CbmRoot
Loading...
Searching...
No Matches
CbmMQTsaSampler Class Reference

#include <CbmMQTsaSampler.h>

Inheritance diagram for CbmMQTsaSampler:
[legend]
Collaboration diagram for CbmMQTsaSampler:
[legend]

Public Member Functions

 CbmMQTsaSampler ()
 
virtual ~CbmMQTsaSampler ()
 

Protected Member Functions

virtual void InitTask ()
 
virtual bool ConditionalRun ()
 

Protected Attributes

uint64_t fMaxTimeslices
 
std::string fFileName
 
std::string fDirName
 
std::vector< std::string > fInputFileList
 List of input files.
 
uint64_t fFileCounter
 
std::string fHost
 
uint64_t fPort
 
uint64_t fTSNumber
 
uint64_t fTSCounter
 
uint64_t fMessageCounter
 
int fMaxMemory = 0
 

Private Member Functions

bool OpenNextFile ()
 
bool CheckTimeslice (const fles::Timeslice &ts)
 
void PrintMicroSliceDescriptor (const fles::MicrosliceDescriptor &mdsc)
 
bool SendData (const fles::StorableTimeslice &component)
 
void CalcRuntime ()
 
bool IsChannelNameAllowed (std::string)
 
bool CreateAndSendComponent (const fles::Timeslice &, int)
 
bool SendData (const fles::StorableTimeslice &, int)
 

Private Attributes

fles::TimesliceSource * fSource
 
std::chrono::steady_clock::time_point fTime
 
std::vector< std::string > fAllowedChannels = {"stscomponent", "trdcomponent", "tofcomponent"}
 
std::vector< int > fSysId = {16, 64, 96}
 
std::vector< int > fComponentsToSend = {0, 0, 0}
 
std::vector< std::vector< std::string > > fChannelsToSend = {{}, {}, {}}
 

Detailed Description

CbmMQTsaSampler.h

Since
2017-11-17
Author
F. Uhlig

Definition at line 28 of file CbmMQTsaSampler.h.

Constructor & Destructor Documentation

◆ CbmMQTsaSampler()

CbmMQTsaSampler::CbmMQTsaSampler ( )

Definition at line 47 of file CbmMQTsaSampler.cxx.

◆ ~CbmMQTsaSampler()

CbmMQTsaSampler::~CbmMQTsaSampler ( )
virtual

Definition at line 357 of file CbmMQTsaSampler.cxx.

Member Function Documentation

◆ CalcRuntime()

void CbmMQTsaSampler::CalcRuntime ( )
private

Definition at line 359 of file CbmMQTsaSampler.cxx.

References fTime.

Referenced by ConditionalRun().

◆ CheckTimeslice()

bool CbmMQTsaSampler::CheckTimeslice ( const fles::Timeslice & ts)
private

Definition at line 382 of file CbmMQTsaSampler.cxx.

Referenced by ConditionalRun().

◆ ConditionalRun()

bool CbmMQTsaSampler::ConditionalRun ( )
protectedvirtual

◆ CreateAndSendComponent()

bool CbmMQTsaSampler::CreateAndSendComponent ( const fles::Timeslice & ts,
int nrComp )
private

Definition at line 293 of file CbmMQTsaSampler.cxx.

References fComponentsToSend, fSysId, pos, and SendData().

Referenced by ConditionalRun().

◆ InitTask()

void CbmMQTsaSampler::InitTask ( )
protectedvirtual

◆ IsChannelNameAllowed()

bool CbmMQTsaSampler::IsChannelNameAllowed ( std::string channelName)
private

Definition at line 226 of file CbmMQTsaSampler.cxx.

References fAllowedChannels, fChannelsToSend, fComponentsToSend, and pos.

Referenced by InitTask().

◆ OpenNextFile()

bool CbmMQTsaSampler::OpenNextFile ( )
private

Definition at line 199 of file CbmMQTsaSampler.cxx.

References fFileName, fInputFileList, and fSource.

Referenced by ConditionalRun(), and InitTask().

◆ PrintMicroSliceDescriptor()

