12#ifndef ROOT_TBufferFile
13#define ROOT_TBufferFile
43 class TActionSequence;
210 virtual void StreamObject(
void *obj,
const std::type_info &typeinfo,
const TClass* onFileClass = 0 );
211 virtual void StreamObject(
void *obj,
const char *className,
const TClass* onFileClass = 0 );
void frombuf(char *&buf, Bool_t *x)
void tobuf(char *&buf, Bool_t x)
unsigned long long ULong64_t
#define ClassDef(name, id)
char *(* ReAllocCharFun_t)(char *, size_t, size_t)
The concrete implementation of TBuffer for writing/reading to/from a ROOT file or socket.
virtual void WriteCharP(const Char_t *c)
virtual void ReadCharStar(char *&s)
Read char* from TBuffer.
virtual void CheckCount(UInt_t offset)
Check if offset is not too large (< kMaxMapCount) when writing.
virtual void ReadFastArrayString(Char_t *c, Int_t n)
Read array of n characters from the I/O buffer.
virtual void StreamObject(void *obj, const std::type_info &typeinfo, const TClass *onFileClass=0)
Stream an object given its C++ typeinfo information.
TVirtualStreamerInfo * GetInfo()
virtual void WriteString(const char *s)
Write string to I/O buffer.
virtual ~TBufferFile()
Delete an I/O buffer object.
virtual void ReadFloat(Float_t &f)
virtual void ReadUShort(UShort_t &s)
virtual void WriteStdString(const std::string *s)
Write std::string to TBuffer.
virtual void ReadStdString(std::string *s)
Read std::string from TBuffer.
virtual void ReadWithNbits(Float_t *ptr, Int_t nbits)
Read a Float16_t from the buffer when the number of bits is specified (explicitly or not) see comment...
virtual void WriteFastArrayString(const Char_t *c, Int_t n)
Write array of n characters into the I/O buffer.
void operator=(const TBufferFile &)
not implemented
virtual void WriteFastArrayDouble32(const Double_t *d, Int_t n, TStreamerElement *ele=0)
Write array of n doubles (as float) into the I/O buffer.
virtual void WriteInt(Int_t i)
virtual void ReadULong64(ULong64_t &l)
virtual void ReadShort(Short_t &s)
virtual void WriteFastArrayFloat16(const Float_t *f, Int_t n, TStreamerElement *ele=0)
Write array of n floats (as truncated float) into the I/O buffer.
virtual Int_t ReadClassEmulated(const TClass *cl, void *object, const TClass *onfile_class)
Read emulated class.
TBufferFile(const TBufferFile &)
not implemented
virtual void WriteDouble32(Double_t *d, TStreamerElement *ele=0)
Write a Double32_t to the buffer.
virtual void SkipVersion(const TClass *cl=0)
Skip class version from I/O buffer.
virtual Version_t ReadVersion(UInt_t *start=0, UInt_t *bcnt=0, const TClass *cl=0)
Read class version from I/O buffer.
virtual void ReadFastArray(Bool_t *b, Int_t n)
Read array of n bools from the I/O buffer.
virtual void WriteArray(const Bool_t *b, Int_t n)
Write array of n bools into the I/O buffer.
virtual void ReadFastArrayFloat16(Float_t *f, Int_t n, TStreamerElement *ele=0)
Read array of n floats (written as truncated float) from the I/O buffer.
virtual void WriteUChar(UChar_t c)
virtual TObject * ReadObject(const TClass *cl)
Read object from I/O buffer.
Int_t ApplySequence(const TStreamerInfoActions::TActionSequence &sequence, void *object)
Read one collection of objects from the buffer using the StreamerInfoLoopAction.
virtual void WriteULong(ULong_t l)
virtual void ReadLong64(Long64_t &l)
virtual void WriteFloat16(Float_t *f, TStreamerElement *ele=0)
Write a Float16_t to the buffer.
virtual void ReadLong(Long_t &l)
Read Long from TBuffer.
virtual void ReadWithFactor(Float_t *ptr, Double_t factor, Double_t minvalue)
Read a Float16_t from the buffer when the factor and minimum value have been specified see comments a...
virtual void WriteClass(const TClass *cl)
Write class description to I/O buffer.
virtual void WriteBool(Bool_t b)
virtual Version_t ReadVersionNoCheckSum(UInt_t *start=0, UInt_t *bcnt=0)
Read class version from I/O buffer, when the caller knows for sure that there is no checksum written/...
virtual void WriteFloat(Float_t f)
virtual void WriteFastArray(const Bool_t *b, Int_t n)
Write array of n bools into the I/O buffer.
virtual Int_t ReadArrayDouble32(Double_t *&d, TStreamerElement *ele=0)
Read array of doubles (written as float) from the I/O buffer.
virtual void ReadFastArrayWithNbits(Float_t *ptr, Int_t n, Int_t nbits)
Read array of n floats (written as truncated float) from the I/O buffer.
virtual void ReadFastArrayWithFactor(Float_t *ptr, Int_t n, Double_t factor, Double_t minvalue)
Read array of n floats (written as truncated float) from the I/O buffer.
Int_t CheckByteCount(UInt_t startpos, UInt_t bcnt, const TClass *clss, const char *classname)
Check byte count with current buffer position.
virtual Int_t ReadClassBuffer(const TClass *cl, void *pointer, const TClass *onfile_class)
Deserialize information from a buffer into an object.
virtual void ReadUInt(UInt_t &i)
virtual void WriteBuf(const void *buf, Int_t max)
Write max bytes from buf into the I/O buffer.
virtual void WriteDouble(Double_t d)
virtual void ReadChar(Char_t &c)
virtual void SkipObjectAny()
Skip any kind of object from buffer.
virtual void WriteTString(const TString &s)
Write TString to TBuffer.
virtual void ReadTString(TString &s)
Read TString from TBuffer.
virtual void ReadBool(Bool_t &b)
virtual void ClassMember(const char *, const char *=0, Int_t=-1, Int_t=-1)
virtual void ReadInt(Int_t &i)
virtual void WriteShort(Short_t s)
virtual void ReadDouble32(Double_t *d, TStreamerElement *ele=0)
Read a Double32_t from the buffer, see comments about Double32_t encoding at TBufferFile::WriteDouble...
virtual void WriteArrayDouble32(const Double_t *d, Int_t n, TStreamerElement *ele=0)
Write array of n doubles (as float) into the I/O buffer.
virtual void WriteUShort(UShort_t s)
virtual void WriteUInt(UInt_t i)
virtual void WriteArrayFloat16(const Float_t *f, Int_t n, TStreamerElement *ele=0)
Write array of n floats (as truncated float) into the I/O buffer.
virtual Int_t ReadArrayFloat16(Float_t *&f, TStreamerElement *ele=0)
Read array of floats (written as truncated float) from the I/O buffer.
virtual void ReadFloat16(Float_t *f, TStreamerElement *ele=0)
Read a Float16_t from the buffer, see comments about Float16_t encoding at TBufferFile::WriteFloat16(...
virtual void WriteLong(Long_t l)
Int_t ApplySequenceVecPtr(const TStreamerInfoActions::TActionSequence &sequence, void *start_collection, void *end_collection)
Read one collection of objects from the buffer using the StreamerInfoLoopAction.
virtual void ReadDouble(Double_t &d)
virtual Int_t ReadArray(Bool_t *&b)
Read array of bools from the I/O buffer.
virtual Int_t ReadStaticArray(Bool_t *b)
Read array of bools from the I/O buffer.
virtual void WriteCharStar(char *s)
Write char* into TBuffer.
virtual void WriteLong64(Long64_t l)
virtual void WriteULong64(ULong64_t l)
virtual void WriteChar(Char_t c)
std::vector< TStreamerInfo * > InfoList_t
virtual void IncrementLevel(TVirtualStreamerInfo *info)
Increment level.
UInt_t CheckObject(UInt_t offset, const TClass *cl, Bool_t readClass=kFALSE)
Check for object in the read map.
virtual Version_t ReadVersionForMemberWise(const TClass *cl=0)
Read class version from I/O buffer.
InfoList_t fInfoStack
Stack of pointers to the TStreamerInfos.
virtual void ClassBegin(const TClass *, Version_t=-1)
virtual void ReadFastArrayDouble32(Double_t *d, Int_t n, TStreamerElement *ele=0)
Read array of n doubles (written as float) from the I/O buffer.
virtual Int_t WriteClassBuffer(const TClass *cl, void *pointer)
Function called by the Streamer functions to serialize object at p to buffer b.
virtual void ReadCharP(Char_t *c)
virtual Int_t ReadStaticArrayDouble32(Double_t *d, TStreamerElement *ele=0)
Read array of doubles (written as float) from the I/O buffer.
virtual void ReadUChar(UChar_t &c)
virtual void ClassEnd(const TClass *)
virtual char * ReadString(char *s, Int_t max)
Read string from I/O buffer.
virtual void SetByteCount(UInt_t cntpos, Bool_t packInVersion=kFALSE)
Set byte count at position cntpos in the buffer.
virtual void DecrementLevel(TVirtualStreamerInfo *)
Decrement level.
virtual void SetStreamerElementNumber(TStreamerElement *, Int_t)
virtual TClass * ReadClass(const TClass *cl=0, UInt_t *objTag=0)
Read class definition from I/O buffer.
virtual void * ReadObjectAny(const TClass *cast)
Read object from I/O buffer.
virtual Int_t ReadBuf(void *buf, Int_t max)
Read max bytes from the I/O buffer into buf.
virtual Int_t ReadStaticArrayFloat16(Float_t *f, TStreamerElement *ele=0)
Read array of floats (written as truncated float) from the I/O buffer.
virtual void WriteObjectClass(const void *actualObjStart, const TClass *actualClass, Bool_t cacheReuse)
Write object to I/O buffer.
TStreamerInfo * fInfo
Pointer to TStreamerInfo object writing/reading the buffer.
virtual UInt_t WriteVersionMemberWise(const TClass *cl, Bool_t useBcnt=kFALSE)
Write class version to I/O buffer after setting the kStreamedMemberWise bit in the version number.
virtual void ReadULong(ULong_t &l)
virtual UInt_t WriteVersion(const TClass *cl, Bool_t useBcnt=kFALSE)
Write class version to I/O buffer.
Direct subclass of TBuffer, implements common methods for TBufferFile and TBufferText classes.
virtual Bool_t CheckObject(const TObject *obj)
Check if the specified object is already in the buffer.
virtual void WriteStdString(const std::string *s)=0
void AutoExpand(Int_t size_needed)
Automatically calculate a new size and expand the buffer to fit at least size_needed.
virtual void ReadStdString(std::string *s)=0
TClass instances represent classes, structs and namespaces in the ROOT type system.
Mother of all ROOT objects.
Describe Streamer information for one class version.
Wrapper around an object and giving indirect access to its content even if the object is not of a cla...
Abstract Interface class describing Streamer information for one class.
static constexpr double s