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

#include <TileTTL1Cell.h>

Collaboration diagram for TileTTL1Cell:

Public Types

enum  QUALITY_BITS {
  MASK_BADTOWER = 0x04 , MASK_BADCELL = 0x02 , MASK_BADCHAN = 0x01 , SHIFT_BADTOWER = 2 ,
  SHIFT_BADCELL = 1 , SHIFT_BADCHAN = 0
}
 definition of various bits in quality More...

Public Member Functions

 TileTTL1Cell ()
 default constructor
 TileTTL1Cell (const Identifier &id, float energy, float time, float correction_factor, uint16_t quality)
 constructor for TileTTL1Cell
 ~TileTTL1Cell ()=default
 destructor
void setEnergy (float ene)
 all set methods
void setTime (float tave)
 set average cell time
void setCorrectionFactor (float corrfact)
 set correction factor
void setQuality (uint16_t qual)
 set quality bits for one tower
const IdentifierTTL1_ID () const
 all get methods
Identifier identify (void) const
float eneTower (void) const
 get energy for tower (data member)
float timeAve (void) const
 get time average for all cells in tower (data member)
float corrFactor (void) const
 get tower correction factor (data member)
uint16_t qualTower (void) const
 get quality factor for (data member)
bool cellbad (void) const
 check if tower has bad cell
bool towerbad (void) const
 check if tower is bad
bool chanbad (void) const
 check if a pmt is bad
std::string whoami (void) const
 get name of the object
void print (void) const
 print all cell data memebers to stdout
 operator std::string () const
 Convertion operator to a std::string Can be used in a cast operation : (std::string) TileTTL1Cell.

Private Attributes

Identifier m_ID
 ID = trigger tower id.
float m_eneTower
 eneTower = sum of cell energies
float m_timeAve
 timeAve = time average of cell times.
float m_corrFactor
 corrFactor = energy correction factors applied to tower
uint16_t m_quality
 quality = quality bit for cell and PMTs in tower

Detailed Description

Definition at line 37 of file TileTTL1Cell.h.

Member Enumeration Documentation

◆ QUALITY_BITS

definition of various bits in quality

Enumerator
MASK_BADTOWER 
MASK_BADCELL 
MASK_BADCHAN 
SHIFT_BADTOWER 
SHIFT_BADCELL 
SHIFT_BADCHAN 

Definition at line 42 of file TileTTL1Cell.h.

42 {
43 MASK_BADTOWER = 0x04,
44 MASK_BADCELL = 0x02,
45 MASK_BADCHAN = 0x01,
46
48 SHIFT_BADCELL = 1,
49 SHIFT_BADCHAN = 0
50 };

Constructor & Destructor Documentation

◆ TileTTL1Cell() [1/2]

TileTTL1Cell::TileTTL1Cell ( )
inline

default constructor

Definition at line 53 of file TileTTL1Cell.h.

54 : m_eneTower(0.0),
55 m_timeAve(0.0),
56 m_corrFactor(0.0),
57 m_quality(0)
58 {}
uint16_t m_quality
quality = quality bit for cell and PMTs in tower
float m_corrFactor
corrFactor = energy correction factors applied to tower
float m_eneTower
eneTower = sum of cell energies
float m_timeAve
timeAve = time average of cell times.

◆ TileTTL1Cell() [2/2]

TileTTL1Cell::TileTTL1Cell ( const Identifier & id,
float energy,
float time,
float correction_factor,
uint16_t quality )

constructor for TileTTL1Cell

Definition at line 40 of file TileTTL1Cell.cxx.

43 : m_ID(id)
44 , m_eneTower(energy)
45 , m_timeAve(time)
46 , m_corrFactor(correction_factor)
47 , m_quality(quality)
48{
49}
Identifier m_ID
ID = trigger tower id.

◆ ~TileTTL1Cell()

TileTTL1Cell::~TileTTL1Cell ( )
default

destructor

Member Function Documentation

◆ cellbad()

bool TileTTL1Cell::cellbad ( void ) const
inline

check if tower has bad cell

Definition at line 93 of file TileTTL1Cell.h.

93{ return ((m_quality&TileTTL1Cell::MASK_BADCELL) != 0); }

◆ chanbad()

bool TileTTL1Cell::chanbad ( void ) const
inline

check if a pmt is bad

Definition at line 97 of file TileTTL1Cell.h.

97{ return ((m_quality&TileTTL1Cell::MASK_BADCHAN) != 0); }

◆ corrFactor()

float TileTTL1Cell::corrFactor ( void ) const
inline

get tower correction factor (data member)

Definition at line 88 of file TileTTL1Cell.h.

88{ return m_corrFactor; }

◆ eneTower()

float TileTTL1Cell::eneTower ( void ) const
inline

get energy for tower (data member)

Definition at line 84 of file TileTTL1Cell.h.

84{ return m_eneTower; }

◆ identify()

Identifier TileTTL1Cell::identify ( void ) const
inline

Definition at line 81 of file TileTTL1Cell.h.

81{ return m_ID; }

◆ operator std::string()

TileTTL1Cell::operator std::string ( ) const

Convertion operator to a std::string Can be used in a cast operation : (std::string) TileTTL1Cell.

Definition at line 88 of file TileTTL1Cell.cxx.

89{
90 std::ostringstream text(std::ostringstream::out);
91
92 text << whoami();
93 if (s_cabling->getTileTBID()->is_tiletb(m_ID)) {
94 text << "MBTS Id = " << s_cabling->getTileTBID()->to_string(m_ID);
95 } else {
96 text << " Id = " << s_cabling->getCaloLVL1_ID()->show_to_string(m_ID);
97 }
98 text << " tower ene = " << eneTower();
99 text << " ave time = " << timeAve();
100 text << " correction factor = " << corrFactor();
101 text << " qual = " << qualTower();
102
103 return text.str();
104}
uint16_t qualTower(void) const
get quality factor for (data member)
float corrFactor(void) const
get tower correction factor (data member)
float eneTower(void) const
get energy for tower (data member)
float timeAve(void) const
get time average for all cells in tower (data member)
std::string whoami(void) const
get name of the object

◆ print()

void TileTTL1Cell::print ( void ) const

print all cell data memebers to stdout

Definition at line 83 of file TileTTL1Cell.cxx.

84{
85 std::cout << (std::string) (*this) << std::endl;
86}

◆ qualTower()

uint16_t TileTTL1Cell::qualTower ( void ) const
inline

get quality factor for (data member)

Definition at line 90 of file TileTTL1Cell.h.

90{ return m_quality; }

◆ setCorrectionFactor()

void TileTTL1Cell::setCorrectionFactor ( float corrfact)

set correction factor

Definition at line 62 of file TileTTL1Cell.cxx.

63{
64 m_corrFactor = corrfact;
65}

◆ setEnergy()

void TileTTL1Cell::setEnergy ( float ene)

all set methods

set total tower energy

Definition at line 54 of file TileTTL1Cell.cxx.

55{
56 m_eneTower = ene;
57}

◆ setQuality()

void TileTTL1Cell::setQuality ( uint16_t qual)

set quality bits for one tower

Definition at line 66 of file TileTTL1Cell.cxx.

67{
69}

◆ setTime()

void TileTTL1Cell::setTime ( float tave)

set average cell time

Definition at line 58 of file TileTTL1Cell.cxx.

59{
60 m_timeAve = tave;
61}

◆ timeAve()

float TileTTL1Cell::timeAve ( void ) const
inline

get time average for all cells in tower (data member)

Definition at line 86 of file TileTTL1Cell.h.

86{ return m_timeAve; }

◆ towerbad()

bool TileTTL1Cell::towerbad ( void ) const
inline

check if tower is bad

Definition at line 95 of file TileTTL1Cell.h.

95{ return ((m_quality&TileTTL1Cell::MASK_BADTOWER) != 0); }

◆ TTL1_ID()

const Identifier & TileTTL1Cell::TTL1_ID ( ) const

all get methods

get identifier

Definition at line 75 of file TileTTL1Cell.cxx.

75 {
76 return m_ID;
77}

◆ whoami()

std::string TileTTL1Cell::whoami ( void ) const
inline

get name of the object

Definition at line 100 of file TileTTL1Cell.h.

100{ return "TileTTL1Cell"; }

Member Data Documentation

◆ m_corrFactor

float TileTTL1Cell::m_corrFactor
private

corrFactor = energy correction factors applied to tower

Definition at line 116 of file TileTTL1Cell.h.

◆ m_eneTower

float TileTTL1Cell::m_eneTower
private

eneTower = sum of cell energies

Definition at line 112 of file TileTTL1Cell.h.

◆ m_ID

Identifier TileTTL1Cell::m_ID
private

ID = trigger tower id.

Definition at line 110 of file TileTTL1Cell.h.

◆ m_quality

uint16_t TileTTL1Cell::m_quality
private

quality = quality bit for cell and PMTs in tower

Definition at line 118 of file TileTTL1Cell.h.

◆ m_timeAve

float TileTTL1Cell::m_timeAve
private

timeAve = time average of cell times.

Definition at line 114 of file TileTTL1Cell.h.


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