MCPcopy Create free account
hub / github.com/AcademySoftwareFoundation/OpenColorIO / Replace

Function Replace

src/utils/StringUtils.h:271–276  ·  view source on GitHub ↗

Replace the 'search' substring by the 'replace' string in 'str'.

Source from the content-addressed store, hash-verified

269
270// Replace the 'search' substring by the 'replace' string in 'str'.
271inline std::string Replace(const std::string & subject, const std::string & search, const std::string & replace)
272{
273 std::string str{subject};
274 ReplaceInPlace(str, search, replace);
275 return str;
276}
277
278// Check if the 'entry' is in the 'list' using a case insensitive comparison.
279inline bool Contain(const StringVec & list, const std::string & entry)

Callers 5

setFunctionNameMethod · 0.85
setResourcePrefixMethod · 0.85
setPixelNameMethod · 0.85
replaceSeparatorFunction · 0.85
OCIO_ADD_TESTFunction · 0.85

Calls 1

ReplaceInPlaceFunction · 0.85

Tested by 1

OCIO_ADD_TESTFunction · 0.68