ATLAS Offline Software
Public Types | Public Member Functions | Private Attributes | List of all members
RPCrawData Class Reference

#include <RPCrawData.h>

Inheritance diagram for RPCrawData:
Collaboration diagram for RPCrawData:

Public Types

typedef std::list< RPCrawDigitDigitList
 
typedef std::list< const RPCdigit * > digitList
 

Public Member Functions

 RPCrawData ()
 
 RPCrawData (const RPCrawData &)
 
 ~RPCrawData ()
 
RPCrawData operator= (const RPCrawData &)
 
const RPCrawDigitload_data (RPCrawDigit &)
 
const DigitListeta_digits (void) const
 
const DigitListphi_digits (void) const
 
const RPCrawDigitoperator<< (RPCrawDigit &)
 
RPCdata::digitList eta_digits_list (void) const
 
RPCdata::digitList phi_digits_list (void) const
 
virtual int how_many (int type, int sector, int station, int layer, int chamber, int strip) const
 
void PrintElement (std::ostream &, std::string, bool) const
 
ObjectType tag () const
 
std::string name () const
 
virtual void Print (std::ostream &, bool) const
 

Private Attributes

DigitList m_eta_digits
 
DigitList m_phi_digits
 
ObjectType m_tag
 
std::string m_name
 

Detailed Description

Definition at line 17 of file RPCrawData.h.

Member Typedef Documentation

◆ DigitList

typedef std::list< RPCrawDigit > RPCrawData::DigitList

Definition at line 20 of file RPCrawData.h.

◆ digitList

typedef std::list< const RPCdigit* > RPCdata::digitList
inherited

Definition at line 21 of file RPCdata.h.

Constructor & Destructor Documentation

◆ RPCrawData() [1/2]

RPCrawData::RPCrawData ( )

Definition at line 9 of file RPCrawData.cxx.

9  :
10  RPCdata("RPCrawData")
11 {
12  m_eta_digits.clear();
13  m_phi_digits.clear();
14 }

◆ RPCrawData() [2/2]

RPCrawData::RPCrawData ( const RPCrawData data)

Definition at line 16 of file RPCrawData.cxx.

16  :
17  RPCdata(data),
18  m_eta_digits(data.eta_digits()),
19  m_phi_digits(data.phi_digits())
20 {
21 }

◆ ~RPCrawData()

RPCrawData::~RPCrawData ( )

Definition at line 23 of file RPCrawData.cxx.

24 {
25  m_eta_digits.clear();
26  m_phi_digits.clear();
27 }

Member Function Documentation

◆ eta_digits()

const DigitList& RPCrawData::eta_digits ( void  ) const
inline

Definition at line 37 of file RPCrawData.h.

37 {return m_eta_digits;}

◆ eta_digits_list()

RPCdata::digitList RPCrawData::eta_digits_list ( void  ) const
virtual

Implements RPCdata.

Definition at line 81 of file RPCrawData.cxx.

82 {
84  DigitList::const_iterator it = m_eta_digits.begin();
85  while(it != m_eta_digits.end())
86  {
87  list.push_back(&(*it));
88  ++it;
89  }
90  return list;
91 }

◆ how_many()

int RPCrawData::how_many ( int  type,
int  sector,
int  station,
int  layer,
int  chamber,
int  strip 
) const
virtual

Implements RPCdata.

Definition at line 107 of file RPCrawData.cxx.

109 {
110  int size = 0;
111 
112  if(type < 0 || type == 1)
113  {
114  DigitList::const_iterator it = m_phi_digits.begin();
115  while(it != m_phi_digits.end())
116  {
117  if( (sector < 0 || sector == (*it).decoding().logic_sector()) &&
118  (station < 0 || station == (*it).decoding().lvl1_station()) &&
119  (layer < 0 || layer == (*it).decoding().rpc_layer() ) &&
120  (chamber < 0 || chamber == (*it).decoding().rpc_z_index() ) &&
121  (strip < 0 || strip == (*it).decoding().strip_number()) )
122  {
123  ++size;
124  }
125  ++it;
126  }
127  }
128 
129  if(type < 0 || type == 2)
130  {
131  DigitList::const_iterator it = m_eta_digits.begin();
132  while(it != m_eta_digits.end())
133  {
134  if( (sector < 0 || sector == (*it).decoding().logic_sector()) &&
135  (station < 0 || station == (*it).decoding().lvl1_station()) &&
136  (layer < 0 || layer == (*it).decoding().rpc_layer() ) &&
137  (chamber < 0 || chamber == (*it).decoding().rpc_z_index() ) &&
138  (strip < 0 || strip == (*it).decoding().strip_number()) )
139  {
140  ++size;
141  }
142  ++it;
143  }
144  }
145 
146  return size;
147 }

◆ load_data()

const RPCrawDigit * RPCrawData::load_data ( RPCrawDigit digit)

Definition at line 43 of file RPCrawData.cxx.

44 {
45  digit.set_data(*this);
46  if(digit.decoding().view() == Eta)
47  {
48  RPCrawData::DigitList::const_iterator dig = m_eta_digits.begin();
49  while(dig != m_eta_digits.end())
50  {
51  if(*dig == static_cast<RPCdigit&>(digit)) return &(*dig);
52  ++dig;
53  }
54  digit.set_number(m_eta_digits.size()+1);
55  m_eta_digits.push_back(digit);
56  return &m_eta_digits.back();
57  }
58  else if(digit.decoding().view() == Phi)
59  {
60  RPCrawData::DigitList::const_iterator dig = m_phi_digits.begin();
61  while(dig != m_phi_digits.end())
62  {
63  if(*dig == static_cast<RPCdigit&>(digit)) return &(*dig);
64  ++dig;
65  }
66  digit.set_number(m_phi_digits.size()+1);
67  m_phi_digits.push_back(digit);
68  return &m_phi_digits.back();
69  }
70  return 0;
71 }

