MCPcopy Create free account
hub / github.com/TorqueGameEngines/Torque3D / getDataFieldPrefix

Method getDataFieldPrefix

Engine/source/console/simObject.cpp:1321–1338  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1319//-----------------------------------------------------------------------------
1320
1321StringTableEntry SimObject::getDataFieldPrefix(StringTableEntry fieldName)
1322{
1323 // Sanity!
1324 AssertFatal(fieldName != NULL, "Cannot get field prefix with NULL field name.");
1325
1326 // Find the field.
1327 const AbstractClassRep::Field* pField = findField(fieldName);
1328
1329 // Return nothing if field was not found.
1330 if (pField == NULL)
1331 return StringTable->EmptyString();
1332
1333 // Yes, so fetch the console base type.
1334 ConsoleBaseType* pConsoleBaseType = ConsoleBaseType::getType(pField->type);
1335
1336 // Fetch the type prefix.
1337 return pConsoleBaseType->getTypePrefix();
1338}
1339
1340
1341//-----------------------------------------------------------------------------

Callers

nothing calls this directly

Calls 3

getTypeFunction · 0.85
EmptyStringMethod · 0.80
getTypePrefixMethod · 0.80

Tested by

no test coverage detected