/search.css" rel="stylesheet" type="text/css"/> /search.js">
| Classes | Job Modules | Data Objects | Services | Algorithms | Tools | Packages | Directories | Tracs |

In This Package:

Public Types | Public Member Functions | Static Public Attributes | Protected Member Functions | Private Member Functions | Private Attributes | Friends
DybDaq::LtbHead Class Reference

#include <LtbHead.h>

Inheritance diagram for DybDaq::LtbHead:
Inheritance graph
[legend]
Collaboration diagram for DybDaq::LtbHead:
Collaboration graph
[legend]

List of all members.

Public Types

typedef std::pair< const char
*, unsigned int > 
OutputBuffer
typedef std::vector< OutputBufferOutputBufferList
typedef std::vector
< ByteInspector * > 
Bytes
typedef std::vector
< BitsInspector * > 
Bits

Public Member Functions

virtual ~LtbHead ()
 Destroy this instance of the class.
unsigned int version () const
 Returns the version of the trigger format.
virtual const DaqTraitsdaqTraits () const
 Returns the DaqTraits instance used to parse this object's buffer.
unsigned int rawTriggerTotal () const
 Returns the total number of raw triggers belonging to this trigger.
unsigned int rawTriggersSaved () const
 Returns the total number of raw triggers saved in this trigger.
unsigned int ltbStatus () const
 Returns the LTB status.
unsigned int localTriggerNumber () const
 Returns the local trigger sequence number.
bool clockError () const
 Returns true if the external clock is not presented or unsteady.
virtual unsigned int bufferSize () const
 Returns the size, in 4-bytes, of this ojbect's contents in the buffer.
const LtbTraitsltbTraits () const
 Returns the LtbTraits instance used to parse this object's buffer.
bool hasDaqTraits () const
virtual unsigned int gather (OutputBufferList &outputBuffers) const
virtual unsigned int inspect (DaqBuffer::Bytes &inspectors) const

Static Public Attributes

static const unsigned int kBytesInInt
static const unsigned int kUndefinedFormatComponent

Protected Member Functions

 LtbHead (const unsigned int localTriggerNumber, const unsigned int rawTriggerTotal, const unsigned int ltbStatus, const bool clockError, const LtbTraits &traits)
 Create an instance of this class.
 LtbHead (const ByteBuffer &byteBuffer)
 Create an instance of this class.
virtual unsigned int formatComponent () const
 Returns the component with the format of this buffer.
const char * buffer () const
char * buffer ()
bool hasByteBuffer () const
const ByteBufferbyteBuffer () const
unsigned int fillInspectors (DaqBuffer::Bytes &inspectors, unsigned int component, unsigned int cursor) const
virtual bool readBool (const unsigned int field) const
virtual int readInt (const unsigned int field) const
virtual unsigned char readUnsignedChar (const unsigned int field) const
virtual unsigned int readUnsignedInt (const unsigned int field) const
virtual void writeField (const bool value, const unsigned int field)
virtual void writeField (const int value, const unsigned int field)
virtual void writeField (const unsigned int value, const unsigned int field)

Private Member Functions

 LtbHead ()
 Suppress default.
 LtbHead (LtbHead &rhs)
 Suppress default.
LtbHeadoperator= (LtbHead &rhs)
 Suppress default.
void setRawTriggerTotal (const unsigned int rawTriggerTotal)
 Sets the total number of raw triggers belonging to this trigger.
void setRawTriggersSaved (const unsigned int rawTriggersSaved)
 Sets the total number of raw triggers saved in this trigger.
void setLtbStatus (const unsigned int ltbStatus)
 Sets the LTB status.
void setLocalTriggerNumber (const unsigned int localTriggerNumber)
 Sets the local trigger sequence number.
void setClockError (const bool clockError)
 Sets whether the external clock is not present or unsteady.

Private Attributes

const LtbTraitsm_traits
 The LtbTraits instance used to parse this object's buffer.

Friends

class LtbReadout

Detailed Description

Definition at line 21 of file LtbHead.h.


Constructor & Destructor Documentation

LtbHead::~LtbHead ( ) [virtual]

Destroy this instance of the class.

Definition at line 44 of file LtbHead.cc.

                  {
}
LtbHead::LtbHead ( const unsigned int  localTriggerNumber,
const unsigned int  rawTriggerTotal,
const unsigned int  ltbStatus,
const bool  clockError,
const LtbTraits traits 
) [protected]

