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 1209 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1158 of file RNTupleSerialize.cxx.
|
static |
Definition at line 715 of file RNTupleSerialize.cxx.
|
static |
Definition at line 894 of file RNTupleSerialize.cxx.
|
static |
Definition at line 861 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1117 of file RNTupleSerialize.cxx.
|
static |
Definition at line 809 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1002 of file RNTupleSerialize.cxx.
|
static |
Definition at line 779 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1699 of file RNTupleSerialize.cxx.
|
static |
Definition at line 970 of file RNTupleSerialize.cxx.
|
static |
Definition at line 936 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1642 of file RNTupleSerialize.cxx.
|
static |
Definition at line 560 of file RNTupleSerialize.cxx.
|
static |
Definition at line 589 of file RNTupleSerialize.cxx.
|
static |
Definition at line 623 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1064 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1773 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1358 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1925 of file RNTupleSerialize.cxx.
|
static |
Definition at line 652 of file RNTupleSerialize.cxx.
|
static |
Definition at line 572 of file RNTupleSerialize.cxx.
|
static |
Definition at line 602 of file RNTupleSerialize.cxx.
|
static |
Definition at line 637 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1191 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1134 of file RNTupleSerialize.cxx.
|
static |
Definition at line 673 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1109 of file RNTupleSerialize.cxx.
|
static |
Definition at line 853 of file RNTupleSerialize.cxx.
|
static |
Definition at line 836 of file RNTupleSerialize.cxx.
|
static |
Definition at line 825 of file RNTupleSerialize.cxx.
|
static |
Definition at line 798 of file RNTupleSerialize.cxx.
|
static |
Definition at line 978 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 762 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1600 of file RNTupleSerialize.cxx.
|
static |
Definition at line 920 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1501 of file RNTupleSerialize.cxx.
|
static |
Definition at line 550 of file RNTupleSerialize.cxx.
|
static |
Definition at line 577 of file RNTupleSerialize.cxx.
|
static |
Definition at line 607 of file RNTupleSerialize.cxx.
|
static |
Definition at line 908 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1021 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1530 of file RNTupleSerialize.cxx.
|
static |
Definition at line 901 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 1287 of file RNTupleSerialize.cxx.
|
static |
Definition at line 1911 of file RNTupleSerialize.cxx.
|
static |
Definition at line 642 of file RNTupleSerialize.cxx.
|
static |
Definition at line 567 of file RNTupleSerialize.cxx.
|
static |
Definition at line 597 of file RNTupleSerialize.cxx.
|
static |
Definition at line 632 of file RNTupleSerialize.cxx.
|
static |
Writes a XxHash-3 64bit checksum of the byte range given by data and length.
Definition at line 521 of file RNTupleSerialize.cxx.
|
static |
Definition at line 544 of file RNTupleSerialize.cxx.
|
static |
Expects an xxhash3 checksum in the 8 bytes following data + length and verifies it.
Definition at line 532 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.