A helper class for serializing and deserialization of the RNTuple binary format.
All serialization and deserialization routines return the number of bytes processed (written or read).
The serialization routines can be called with a nullptr buffer, in which case only the size required to perform a serialization is returned. Deserialization routines must be called with a buffer that is sufficiently large.
Deserialization errors throw exceptions. Only when indicated or when passed as a parameter is the buffer size checked.
Definition at line 62 of file RNTupleSerialize.hxx.
Classes | |
struct | RClusterGroup |
struct | RClusterSummary |
class | RContext |
The serialization context is used for the piecewise serialization of a descriptor. More... | |
struct | REnvelopeLink |
Public Types | |
using | StreamerInfoMap_t = std::map< Int_t, TVirtualStreamerInfo * > |
Static Public Member Functions | |
static RResult< std::uint32_t > | DeserializeClusterGroup (const void *buffer, std::uint64_t bufSize, RClusterGroup &clusterGroup) |
static RResult< std::uint32_t > | DeserializeClusterSummary (const void *buffer, std::uint64_t bufSize, RClusterSummary &clusterSummary) |
static RResult< std::uint32_t > | DeserializeColumnType (const void *buffer, ROOT::Experimental::EColumnType &type) |
static RResult< std::uint32_t > | DeserializeEnvelope (const void *buffer, std::uint64_t bufSize, std::uint16_t expectedType) |
static RResult< std::uint32_t > | DeserializeEnvelope (const void *buffer, std::uint64_t bufSize, std::uint16_t expectedType, std::uint64_t &xxhash3) |
static RResult< std::uint32_t > | DeserializeEnvelopeLink (const void *buffer, std::uint64_t bufSize, REnvelopeLink &envelopeLink) |
static RResult< std::uint32_t > | DeserializeExtraTypeInfoId (const void *buffer, ROOT::Experimental::EExtraTypeInfoIds &id) |
static RResult< std::uint32_t > | DeserializeFeatureFlags (const void *buffer, std::uint64_t bufSize, std::vector< std::uint64_t > &flags) |
static RResult< std::uint32_t > | DeserializeFieldStructure (const void *buffer, ROOT::Experimental::ENTupleStructure &structure) |
static RResult< void > | DeserializeFooter (const void *buffer, std::uint64_t bufSize, RNTupleDescriptorBuilder &descBuilder) |
static RResult< std::uint32_t > | DeserializeFrameHeader (const void *buffer, std::uint64_t bufSize, std::uint64_t &frameSize) |
static RResult< std::uint32_t > | DeserializeFrameHeader (const void *buffer, std::uint64_t bufSize, std::uint64_t &frameSize, std::uint32_t &nitems) |
static RResult< void > | DeserializeHeader (const void *buffer, std::uint64_t bufSize, RNTupleDescriptorBuilder &descBuilder) |
static std::uint32_t | DeserializeInt16 (const void *buffer, std::int16_t &val) |
static std::uint32_t | DeserializeInt32 (const void *buffer, std::int32_t &val) |
static std::uint32_t | DeserializeInt64 (const void *buffer, std::int64_t &val) |
static RResult< std::uint32_t > | DeserializeLocator (const void *buffer, std::uint64_t bufSize, RNTupleLocator &locator) |
static RResult< void > | DeserializePageList (const void *buffer, std::uint64_t bufSize, DescriptorId_t clusterGroupId, RNTupleDescriptor &desc) |
static RResult< std::uint32_t > | DeserializeSchemaDescription (const void *buffer, std::uint64_t bufSize, RNTupleDescriptorBuilder &descBuilder) |
static RResult< StreamerInfoMap_t > | DeserializeStreamerInfos (const std::string &extraTypeInfoContent) |
static RResult< std::uint32_t > | DeserializeString (const void *buffer, std::uint64_t bufSize, std::string &val) |
static std::uint32_t | DeserializeUInt16 (const void *buffer, std::uint16_t &val) |
static std::uint32_t | DeserializeUInt32 (const void *buffer, std::uint32_t &val) |
static std::uint32_t | DeserializeUInt64 (const void *buffer, std::uint64_t &val) |
static std::uint32_t | SerializeClusterGroup (const RClusterGroup &clusterGroup, void *buffer) |
static std::uint32_t | SerializeClusterSummary (const RClusterSummary &clusterSummary, void *buffer) |
static std::uint32_t | SerializeColumnType (ROOT::Experimental::EColumnType type, void *buffer) |
static std::uint32_t | SerializeEnvelopeLink (const REnvelopeLink &envelopeLink, void *buffer) |
static std::uint32_t | SerializeEnvelopePostscript (unsigned char *envelope, std::uint64_t size) |
static std::uint32_t | SerializeEnvelopePostscript (unsigned char *envelope, std::uint64_t size, std::uint64_t &xxhash3) |
static std::uint32_t | SerializeEnvelopePreamble (std::uint16_t envelopeType, void *buffer) |
static std::uint32_t | SerializeExtraTypeInfoId (ROOT::Experimental::EExtraTypeInfoIds id, void *buffer) |
static std::uint32_t | SerializeFeatureFlags (const std::vector< std::uint64_t > &flags, void *buffer) |
static std::uint32_t | SerializeFieldStructure (ROOT::Experimental::ENTupleStructure structure, void *buffer) |
While we could just interpret the enums as ints, we make the translation explicit in order to avoid accidentally changing the on-disk numbers when adjusting the enum classes. | |
static std::uint32_t | SerializeFooter (void *buffer, const RNTupleDescriptor &desc, const RContext &context) |
static std::uint32_t | SerializeFramePostscript (void *frame, std::uint64_t size) |
static RContext | SerializeHeader (void *buffer, const RNTupleDescriptor &desc) |
static std::uint32_t | SerializeInt16 (std::int16_t val, void *buffer) |
static std::uint32_t | SerializeInt32 (std::int32_t val, void *buffer) |
static std::uint32_t | SerializeInt64 (std::int64_t val, void *buffer) |
static std::uint32_t | SerializeListFramePreamble (std::uint32_t nitems, void *buffer) |
static std::uint32_t | SerializeLocator (const RNTupleLocator &locator, void *buffer) |
static std::uint32_t | SerializePageList (void *buffer, const RNTupleDescriptor &desc, std::span< DescriptorId_t > physClusterIDs, const RContext &context) |
static std::uint32_t | SerializeRecordFramePreamble (void *buffer) |
static std::uint32_t | SerializeSchemaDescription (void *buffer, const RNTupleDescriptor &desc, const RContext &context, bool forHeaderExtension=false) |
Serialize the schema description in desc into buffer . | |
static std::string | SerializeStreamerInfos (const StreamerInfoMap_t &infos) |
static std::uint32_t | SerializeString (const std::string &val, void *buffer) |
static std::uint32_t | SerializeUInt16 (std::uint16_t val, void *buffer) |
static std::uint32_t | SerializeUInt32 (std::uint32_t val, void *buffer) |
static std::uint32_t | SerializeUInt64 (std::uint64_t val, void *buffer) |
static std::uint32_t | SerializeXxHash3 (const unsigned char *data, std::uint64_t length, std::uint64_t &xxhash3, void *buffer) |
Writes a XxHash-3 64bit checksum of the byte range given by data and length. | |
static RResult< void > | VerifyXxHash3 (const unsigned char *data, std::uint64_t length) |
static RResult< void > | VerifyXxHash3 (const unsigned char *data, std::uint64_t length, std::uint64_t &xxhash3) |
Expects an xxhash3 checksum in the 8 bytes following data + length and verifies it. | |
Static Public Attributes | |
static constexpr std::uint16_t | kEnvelopeTypeFooter = 0x02 |
static constexpr std::uint16_t | kEnvelopeTypeHeader = 0x01 |
static constexpr std::uint16_t | kEnvelopeTypePageList = 0x03 |
static constexpr std::uint16_t | kFlagDeferredColumn = 0x01 |
static constexpr std::uint16_t | kFlagHasTypeChecksum = 0x04 |
static constexpr std::uint16_t | kFlagHasValueRange = 0x02 |
static constexpr std::uint16_t | kFlagProjectedField = 0x02 |
static constexpr std::uint16_t | kFlagRepetitiveField = 0x01 |
static constexpr int64_t | kSuppressedColumnMarker = std::numeric_limits<std::int64_t>::min() |
static constexpr DescriptorId_t | kZeroFieldId = std::uint64_t(-2) |
#include <ROOT/RNTupleSerialize.hxx>
using ROOT::Experimental::Internal::RNTupleSerializer::StreamerInfoMap_t = std::map<Int_t, TVirtualStreamerInfo *> |
Definition at line 81 of file RNTupleSerialize.hxx.
|
static |
Definition at line 1206 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1155 of file RNTupleSerialize.cxx.
|
static |
Definition at line 713 of file RNTupleSerialize.cxx.
|
static |
Definition at line 891 of file RNTupleSerialize.cxx.
|
static |
Definition at line 859 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1114 of file RNTupleSerialize.cxx.
|
static |
Definition at line 807 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1000 of file RNTupleSerialize.cxx.
|
static |
Definition at line 777 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1696 of file RNTupleSerialize.cxx.
|
static |
Definition at line 968 of file RNTupleSerialize.cxx.
|
static |
Definition at line 934 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1639 of file RNTupleSerialize.cxx.
|
static |
Definition at line 558 of file RNTupleSerialize.cxx.
|
static |
Definition at line 587 of file RNTupleSerialize.cxx.
|
static |
Definition at line 621 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1061 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1771 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1355 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1922 of file RNTupleSerialize.cxx.
|
static |
Definition at line 650 of file RNTupleSerialize.cxx.
|
static |
Definition at line 570 of file RNTupleSerialize.cxx.
|
static |
Definition at line 600 of file RNTupleSerialize.cxx.
|
static |
Definition at line 635 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1188 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1131 of file RNTupleSerialize.cxx.
|
static |
Definition at line 671 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1106 of file RNTupleSerialize.cxx.
|
static |
Definition at line 851 of file RNTupleSerialize.cxx.
|
static |
Definition at line 834 of file RNTupleSerialize.cxx.
|
static |
Definition at line 823 of file RNTupleSerialize.cxx.
|
static |
Definition at line 796 of file RNTupleSerialize.cxx.
|
static |
Definition at line 976 of file RNTupleSerialize.cxx.
|
static |
While we could just interpret the enums as ints, we make the translation explicit in order to avoid accidentally changing the on-disk numbers when adjusting the enum classes.
Definition at line 760 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1597 of file RNTupleSerialize.cxx.
|
static |
Definition at line 918 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1498 of file RNTupleSerialize.cxx.
|
static |
Definition at line 548 of file RNTupleSerialize.cxx.
|
static |
Definition at line 575 of file RNTupleSerialize.cxx.
|
static |
Definition at line 605 of file RNTupleSerialize.cxx.
|
static |
Definition at line 906 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1019 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1527 of file RNTupleSerialize.cxx.
|
static |
Definition at line 899 of file RNTupleSerialize.cxx.
|
static |
Serialize the schema description in desc
into buffer
.
If forHeaderExtension
is true, serialize only the fields and columns tagged as part of the header extension (see RNTupleDescriptorBuilder::BeginHeaderExtension
).
Definition at line 1284 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1908 of file RNTupleSerialize.cxx.
|
static |
Definition at line 640 of file RNTupleSerialize.cxx.
|
static |
Definition at line 565 of file RNTupleSerialize.cxx.
|
static |
Definition at line 595 of file RNTupleSerialize.cxx.
|
static |
Definition at line 630 of file RNTupleSerialize.cxx.
|
static |
Writes a XxHash-3 64bit checksum of the byte range given by data and length.
Definition at line 519 of file RNTupleSerialize.cxx.
|
static |
Definition at line 542 of file RNTupleSerialize.cxx.
|
static |
Expects an xxhash3 checksum in the 8 bytes following data + length and verifies it.
Definition at line 530 of file RNTupleSerialize.cxx.
|
staticconstexpr |
Definition at line 65 of file RNTupleSerialize.hxx.
|
staticconstexpr |
Definition at line 64 of file RNTupleSerialize.hxx.
|
staticconstexpr |
Definition at line 66 of file RNTupleSerialize.hxx.
|
staticconstexpr |
Definition at line 72 of file RNTupleSerialize.hxx.
|
staticconstexpr |
Definition at line 70 of file RNTupleSerialize.hxx.
|
staticconstexpr |
Definition at line 73 of file RNTupleSerialize.hxx.
|
staticconstexpr |
Definition at line 69 of file RNTupleSerialize.hxx.
|
staticconstexpr |
Definition at line 68 of file RNTupleSerialize.hxx.
|
staticconstexpr |
Definition at line 77 of file RNTupleSerialize.hxx.
|
staticconstexpr |
Definition at line 75 of file RNTupleSerialize.hxx.