MCPcopy Create free account
hub / github.com/axmolengine/axmol / isVariable

Function isVariable

core/base/Properties.cpp:145–159  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

143}
144
145static bool isVariable(const char* str, char* outName, size_t outSize)
146{
147 size_t len = strlen(str);
148 if (len > 3 && str[0] == '$' && str[1] == '{' && str[len - 1] == '}')
149 {
150 size_t size = len - 3;
151 if (size > (outSize - 1))
152 size = outSize - 1;
153 strncpy(outName, str + 2, len - 3);
154 outName[len - 3] = 0;
155 return true;
156 }
157
158 return false;
159}
160
161void Properties::readProperties()
162{

Callers 2

readPropertiesMethod · 0.85
getStringMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected