MCPcopy Create free account
hub / github.com/GarageGames/Torque3D / lookup

Method lookup

Engine/source/core/stringTable.cpp:169–184  ·  view source on GitHub ↗

--------------------------------------

Source from the content-addressed store, hash-verified

167
168//--------------------------------------
169StringTableEntry _StringTable::lookup(const char* val, const bool caseSens)
170{
171 PROFILE_SCOPE(StringTableLookup);
172
173 Node **walk, *temp;
174 U32 key = hashString(val);
175 walk = &buckets[key % numBuckets];
176 while((temp = *walk) != NULL) {
177 if(caseSens && !dStrcmp(temp->val, val))
178 return temp->val;
179 else if(!caseSens && !dStricmp(temp->val, val))
180 return temp->val;
181 walk = &(temp->next);
182 }
183 return NULL;
184}
185
186//--------------------------------------
187StringTableEntry _StringTable::lookupn(const char* val, S32 len, const bool caseSens)

Callers 8

FileDialogDataMethod · 0.45
ExecuteMethod · 0.45
ComponentMethod · 0.45
ComponentAssetMethod · 0.45
GameObjectAssetMethod · 0.45
onStaticModifiedMethod · 0.45
FileDialogDataMethod · 0.45
ExecuteMethod · 0.45

Calls 2

dStricmpFunction · 0.85
dStrcmpFunction · 0.50

Tested by

no test coverage detected