// Return a C++ type for any type (scalar/pointer) specifically for // building a flatbuffer. static std::string GenTypeWire(const Type &type, const char *postfix) { return IsScalar(type.base_type) ? GenTypeBasic(type) + postfix : IsStruct(type) ? "const " + GenTypePointer(type) + " *" : "flatbuffers::Offset<" + GenTypePointer(type) + ">" + postfix; }
// Return a C++ type for any type (scalar/pointer) specifically for // building a flatbuffer. static std::string GenTypeWire(const Parser &parser, const Type &type, const char *postfix, bool real_enum) { return IsScalar(type.base_type) ? GenTypeBasic(parser, type, real_enum) + postfix : IsStruct(type) ? "const " + GenTypePointer(parser, type) + " *" : "flatbuffers::Offset<" + GenTypePointer(parser, type) + ">" + postfix; }
// Return a C++ type for any type (scalar/pointer) that reflects its // serialized size. static std::string GenTypeSize(const Parser &parser, const Type &type) { return IsScalar(type.base_type) ? GenTypeBasic(parser, type, false) : IsStruct(type) ? GenTypePointer(parser, type) : "flatbuffers::uoffset_t"; }
// Return a C++ type for any type (scalar/pointer) specifically for // using a flatbuffer. static std::string GenTypeGet(const Parser &parser, const Type &type, const char *afterbasic, const char *beforeptr, const char *afterptr, bool real_enum) { return IsScalar(type.base_type) ? GenTypeBasic(parser, type, real_enum) + afterbasic : beforeptr + GenTypePointer(parser, type) + afterptr; }
static std::string GenTypeGet(const Type &type) { return IsScalar(type.base_type) ? GenTypeBasic(type) : GenTypePointer(type); }
// Return a C++ type for any type (scalar/pointer) specifically for // using a flatbuffer. static std::string GenTypeGet(const Type &type, const char *afterbasic, const char *beforeptr, const char *afterptr) { return IsScalar(type.base_type) ? GenTypeBasic(type) + afterbasic : beforeptr + GenTypePointer(type) + afterptr; }