Create an instance of this class.

Definition at line 20 of file LtbHead.cc.

LtbHead::LtbHead ( const ByteBuffer byteBuffer) [protected]

Create an instance of this class.

Definition at line 36 of file LtbHead.cc.

                                             :
LtbBuffer(byteBuffer,
          *((LtbTraits*)0)) {
    const char* buffer = byteBuffer.cursor();
    m_traits = LtbTraits::readTraits(buffer);
        byteBuffer.position(byteBuffer.position() + kBytesInInt);
}
DybDaq::LtbHead::LtbHead ( ) [private]

Suppress default.

DybDaq::LtbHead::LtbHead ( LtbHead rhs) [private]

Suppress default.


Member Function Documentation

unsigned int LtbHead::version ( ) const

Returns the version of the trigger format.

Definition at line 55 of file LtbHead.cc.

const DaqTraits & LtbHead::daqTraits ( ) const [virtual]

Returns the DaqTraits instance used to parse this object's buffer.

Reimplemented from DybDaq::DaqBuffer.

Definition at line 47 of file LtbHead.cc.

                                          {
        return *m_traits;
}
unsigned int LtbHead::rawTriggerTotal ( ) const

Returns the total number of raw triggers belonging to this trigger.

Definition at line 59 of file LtbHead.cc.

unsigned int LtbHead::rawTriggersSaved ( ) const

Returns the total number of raw triggers saved in this trigger.

Definition at line 63 of file LtbHead.cc.

unsigned int LtbHead::ltbStatus ( ) const

Returns the LTB status.

Definition at line 67 of file LtbHead.cc.

unsigned int LtbHead::localTriggerNumber ( ) const

Returns the local trigger sequence number.

Definition at line 71 of file LtbHead.cc.

bool LtbHead::clockError ( ) const

Returns true if the external clock is not presented or unsteady.

Definition at line 75 of file LtbHead.cc.

unsigned int LtbHead::bufferSize ( ) const [virtual]

Returns the size, in 4-bytes, of this ojbect's contents in the buffer.

Implements DybDaq::DaqBuffer.

Definition at line 79 of file LtbHead.cc.

                                       {
    return ltbTraits().headSize();
}
unsigned int LtbHead::formatComponent ( ) const [protected, virtual]

Returns the component with the format of this buffer.

Reimplemented from DybDaq::DaqBuffer.

Definition at line 51 of file LtbHead.cc.

                                            {
    return LtbTraits::kHead;
}
LtbHead& DybDaq::LtbHead::operator= ( LtbHead rhs) [private]

Suppress default.

void LtbHead::setRawTriggerTotal ( const unsigned int  rawTriggerTotal) [private]

Sets the total number of raw triggers belonging to this trigger.

Definition at line 83 of file LtbHead.cc.

void LtbHead::setRawTriggersSaved ( const unsigned int  rawTriggersSaved) [private]

Sets the total number of raw triggers saved in this trigger.

Definition at line 88 of file LtbHead.cc.

void LtbHead::setLtbStatus ( const unsigned int  ltbStatus) [private]

Sets the LTB status.

Definition at line 93 of file LtbHead.cc.

void LtbHead::setLocalTriggerNumber ( const unsigned int  localTriggerNumber) [private]

Sets the local trigger sequence number.

Definition at line 98 of file LtbHead.cc.

void LtbHead::setClockError ( const bool  clockError) [private]

Sets whether the external clock is not present or unsteady.

Definition at line 103 of file LtbHead.cc.

const LtbTraits & LtbBuffer::ltbTraits ( ) const [inherited]

Returns the LtbTraits instance used to parse this object's buffer.

Definition at line 36 of file LtbBuffer.cc.

                                            {
        return dynamic_cast<const LtbTraits&>(daqTraits());
}

Friends And Related Function Documentation

friend class LtbReadout [friend]

Definition at line 25 of file LtbHead.h.


Member Data Documentation

The LtbTraits instance used to parse this object's buffer.

This is set after construction, so can not use base class's.

Reimplemented from DybDaq::DaqBuffer.

Definition at line 140 of file LtbHead.h.


The documentation for this class was generated from the following files:
| Classes | Job Modules | Data Objects | Services | Algorithms | Tools | Packages | Directories | Tracs |

Generated on Fri May 16 2014 09:53:06 for LtbReadoutFormat by doxygen 1.7.4