Public Member Functions | Protected Types | Protected Attributes

roc::Iterator Class Reference

#include <Iterator.h>

Collaboration diagram for roc::Iterator:
Collaboration graph
[legend]

Public Member Functions

 Iterator (int fmt=formatNormal)
 Iterator (base::Board *brd, bool owner=false)
 Iterator (const Iterator &src)
 Iterator (const char *filename)
virtual ~Iterator ()
void setFormat (int fmt)
int getFormat () const
bool isFile () const
void setRocNumber (uint16_t rocnum=0)
uint32_t getMsgSize () const
bool assign (void *buf, uint32_t len)
bool nextBuffer (base::Board *brd, double tmout=1.)
void resetEpochs ()
bool next (double tmout=1.)
bool islast () const
bool last ()
bool prev ()
uint32_t getLastEpoch () const
uint32_t getLastEpoch2 (unsigned n=0) const
Messagemsg ()
uint32_t getMsgEpoch () const
uint64_t getMsgFullTime () const
double getMsgFullTimeD () const
void printMessage (unsigned kind=msg_print_Prefix|msg_print_Data)
void printMessages (unsigned cnt=100, unsigned kind=msg_print_Prefix|msg_print_Data)

Protected Types

enum  { MaxGet4 = 16 }

Protected Attributes

int fFormat
void * fBuffer
uint32_t fBufferLen
uint32_t fBufferPos
uint32_t fMsgSize
Message fMsg
uint32_t fEpoch
uint32_t fEpoch2 [MaxGet4]
base::BoardfBoard
bool fOwner

Detailed Description

Definition at line 10 of file Iterator.h.


Member Enumeration Documentation

anonymous enum [protected]
Enumerator:
MaxGet4 

Definition at line 12 of file Iterator.h.


Constructor & Destructor Documentation

roc::Iterator::Iterator ( int  fmt = formatNormal  ) 

Definition at line 3 of file Iterator.cxx.

References fEpoch2, fFormat, fMsgSize, and roc::Message::RawSize().

roc::Iterator::Iterator ( base::Board brd,
bool  owner = false 
)
roc::Iterator::Iterator ( const Iterator src  ) 

Definition at line 18 of file Iterator.cxx.

References fEpoch2.

roc::Iterator::Iterator ( const char *  filename  ) 
roc::Iterator::~Iterator (  )  [virtual]

Definition at line 73 of file Iterator.cxx.

References base::Board::Close(), fBoard, and fOwner.


Member Function Documentation

bool roc::Iterator::assign ( void *  buf,
uint32_t  len 
)
int roc::Iterator::getFormat (  )  const [inline]

Definition at line 37 of file Iterator.h.

References fFormat.

Referenced by roc::FileInput::getNextBuffer().

uint32_t roc::Iterator::getLastEpoch (  )  const [inline]

Definition at line 92 of file Iterator.h.

References fEpoch.

uint32_t roc::Iterator::getLastEpoch2 ( unsigned  n = 0  )  const [inline]

Definition at line 94 of file Iterator.h.

References fEpoch2, and MaxGet4.

uint32_t roc::Iterator::getMsgEpoch (  )  const [inline]
uint64_t roc::Iterator::getMsgFullTime (  )  const [inline]

Definition at line 110 of file Iterator.h.

References fMsg, getMsgEpoch(), and roc::Message::getMsgFullTime().

double roc::Iterator::getMsgFullTimeD (  )  const [inline]

Definition at line 115 of file Iterator.h.

References fMsg, getMsgEpoch(), and roc::Message::getMsgFullTimeD().

Referenced by nxyter::QuickDaq::testRun().

uint32_t roc::Iterator::getMsgSize (  )  const [inline]

Definition at line 43 of file Iterator.h.

References fMsgSize.

Referenced by roc::CombinerModule::FindNextEvent().

bool roc::Iterator::isFile (  )  const

Definition at line 82 of file Iterator.cxx.

References fBoard, and base::Board::isFile().

bool roc::Iterator::islast (  )  const [inline]

Definition at line 70 of file Iterator.h.

References fBufferLen, and fBufferPos.

bool roc::Iterator::last (  )  [inline]

Definition at line 73 of file Iterator.h.

References fBuffer, fBufferLen, fBufferPos, fMsgSize, and next().

Referenced by roc::FileInput::getNextBuffer().

Message& roc::Iterator::msg (  )  [inline]
bool roc::Iterator::next ( double  tmout = 1.  )  [inline]
bool roc::Iterator::nextBuffer ( base::Board brd,
double  tmout = 1. 
)
bool roc::Iterator::prev (  )  [inline]

Definition at line 83 of file Iterator.h.

References fBuffer, fBufferPos, fMsgSize, and next().

Referenced by roc::Sorter::checkLastEpoch(), and roc::FileInput::getNextBuffer().

void roc::Iterator::printMessage ( unsigned  kind = msg_print_Prefix | msg_print_Data  ) 

Definition at line 134 of file Iterator.cxx.

References getMsgEpoch(), msg(), and roc::Message::printData().

void roc::Iterator::printMessages ( unsigned  cnt = 100,
unsigned  kind = msg_print_Prefix | msg_print_Data 
)

Definition at line 140 of file Iterator.cxx.

References getMsgEpoch(), msg(), next(), and roc::Message::printData().

void roc::Iterator::resetEpochs (  ) 

Definition at line 103 of file Iterator.cxx.

References fEpoch, and fEpoch2.

void roc::Iterator::setFormat ( int  fmt  ) 

Definition at line 90 of file Iterator.cxx.

References fFormat, fMsgSize, and roc::Message::RawSize().

Referenced by InitIterator().

void roc::Iterator::setRocNumber ( uint16_t  rocnum = 0  ) 

Field Documentation

Definition at line 22 of file Iterator.h.

Referenced by isFile(), Iterator(), next(), and ~Iterator().

void* roc::Iterator::fBuffer [protected]

Definition at line 15 of file Iterator.h.

Referenced by assign(), last(), next(), and prev().

uint32_t roc::Iterator::fBufferLen [protected]

Definition at line 16 of file Iterator.h.

Referenced by assign(), islast(), last(), and next().

uint32_t roc::Iterator::fBufferPos [protected]

Definition at line 17 of file Iterator.h.

Referenced by assign(), islast(), last(), next(), and prev().

uint32_t roc::Iterator::fEpoch [protected]

Definition at line 20 of file Iterator.h.

Referenced by getLastEpoch(), getMsgEpoch(), next(), and resetEpochs().

uint32_t roc::Iterator::fEpoch2[MaxGet4] [protected]

Definition at line 21 of file Iterator.h.

Referenced by getLastEpoch2(), getMsgEpoch(), Iterator(), next(), and resetEpochs().

int roc::Iterator::fFormat [protected]

Definition at line 14 of file Iterator.h.

Referenced by getFormat(), Iterator(), next(), nextBuffer(), setFormat(), and setRocNumber().

Definition at line 19 of file Iterator.h.

Referenced by getMsgEpoch(), getMsgFullTime(), getMsgFullTimeD(), msg(), next(), and setRocNumber().

uint32_t roc::Iterator::fMsgSize [protected]

Definition at line 18 of file Iterator.h.

Referenced by assign(), getMsgSize(), Iterator(), last(), next(), nextBuffer(), prev(), and setFormat().

bool roc::Iterator::fOwner [protected]

Definition at line 23 of file Iterator.h.

Referenced by Iterator(), and ~Iterator().


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