MCPcopy Create free account
hub / github.com/HumbleNet/HumbleNet / CreateVector

Function CreateVector

3rdparty/flatbuffers/include/flatbuffers/flatbuffers.h:947–953  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

945 /// @return Returns a typed `Offset` into the serialized data indicating
946 /// where the vector is stored.
947 template<typename T> Offset<Vector<T>> CreateVector(const T *v, size_t len) {
948 StartVector(len, sizeof(T));
949 for (auto i = len; i > 0; ) {
950 PushElement(v[--i]);
951 }
952 return Offset<Vector<T>>(EndVector(len));
953 }
954
955 /// @brief Serialize a `std::vector` into a FlatBuffer `vector`.
956 /// @tparam T The data type of the `std::vector` elements.

Callers 1

Calls 5

StartVectorFunction · 0.85
PushElementFunction · 0.85
EndVectorFunction · 0.85
dataMethod · 0.45
sizeMethod · 0.45

Tested by

no test coverage detected