MCPcopy Create free account
hub / github.com/ZDoom/Raze / GetKey

Method GetKey

source/common/engine/serializer.cpp:622–630  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

620//==========================================================================
621
622const char *FSerializer::GetKey()
623{
624 if (isWriting()) return nullptr; // we do not know this when writing.
625 if (!r->mObjects.Last().mObject->IsObject()) return nullptr; // non-objects do not have keys.
626 auto &it = r->mObjects.Last().mIterator;
627 if (it == r->mObjects.Last().mObject->MemberEnd()) return nullptr;
628 r->mKeyValue = &it->value;
629 return (it++)->name.GetString();
630}
631
632//==========================================================================
633//

Callers 5

ReadAllFieldsMethod · 0.80
ReadFieldsMethod · 0.80
PMapValueReaderFunction · 0.80
MapIteratorGetKeyFunction · 0.80
MapIteratorGetKeyStringFunction · 0.80

Calls 2

IsObjectMethod · 0.80
GetStringMethod · 0.45

Tested by

no test coverage detected