MCPcopy Create free account
hub / github.com/BohemiaInteractive/CWR / MutableData

Method MutableData

engine/Poseidon/Foundation/Strings/RString.hpp:80–88  ·  view source on GitHub ↗

Detach from any shared copy and return a writable pointer; null if unset.

Source from the content-addressed store, hash-verified

78
79 // Detach from any shared copy and return a writable pointer; null if unset.
80 char* MutableData()
81 {
82 if (!_ref)
83 {
84 return nullptr;
85 }
86 MakeMutable();
87 return _ref->Data();
88 }
89 __forceinline operator const char*() const { return Data(); }
90 int GetLength() const { return _ref ? strlen(_ref->Data()) : 0; }
91 int GetRefCount() const { return _ref->RefCounter(); }

Callers 6

ConvertDirSlashFunction · 0.80
ReplacesCharsFunction · 0.80
DeserializeScriptValueFunction · 0.80
OnDrawMethod · 0.80
OnDrawMethod · 0.80
test_strings.cppFile · 0.80

Calls 1

DataMethod · 0.45

Tested by

no test coverage detected