ATLAS Offline Software
Loading...
Searching...
No Matches
TrigMonROBSum Class Reference

#include <TrigMonROBSum.h>

Collaboration diagram for TrigMonROBSum:

Public Member Functions

 TrigMonROBSum ()
 TrigMonROBSum (uint32_t word)
 ~TrigMonROBSum ()
bool setHistory (uint32_t hist)
bool setNROB (uint32_t nrob)
bool setSize (uint32_t size)
bool addROB (const TrigMonROBData &data, int subdet=-1)
uint32_t getWord () const
uint32_t getSize () const
uint32_t getNROB () const
uint32_t getSubDet () const
TrigMonROBData::History getHistory () const
void print (std::ostream &os=std::cout) const

Private Attributes

uint32_t m_word

Detailed Description

Definition at line 24 of file TrigMonROBSum.h.

Constructor & Destructor Documentation

◆ TrigMonROBSum() [1/2]

TrigMonROBSum::TrigMonROBSum ( )

Definition at line 24 of file TrigMonROBSum.cxx.

25 :m_word(0)
26{
27}
uint32_t m_word

◆ TrigMonROBSum() [2/2]

TrigMonROBSum::TrigMonROBSum ( uint32_t word)
explicit

Definition at line 30 of file TrigMonROBSum.cxx.

31 :m_word(word)
32{
33}

◆ ~TrigMonROBSum()

TrigMonROBSum::~TrigMonROBSum ( )
inline

Definition at line 30 of file TrigMonROBSum.h.

30{}

Member Function Documentation

◆ addROB()

bool TrigMonROBSum::addROB ( const TrigMonROBData & data,
int subdet = -1 )

Definition at line 81 of file TrigMonROBSum.cxx.

82{
83 //
84 // Add rob data
85 //
86
87 if(getNROB() > 254) return false;
88 if(getSize() > 1048574) return false;
89
90 setHistory(data.getHistory());
91 setSize(getSize()+data.getROBSize());
92
93 if(subdet < 0) {
94 setNROB(getNROB()+1);
95 }
96 else {
97 setNROB(subdet);
98 }
99
100 return true;
101}
char data[hepevt_bytes_allocation_ATLAS]
Definition HepEvt.cxx:11
uint32_t getNROB() const
bool setSize(uint32_t size)
bool setNROB(uint32_t nrob)
uint32_t getSize() const
bool setHistory(uint32_t hist)

◆ getHistory()

TrigMonROBData::History TrigMonROBSum::getHistory ( ) const

Definition at line 131 of file TrigMonROBSum.cxx.

132{
133 //
134 // Return History enum
135 //
137}
const uint32_t maskHist
TrigMonROBData::History getROBHistory(unsigned int val)

◆ getNROB()

uint32_t TrigMonROBSum::getNROB ( ) const

Definition at line 113 of file TrigMonROBSum.cxx.

114{
115 //
116 // Return History enum
117 //
119}
const uint32_t shiftNrob
const uint32_t maskNrob

◆ getSize()

uint32_t TrigMonROBSum::getSize ( ) const

Definition at line 104 of file TrigMonROBSum.cxx.

105{
106 //
107 // Return History enum
108 //
110}
const uint32_t shiftSize
const uint32_t maskSize

◆ getSubDet()

uint32_t TrigMonROBSum::getSubDet ( ) const

Definition at line 122 of file TrigMonROBSum.cxx.

123{
124 //
125 // Return History enum
126 //
128}

◆ getWord()

uint32_t TrigMonROBSum::getWord ( ) const
inline

Definition at line 38 of file TrigMonROBSum.h.

38{ return m_word; }

◆ print()

void TrigMonROBSum::print ( std::ostream & os = std::cout) const

Definition at line 140 of file TrigMonROBSum.cxx.

◆ setHistory()

bool TrigMonROBSum::setHistory ( uint32_t hist)

Definition at line 36 of file TrigMonROBSum.cxx.

37{
38 //
39 // Set encoded state
40 //
41 if(hist < 16) {
42 m_word = m_word & (~SumBits::maskHist);
43 m_word |= hist;
44 return true;
45 }
46 REPORT_MESSAGE_WITH_CONTEXT(MSG::ERROR, "TrigMonROBSum") << "setHistory: Bad int";
47 return false;
48}
#define REPORT_MESSAGE_WITH_CONTEXT(LVL, CONTEXT_NAME)
Report a message, with an explicitly specified context name.

◆ setNROB()

bool TrigMonROBSum::setNROB ( uint32_t nrob)

Definition at line 51 of file TrigMonROBSum.cxx.

52{
53 //
54 // Set number of robs
55 //
56 if(nrob < 256) {
57 m_word = m_word & (~SumBits::maskNrob);
58 m_word |= (nrob << SumBits::shiftNrob);
59 return true;
60 }
61 REPORT_MESSAGE_WITH_CONTEXT(MSG::ERROR, "TrigMonROBSum") << "setNROB: Bad int";
62 return false;
63}

◆ setSize()

bool TrigMonROBSum::setSize ( uint32_t size)

Definition at line 66 of file TrigMonROBSum.cxx.

67{
68 //
69 // Set number of robs
70 //
71 if(size < 1048576) {
72 m_word = m_word & (~SumBits::maskSize);
73 m_word |= (size << SumBits::shiftSize);
74 return true;
75 }
76 REPORT_MESSAGE_WITH_CONTEXT(MSG::ERROR, "TrigMonROBSum") << "setSize: Bad int";
77 return false;
78}

Member Data Documentation

◆ m_word

uint32_t TrigMonROBSum::m_word
private

Definition at line 49 of file TrigMonROBSum.h.


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