◆ name()

std::string BaseObject::name ( ) const
inlineinherited

Definition at line 23 of file BaseObject.h.

23 { return m_name; }

◆ operator<<()

const RPCrawDigit * RPCrawData::operator<< ( RPCrawDigit rpc_digit)

Definition at line 74 of file RPCrawData.cxx.

76 {
77  return this->load_data(rpc_digit);
78 }

◆ operator=()

RPCrawData RPCrawData::operator= ( const RPCrawData data)

Definition at line 30 of file RPCrawData.cxx.

31 {
32  m_eta_digits.clear();
33  m_phi_digits.clear();
34 
35  m_eta_digits = data.eta_digits();
36  m_phi_digits = data.phi_digits();
37 
38  return *this;
39 }

◆ phi_digits()

const DigitList& RPCrawData::phi_digits ( void  ) const
inline

Definition at line 38 of file RPCrawData.h.

38 {return m_phi_digits;}

◆ phi_digits_list()

RPCdata::digitList RPCrawData::phi_digits_list ( void  ) const
virtual

Implements RPCdata.

Definition at line 94 of file RPCrawData.cxx.

95 {
97  DigitList::const_iterator it = m_phi_digits.begin();
98  while(it != m_phi_digits.end())
99  {
100  list.push_back(&(*it));
101  ++it;
102  }
103  return list;
104 }

◆ Print()

virtual void BaseObject::Print ( std::ostream &  ,
bool   
) const
inlinevirtualinherited

◆ PrintElement()

void RPCrawData::PrintElement ( std::ostream &  stream,
std::string  element,
bool  detail 
) const

Definition at line 150 of file RPCrawData.cxx.

151 {
152  bool all = (element == name() || element == "")? true : false;
153  bool nEtaDig = m_eta_digits.size();
154  bool nPhiDig = m_phi_digits.size();
155  bool printed = false;
156 
157  if (nEtaDig && (element == (*m_eta_digits.begin()).name() || all))
158  {
159  printed = true;
160  DigitList::const_iterator it = m_eta_digits.begin();
161  while(it != m_eta_digits.end())
162  {
163  it->Print(stream,detail);
164  ++it;
165  }
166  }
167 
168  if (nPhiDig && (element == (*m_phi_digits.begin()).name() || all))
169  {
170  printed = true;
171  DigitList::const_iterator it = m_phi_digits.begin();
172  while(it != m_phi_digits.end())
173  {
174  it->Print(stream,detail);
175  ++it;
176  }
177  }
178 
179  if(!printed)
180  {
181  if( element == "") element = "digits";
182  stream << name() << " contains no " << element << "!" << endl;
183  }
184 }

◆ tag()

ObjectType BaseObject::tag ( ) const
inlineinherited

Definition at line 22 of file BaseObject.h.

22 { return m_tag; }

Member Data Documentation

◆ m_eta_digits

DigitList RPCrawData::m_eta_digits
private

Definition at line 23 of file RPCrawData.h.

◆ m_name

std::string BaseObject::m_name
privateinherited

Definition at line 16 of file BaseObject.h.

◆ m_phi_digits

DigitList RPCrawData::m_phi_digits
private

Definition at line 24 of file RPCrawData.h.

◆ m_tag

ObjectType BaseObject::m_tag
privateinherited

Definition at line 15 of file BaseObject.h.


The documentation for this class was generated from the following files:
data
char data[hepevt_bytes_allocation_ATLAS]
Definition: HepEvt.cxx:11
SiliconTech::strip
@ strip
RPCrawData::m_phi_digits
DigitList m_phi_digits
Definition: RPCrawData.h:24
BaseObject::m_name
std::string m_name
Definition: BaseObject.h:16
calibdata.chamber
chamber
Definition: calibdata.py:32
skel.it
it
Definition: skel.GENtoEVGEN.py:423
detail
Definition: extract_histogram_tag.cxx:14
Phi
@ Phi
Definition: RPCdef.h:8
checkRpcDigits.digit
digit
Definition: checkRpcDigits.py:186
AthenaPoolTestWrite.stream
string stream
Definition: AthenaPoolTestWrite.py:12
RPCrawData::m_eta_digits
DigitList m_eta_digits
Definition: RPCrawData.h:23
python.setupRTTAlg.size
int size
Definition: setupRTTAlg.py:39
TRT::Hit::layer
@ layer
Definition: HitInfo.h:79
BaseObject::name
std::string name() const
Definition: BaseObject.h:23
histSizes.list
def list(name, path='/')
Definition: histSizes.py:38
RPCdata::RPCdata
RPCdata(const std::string &)
Definition: RPCdata.cxx:8
RPCdigit
Definition: RPCdigit.h:16
Cut::all
@ all
Definition: SUSYToolsAlg.cxx:64
BaseObject::m_tag
ObjectType m_tag
Definition: BaseObject.h:15
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
RPCdata::digitList
std::list< const RPCdigit * > digitList
Definition: RPCdata.h:21
RPCrawData::load_data
const RPCrawDigit * load_data(RPCrawDigit &)
Definition: RPCrawData.cxx:43
Eta
@ Eta
Definition: RPCdef.h:8