BOSS 7.0.7
BESIII Offline Software System
|
Namespaces | |
namespace | helper |
namespace | old |
namespace | write |
Classes | |
class | BadVersionIssue |
class | FullEventFragment |
class | Header |
class | Issue |
class | NoSuchChildIssue |
class | NotAlignedIssue |
class | OutOfBoundsIssue |
class | PagedMemory |
class | ROBFragment |
class | ROSFragment |
class | SizeCheckIssue |
class | SubDetectorFragment |
class | TooBigCountIssue |
class | UnboundSourceIdentifierIssue |
class | WrongMarkerIssue |
class | WrongSizeIssue |
Typedefs | |
typedef enum HeaderMarker | HeaderMarker |
typedef enum RunType | RunType |
typedef enum SubDetector | SubDetector |
typedef enum GenericStatus | GenericStatus |
Functions | |
HeaderMarker | child_marker (HeaderMarker e) |
std::string | marker2string (const eformat::HeaderMarker &e) |
std::string | marker2string (uint32_t e) |
uint32_t * | next_fragment (std::fstream &fs, uint32_t *addr=0, size_t size=0) |
size_t | find_rods (const uint32_t *block_start, size_t block_size, const uint32_t **rod=0, uint32_t *rod_size=0, size_t max_count=0) |
template<class TPointer > | |
size_t | find_fragments (eformat::HeaderMarker marker, TPointer block_start, size_t block_size, TPointer *frag=0, size_t max_count=0) |
size_t | get_robs (const uint32_t *fragment, const uint32_t **rob, size_t max_count) |
Variables | |
const uint32_t | STATUS_FRONT = 0 |
status goes in front of data block | |
const uint32_t | STATUS_BACK = 1 |
status goes after data block | |
const uint32_t | DEFAULT_STATUS = NO_ERROR |
const uint32_t | DEFAULT_VERSION = 0x03000000 |
const uint16_t | MAJOR_DEFAULT_VERSION = 0x0300 |
const uint16_t | MAJOR_OLD_VERSION = 0x0204 |
typedef enum GenericStatus eformat::GenericStatus |
typedef enum HeaderMarker eformat::HeaderMarker |
An alias
Definition at line 35 of file HeaderMarker.h.
typedef enum RunType eformat::RunType |
An alias
Definition at line 31 of file RunNumber.h.
typedef enum SubDetector eformat::SubDetector |
An alias
Definition at line 87 of file SourceIdentifier.h.
Defines possible generic errors for the status words
Enumerator | |
---|---|
NO_ERROR | |
BCID_CHECK_FAIL | |
LVL1ID_CHECK_FAIL | |
TIMEOUT | |
DATA_CORRUPTION | |
INTERNAL_OVERFLOW |
Definition at line 24 of file Status.h.
The types of header markers available. They are all 32 bit numbers, with 1234 in the middle for the identification of byte ordering (endianness).
Enumerator | |
---|---|
ROD | The ROD marker. |
ROB | The ROB marker. |
ROS | The ROS marker. |
SUB_DETECTOR | The SubDet. marker. |
FULL_EVENT |
Definition at line 26 of file HeaderMarker.h.
enum eformat::RunType |
Physics Types
Enumerator | |
---|---|
PHYSICS | |
CALIBRATION | |
COSMICS | |
TEST |
Definition at line 23 of file RunNumber.h.
enum eformat::SubDetector |
Sub-detector ID
Definition at line 25 of file SourceIdentifier.h.
eformat::HeaderMarker eformat::child_marker | ( | eformat::HeaderMarker | e | ) |
Returns the child marker of a given parent marker
e | The marker from which you would like to the get child fragment type from |
Definition at line 15 of file HeaderMarker.cxx.
Referenced by eformat::Header< TPointer >::children().
size_t eformat::find_fragments | ( | eformat::HeaderMarker | marker, |
TPointer | block_start, | ||
size_t | block_size, | ||
TPointer * | frag = 0 , |
||
size_t | max_count = 0 |
||
) |
A generic method to find all fragments in a contiguous area of memory. These fragments cannot be RODFragments. For that, use the eformat::find_rods().
marker | The marker you are searching for. |
block_start | A pointer to the block start |
block_size | The overall size of this block, in 32-bit words |
frag | A (optional) preallocated set of pointers to hold the found fragments. If frag is NULL, only counts the number of children. |
max_count | The maximum number of fragments I'll search for, if frag is not NULL. If frag is NULL, this flag has no meaning. |
Definition at line 111 of file util.h.
Referenced by eformat::Header< TPointer >::children().
size_t eformat::find_rods | ( | const uint32_t * | block_start, |
size_t | block_size, | ||
const uint32_t ** | rod = 0 , |
||
uint32_t * | rod_size = 0 , |
||
size_t | max_count = 0 |
||
) |
Returns pointers (to words) to the start of each ROD fragment block in a piece of memory. This is primarily intended for LVL2 supervisor usage.
block_start | The start address of the data block you want to dig the ROD pointers from |
block_size | The size of the block, in 32-bit words |
rod | A (optional) pointer to set of pre-allocated pointers |
rod_size | A (optional) pointer to set of pre-allocated size_t's, where the size of each ROD, in words, will be stored. |
max_count | The maximum number of blocks to dig out from block_start , if rod is not NULL. If rod is NULL, this is meaningless. |
Definition at line 84 of file util.cxx.
size_t eformat::get_robs | ( | const uint32_t * | fragment, |
const uint32_t ** | rob, | ||
size_t | max_count | ||
) |
Gets pointers to all ROB fragments from a fragment of a type which is not known in advance.
fragment | The top level fragment to extract the other ROBFragment's from. |
rod | A pointer to set of pre-allocated pointers |
max_count | The maximum number of blocks to dig out from block_start . |
Definition at line 105 of file util.cxx.
Referenced by EFEventLoopMgr::executeEvent(), get_robs(), main(), RawDataInputSvc::nextEvent(), MixerAlg::nextEvent(), and RawEventReader::readEvent().
std::string eformat::marker2string | ( | const eformat::HeaderMarker & | e | ) |
Returns a string that represents the string of the equivalent marker
e | The enumeration value |
Definition at line 33 of file HeaderMarker.cxx.
Referenced by eformat::Header< TPointer >::check(), eformat::Header< TPointer >::child(), marker2string(), and eformat::Header< TPointer >::nchildren().
std::string eformat::marker2string | ( | uint32_t | e | ) |
Returns a string that represents the string of the equivalent marker
e | The enumeration value |
Definition at line 51 of file HeaderMarker.cxx.
uint32_t * eformat::next_fragment | ( | std::fstream & | fs, |
uint32_t * | addr = 0 , |
||
size_t | size = 0 |
||
) |
This function will read the next fragment in a normal, already opened, std::fstream. The space for the fragment will be allocated dynamically and the user should free it. Otherwise, if the user wants to re-use a pre-allocated memory space, the second and third arguments can be given, in which case the function will check if the space is enough. If the space is not enough, NULL is returned.
fs | The input filestream |
addr | The optional user allocated space |
size | The optional size, in bytes, of the allocated space |
Definition at line 22 of file util.cxx.
const uint32_t eformat::DEFAULT_STATUS = NO_ERROR |
The default status to use
Definition at line 44 of file Status.h.
Referenced by eformat::write::FullEventFragment::FullEventFragment(), eformat::write::ROBFragment::ROBFragment(), eformat::write::ROSFragment::ROSFragment(), and eformat::write::SubDetectorFragment::SubDetectorFragment().
const uint32_t eformat::DEFAULT_VERSION = 0x03000000 |
The default eformat version to use
Definition at line 24 of file Version.h.
Referenced by eformat::write::FullEventFragment::FullEventFragment(), eformat::write::FullEventFragment::minor_version(), eformat::write::ROBFragment::minor_version(), eformat::write::ROSFragment::minor_version(), eformat::write::SubDetectorFragment::minor_version(), eformat::write::ROBFragment::ROBFragment(), eformat::write::ROBFragment::rod_minor_version(), eformat::write::ROSFragment::ROSFragment(), and eformat::write::SubDetectorFragment::SubDetectorFragment().
const uint16_t eformat::MAJOR_DEFAULT_VERSION = 0x0300 |
The major default eformat version to use
Definition at line 29 of file Version.h.
Referenced by eformat::Header< TPointer >::check(), eformat::ROBFragment< TPointer >::check(), and eformat::old::convert().
const uint16_t eformat::MAJOR_OLD_VERSION = 0x0204 |
The major default eformat version to use
Definition at line 34 of file Version.h.
Referenced by eformat::old::Header::check(), eformat::old::RODFragment::check(), and eformat::old::convert().
const uint32_t eformat::STATUS_BACK = 1 |
status goes after data block
Definition at line 39 of file Status.h.
Referenced by eformat::old::RODFragment::data().
const uint32_t eformat::STATUS_FRONT = 0 |
status goes in front of data block
Definition at line 38 of file Status.h.
Referenced by main(), eformat::write::ROBFragment::operator=(), eformat::write::ROBFragment::ROBFragment(), eformat::old::RODFragment::status(), and eformat::write::ROBFragment::status_position().