DABC (Data Acquisition Backbone Core)  2.9.9
Public Member Functions | Protected Attributes
dabc::BinaryFile Class Reference

Generic file storage for DABC buffers. More...

#include <dabc/BinaryFile.h>

Inheritance diagram for dabc::BinaryFile:
dabc::BasicFile

Public Member Functions

 BinaryFile ()
 buffer header More...
 
bool Close ()
 
const BinaryFileHeaderhdr () const
 
bool OpenReading (const char *fname)
 
bool OpenWriting (const char *fname)
 
bool ReadBuffer (void *ptr, uint64_t *sz, uint64_t *typ=0)
 
bool ReadBufHeader (uint64_t *size, uint64_t *typ=0)
 
bool ReadBufPayload (void *ptr, uint64_t sz)
 
bool WriteBuffer (const void *ptr, uint64_t sz, uint64_t typ=0)
 
bool WriteBufHeader (uint64_t size, uint64_t typ=0)
 
bool WriteBufPayload (const void *ptr, uint64_t sz)
 
 ~BinaryFile ()
 
- Public Member Functions inherited from dabc::BasicFile
 BasicFile ()
 
bool eof () const
 
int GetIntPar (const char *parname)
 Return integer file parameter. More...
 
bool GetStrPar (const char *parname, char *sbuf, int sbuflen)
 Return string file parameter. More...
 
bool isOpened () const
 
bool isReading () const
 
bool IsRFIO ()
 Returns true when RFIO is used. More...
 
bool isWriting () const
 
void SetIO (FileInterface *_io, bool _ioowner=false)
 
 ~BasicFile ()
 

Protected Attributes

BinaryFileBufHeader fBufHdr
 file header More...
 
BinaryFileHeader fFileHdr
 
- Protected Attributes inherited from dabc::BasicFile
FileInterface::Handle fd
 if true, io object owned by file More...
 
bool fReadingMode
 file descriptor More...
 
FileInterfaceio
 
bool iowoner
 interface to the file system More...
 

Additional Inherited Members

- Protected Member Functions inherited from dabc::BasicFile
void CheckIO ()
 
bool CloseBasicFile ()
 reading/writing mode More...
 

Detailed Description

Generic file storage for DABC buffers.

Definition at line 181 of file BinaryFile.h.

Constructor & Destructor Documentation

◆ BinaryFile()

dabc::BinaryFile::BinaryFile ( )
inline

buffer header

Definition at line 188 of file BinaryFile.h.

◆ ~BinaryFile()

dabc::BinaryFile::~BinaryFile ( )
inline

Definition at line 192 of file BinaryFile.h.

Member Function Documentation

◆ OpenReading()

bool dabc::BinaryFile::OpenReading ( const char *  fname)
inline

Definition at line 197 of file BinaryFile.h.

◆ OpenWriting()

bool dabc::BinaryFile::OpenWriting ( const char *  fname)
inline

Definition at line 227 of file BinaryFile.h.

◆ Close()

bool dabc::BinaryFile::Close ( )
inline

Definition at line 259 of file BinaryFile.h.

◆ hdr()

const BinaryFileHeader& dabc::BinaryFile::hdr ( ) const
inline

Definition at line 264 of file BinaryFile.h.

◆ WriteBufHeader()

bool dabc::BinaryFile::WriteBufHeader ( uint64_t  size,
uint64_t  typ = 0 
)
inline

Definition at line 266 of file BinaryFile.h.

◆ WriteBufPayload()

bool dabc::BinaryFile::WriteBufPayload ( const void *  ptr,
uint64_t  sz 
)
inline

Definition at line 288 of file BinaryFile.h.

◆ WriteBuffer()

bool dabc::BinaryFile::WriteBuffer ( const void *  ptr,
uint64_t  sz,
uint64_t  typ = 0 
)
inline

Definition at line 309 of file BinaryFile.h.

◆ ReadBufHeader()

bool dabc::BinaryFile::ReadBufHeader ( uint64_t *  size,
uint64_t *  typ = 0 
)
inline

Definition at line 317 of file BinaryFile.h.

◆ ReadBufPayload()

bool dabc::BinaryFile::ReadBufPayload ( void *  ptr,
uint64_t  sz 
)
inline

Definition at line 337 of file BinaryFile.h.

◆ ReadBuffer()

bool dabc::BinaryFile::ReadBuffer ( void *  ptr,
uint64_t *  sz,
uint64_t *  typ = 0 
)
inline

Definition at line 358 of file BinaryFile.h.

Field Documentation

◆ fFileHdr

BinaryFileHeader dabc::BinaryFile::fFileHdr
protected

Definition at line 183 of file BinaryFile.h.

◆ fBufHdr

BinaryFileBufHeader dabc::BinaryFile::fBufHdr
protected

file header

Definition at line 184 of file BinaryFile.h.


The documentation for this class was generated from the following file: