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

#include <TRIGGERidentity.h>

Collaboration diagram for TRIGGERidentity:

Public Member Functions

 TRIGGERidentity ()
 TRIGGERidentity (TrigType, Threshold, bool)
 TRIGGERidentity (const TRIGGERidentity &)
TRIGGERidentityoperator= (const TRIGGERidentity &)
bool operator== (const TRIGGERidentity &) const
bool operator!= (const TRIGGERidentity &) const
bool operator< (const TRIGGERidentity &) const
 operator bool ()
bool operator! ()
TrigType type (void) const
Threshold threshold (void) const
bool overlap (void) const
float pt (void) const
bool searchForHigh (void) const
bool highest (TrigType) const
void Print (std::ostream &, bool) const

Private Attributes

TrigType m_type
Threshold m_threshold
bool m_overlap

Static Private Attributes

static const char s_type_tag [NTYPE][8] = {{"no"}, {"low Pt"}, {"high Pt"}}
static const char s_threshold_tag [NTHRESHOLD][7] = {{"first"}, {"second"}, {"third"}}
static const float s_pt_value [NTYPE][NTHRESHOLD] = {{0., 0., 0.}, {6., 8., 10.}, {11., 20., 40.}}

Detailed Description

Definition at line 20 of file TRIGGERidentity.h.

Constructor & Destructor Documentation

◆ TRIGGERidentity() [1/3]

TRIGGERidentity::TRIGGERidentity ( )

Definition at line 17 of file TRIGGERidentity.cxx.

◆ TRIGGERidentity() [2/3]

TRIGGERidentity::TRIGGERidentity ( TrigType type,
Threshold threshold,
bool flag )

Definition at line 19 of file TRIGGERidentity.cxx.

Threshold threshold(void) const
TrigType type(void) const

◆ TRIGGERidentity() [3/3]

TRIGGERidentity::TRIGGERidentity ( const TRIGGERidentity & id)

Definition at line 21 of file TRIGGERidentity.cxx.

21: m_type(id.type()), m_threshold(id.threshold()), m_overlap(id.overlap()) {}
bool overlap(void) const

Member Function Documentation

◆ highest()

bool TRIGGERidentity::highest ( TrigType type) const

Definition at line 61 of file TRIGGERidentity.cxx.

61 {
62 if (type == High) {
63 if (m_type == High && m_threshold == SecondTh) return true;
64 }
65 if (type == Low) {
66 if (m_type == Low && m_threshold == ThirdTh) return true;
67 }
68 return false;
69}
@ High
@ Low
@ SecondTh
@ ThirdTh

◆ operator bool()

TRIGGERidentity::operator bool ( )

Definition at line 52 of file TRIGGERidentity.cxx.

52 {
53 if (m_type == None)
54 return false;
55 else
56 return true;
57}

◆ operator!()

bool TRIGGERidentity::operator! ( )

Definition at line 59 of file TRIGGERidentity.cxx.

59{ return !(bool)*this; }
setBGCode setTAP setLVL2ErrorBits bool

◆ operator!=()

bool TRIGGERidentity::operator!= ( const TRIGGERidentity & id) const

Definition at line 39 of file TRIGGERidentity.cxx.

39{ return !(*this == id); }

◆ operator<()

bool TRIGGERidentity::operator< ( const TRIGGERidentity & id) const

Definition at line 41 of file TRIGGERidentity.cxx.

41 {
42 if (m_type < id.type()) return true;
43 if (m_type == id.type()) {
44 if (m_threshold < id.threshold()) return true;
45 if (m_threshold == id.threshold()) {
46 if (m_overlap < id.overlap()) return true;
47 }
48 }
49 return false;
50}

◆ operator=()

TRIGGERidentity & TRIGGERidentity::operator= ( const TRIGGERidentity & id)

Definition at line 23 of file TRIGGERidentity.cxx.

23 {
24 if (this != &id) {
25 m_type = id.type();
26 m_threshold = id.threshold();
27 m_overlap = id.overlap();
28 }
29 return *this;
30}

◆ operator==()

bool TRIGGERidentity::operator== ( const TRIGGERidentity & id) const

Definition at line 32 of file TRIGGERidentity.cxx.

32 {
33 if (m_type == id.type() && m_threshold == id.threshold() && m_overlap == id.overlap())
34 return true;
35 else
36 return false;
37}

◆ overlap()

bool TRIGGERidentity::overlap ( void ) const
inline

Definition at line 46 of file TRIGGERidentity.h.

46{ return m_overlap; }

◆ Print()

void TRIGGERidentity::Print ( std::ostream & stream,
bool detail ) const

Definition at line 79 of file TRIGGERidentity.cxx.

79 {
80 detail = true;
81 if (detail) {
82 stream << s_type_tag[type()] << " trigger, " << s_threshold_tag[threshold()] << " threshold fired (" << std::setw(4)
83 << s_pt_value[type()][threshold()] << " GeV), overlap flag ";
84 if (overlap())
85 stream << "ON";
86 else
87 stream << "OFF";
88 }
89}
static const float s_pt_value[NTYPE][NTHRESHOLD]
static const char s_type_tag[NTYPE][8]
static const char s_threshold_tag[NTHRESHOLD][7]

◆ pt()

float TRIGGERidentity::pt ( void ) const
inline

Definition at line 47 of file TRIGGERidentity.h.

47{ return s_pt_value[m_type][m_threshold]; }

◆ searchForHigh()

bool TRIGGERidentity::searchForHigh ( void ) const

Definition at line 71 of file TRIGGERidentity.cxx.

71 {
72 TRIGGERidentity maxLow(Low, ThirdTh, false);
73 if (*this < maxLow)
74 return false;
75 else
76 return true;
77}

◆ threshold()

Threshold TRIGGERidentity::threshold ( void ) const
inline

Definition at line 45 of file TRIGGERidentity.h.

45{ return m_threshold; }

◆ type()

TrigType TRIGGERidentity::type ( void ) const
inline

Definition at line 44 of file TRIGGERidentity.h.

44{ return m_type; }

Member Data Documentation

◆ m_overlap

bool TRIGGERidentity::m_overlap
private

Definition at line 29 of file TRIGGERidentity.h.

◆ m_threshold

Threshold TRIGGERidentity::m_threshold
private

Definition at line 28 of file TRIGGERidentity.h.

◆ m_type

TrigType TRIGGERidentity::m_type
private

Definition at line 27 of file TRIGGERidentity.h.

◆ s_pt_value

const float TRIGGERidentity::s_pt_value = {{0., 0., 0.}, {6., 8., 10.}, {11., 20., 40.}}
staticprivate

Definition at line 13 of file TRIGGERidentity.h.

◆ s_threshold_tag

const char TRIGGERidentity::s_threshold_tag = {{"first"}, {"second"}, {"third"}}
staticprivate

Definition at line 12 of file TRIGGERidentity.h.

◆ s_type_tag

const char TRIGGERidentity::s_type_tag = {{"no"}, {"low Pt"}, {"high Pt"}}
staticprivate

Definition at line 11 of file TRIGGERidentity.h.


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