void CbmMQTsaSampler::PrintMicroSliceDescriptor ( const fles::MicrosliceDescriptor & mdsc)
private

Definition at line 368 of file CbmMQTsaSampler.cxx.

◆ SendData() [1/2]

bool CbmMQTsaSampler::SendData ( const fles::StorableTimeslice & component,
int idx )
private

Definition at line 321 of file CbmMQTsaSampler.cxx.

References fChannelsToSend, fComponentsToSend, and fMessageCounter.

◆ SendData() [2/2]

bool CbmMQTsaSampler::SendData ( const fles::StorableTimeslice & component)
private

Referenced by CreateAndSendComponent().

Member Data Documentation

◆ fAllowedChannels

std::vector<std::string> CbmMQTsaSampler::fAllowedChannels = {"stscomponent", "trdcomponent", "tofcomponent"}
private

Definition at line 79 of file CbmMQTsaSampler.h.

Referenced by IsChannelNameAllowed().

◆ fChannelsToSend

std::vector<std::vector<std::string> > CbmMQTsaSampler::fChannelsToSend = {{}, {}, {}}
private

Definition at line 84 of file CbmMQTsaSampler.h.

Referenced by IsChannelNameAllowed(), and SendData().

◆ fComponentsToSend

std::vector<int> CbmMQTsaSampler::fComponentsToSend = {0, 0, 0}
private

Definition at line 83 of file CbmMQTsaSampler.h.

Referenced by CreateAndSendComponent(), InitTask(), IsChannelNameAllowed(), and SendData().

◆ fDirName

std::string CbmMQTsaSampler::fDirName
protected

Definition at line 37 of file CbmMQTsaSampler.h.

Referenced by InitTask().

◆ fFileCounter

uint64_t CbmMQTsaSampler::fFileCounter
protected

Definition at line 40 of file CbmMQTsaSampler.h.

◆ fFileName

std::string CbmMQTsaSampler::fFileName
protected

Definition at line 36 of file CbmMQTsaSampler.h.

Referenced by InitTask(), and OpenNextFile().

◆ fHost

std::string CbmMQTsaSampler::fHost
protected

Definition at line 41 of file CbmMQTsaSampler.h.

Referenced by InitTask().

◆ fInputFileList

std::vector<std::string> CbmMQTsaSampler::fInputFileList
protected

List of input files.

Definition at line 39 of file CbmMQTsaSampler.h.

Referenced by InitTask(), and OpenNextFile().

◆ fMaxMemory

int CbmMQTsaSampler::fMaxMemory = 0
protected

Definition at line 48 of file CbmMQTsaSampler.h.

◆ fMaxTimeslices

uint64_t CbmMQTsaSampler::fMaxTimeslices
protected

Definition at line 34 of file CbmMQTsaSampler.h.

Referenced by ConditionalRun(), and InitTask().

◆ fMessageCounter

uint64_t CbmMQTsaSampler::fMessageCounter
protected

Definition at line 46 of file CbmMQTsaSampler.h.

Referenced by SendData().

◆ fPort

uint64_t CbmMQTsaSampler::fPort
protected

Definition at line 42 of file CbmMQTsaSampler.h.

Referenced by InitTask().

◆ fSource

fles::TimesliceSource* CbmMQTsaSampler::fSource
private

Definition at line 64 of file CbmMQTsaSampler.h.

Referenced by ConditionalRun(), InitTask(), and OpenNextFile().

◆ fSysId

std::vector<int> CbmMQTsaSampler::fSysId = {16, 64, 96}
private

Definition at line 80 of file CbmMQTsaSampler.h.

Referenced by CreateAndSendComponent().

◆ fTime

std::chrono::steady_clock::time_point CbmMQTsaSampler::fTime
private

Definition at line 65 of file CbmMQTsaSampler.h.

Referenced by CalcRuntime(), and InitTask().

◆ fTSCounter

uint64_t CbmMQTsaSampler::fTSCounter
protected

Definition at line 45 of file CbmMQTsaSampler.h.

Referenced by ConditionalRun().

◆ fTSNumber

uint64_t CbmMQTsaSampler::fTSNumber
protected

Definition at line 44 of file CbmMQTsaSampler.h.


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