MCPcopy Create free account
hub / github.com/chronoxor/FastBinaryEncoding / deserialize

Method deserialize

proto/enums_models.cpp:1242–1254  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1240}
1241
1242size_t EnumsModel::deserialize(::enums::Enums& value) const noexcept
1243{
1244 if ((this->buffer().offset() + model.fbe_offset() - 4) > this->buffer().size())
1245 return 0;
1246
1247 uint32_t fbe_full_size = *((const uint32_t*)(this->buffer().data() + this->buffer().offset() + model.fbe_offset() - 4));
1248 assert((fbe_full_size >= model.fbe_size()) && "Model is broken!");
1249 if (fbe_full_size < model.fbe_size())
1250 return 0;
1251
1252 model.get(value);
1253 return fbe_full_size;
1254}
1255
1256} // namespace enums
1257

Callers

nothing calls this directly

Calls 7

offsetMethod · 0.45
bufferMethod · 0.45
fbe_offsetMethod · 0.45
sizeMethod · 0.45
dataMethod · 0.45
fbe_sizeMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected