ATLAS Offline Software
Loading...
Searching...
No Matches
RpcPad.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3*/
4
5// RpcPad.h
6
7#ifndef RpcPadH
8#define RpcPadH
9
10// M.Grothe, 28/11/02
11// K. Assamagan 07/12/02
12
16#include "Identifier/Identifier.h"
18
19typedef unsigned short int ubit16;
20
21class RpcPad : public DataVector<RpcCoinMatrix> {
22
23public: // functions
24
25 //typedef
26 typedef Identifier ID;
28
29 // Constructors.
30
35 {
36 // std::cout<<"RpcPad default ctor ["<<this<<"]"<<std::endl;
37
38}
39
43
44 RpcPad(const Identifier& id, const IdentifierHash& idHash)
45 : DataVector<RpcCoinMatrix>(), m_id(id), m_idHash(idHash),
47 {
48 // std::cout<<"RpcPad ctor 2 ["<<this<<"]"<<std::endl;
49
50 };
51
56 m_lvl1Id(0), m_bcId(0),
58 {
59 // std::cout<<"RpcPadContainer ctor 3 ["<<this<<"]"<<std::endl;
60
61 };
62
64 RpcPad(const Identifier& id, const IdentifierHash& idHash, ubit16 onlineId,
70 {
71 // std::cout<<"RpcPadContainer ctor 4 ["<<this<<"]"<<std::endl;
72
73 };
74
77 RpcPad(const Identifier& id, const IdentifierHash& idHash, ubit16 onlineId,
78 int sector, ubit16 status)
80 m_lvl1Id(0), m_bcId(0),
82 {
83 // std::cout<<"RpcPadContainer ctor 5 ["<<this<<"]"<<std::endl;
84
85};
86
87 // virtual destructor for persistency
88 virtual ~RpcPad() {
89 // std::cout<<"RpcPadContainer dtor ["<<this<<"]"<<std::endl;
90 // for( auto it : this->stdcont() ) {
91 // for (auto it2 : it->stdcont() ) {
92 // delete it2;
93 // }
94 // delete it;
95 // }
96}
97
98 RpcPad& operator= (RpcPad&&) = default;
99
100 Identifier identify() const { return m_id; }
101
104
105 ubit16 status() const { return m_status; }
106 ubit16 errorCode() const { return m_errorCode; }
107 ubit16 onlineId() const {return m_onlineId; }
108
109 ubit16 lvl1Id() const {return m_lvl1Id; }
110 ubit16 bcId() const {return m_bcId; }
111
112 int sector() const {return m_sector; }
113
114 // This method to be used with the second constructor above
119
122
123private:
125 friend class RpcPadCnv_p1;
126
130
133
137
138};
139
141MsgStream& operator << ( MsgStream& sl, const RpcPad& coll);
142
144std::ostream& operator << ( std::ostream& sl, const RpcPad& coll);
145
146
147CLASS_DEF(RpcPad, 4189, 1)
148
149// Class needed only for persistency
151CLASS_DEF( RPC_PAD_vector, 4181, 1 )
152
153#endif
154
155
156
157
macros to associate a CLID to a type
#define CLASS_DEF(NAME, CID, VERSION)
associate a clid and a version to a type eg
An STL vector of pointers that by default owns its pointed-to elements.
unsigned short int ubit16
DataVector< RpcPad > RPC_PAD_vector
Definition RpcPad.h:150
MsgStream & operator<<(MsgStream &sl, const RpcPad &coll)
Overload of << operator for MsgStream for debug output.
Definition RpcPad.cxx:8
Derived DataVector<T>.
Definition DataVector.h:795
DataVector(SG::OwnershipPolicy ownPolicy=SG::OWN_ELEMENTS, SG::IndexTrackingPolicy trackIndices=SG::DEFAULT_TRACK_INDICES)
This is a "hash" representation of an Identifier.
ubit16 onlineId() const
Definition RpcPad.h:107
ubit16 m_onlineId
Definition RpcPad.h:129
ubit16 errorCode() const
Definition RpcPad.h:106
Identifier identify() const
Definition RpcPad.h:100
RpcPad & operator=(RpcPad &&)=default
virtual ~RpcPad()
Definition RpcPad.h:88
int sector() const
Definition RpcPad.h:112
ubit16 m_bcId
Definition RpcPad.h:132
void setLvl1Id(ubit16 lvl1Id)
Definition RpcPad.h:118
int m_sector
Definition RpcPad.h:136
friend class RpcPadCnv_p1
Definition RpcPad.h:125
RpcPad(const Identifier &id, const IdentifierHash &idHash, ubit16 onlineId, ubit16 lvl1Id, ubit16 bcId, ubit16 status, ubit16 errorCode, int sector)
full constructor with Lvl1 and Bcid
Definition RpcPad.h:64
void setOnlineId(ubit16 onlineId)
Definition RpcPad.h:116
RpcPad()
Default constructor.
Definition RpcPad.h:32
void setStatus(ubit16 status)
Definition RpcPad.h:120
Identifier ID
Definition RpcPad.h:26
void setErrorCode(ubit16 errorCode)
Definition RpcPad.h:115
RpcPad(const Identifier &id, const IdentifierHash &idHash, ubit16 onlineId, int sector, ubit16 status)
partial contructor: needed when filling pad from bytestream errorCode not know until one is reading t...
Definition RpcPad.h:77
Identifier m_id
Definition RpcPad.h:127
RpcPad(const Identifier &id, const IdentifierHash &idHash)
Creates an empty container ready for writing.
Definition RpcPad.h:44
ubit16 m_errorCode
Definition RpcPad.h:135
ubit16 status() const
Definition RpcPad.h:105
ubit16 lvl1Id() const
Definition RpcPad.h:109
void setSector(int sector)
Definition RpcPad.h:121
IdentifierHash identifyHash() const
Returns the OFFLINE identifier hash for this collection.
Definition RpcPad.h:103
ubit16 bcId() const
Definition RpcPad.h:110
void setBcId(ubit16 bcId)
Definition RpcPad.h:117
ubit16 m_lvl1Id
Definition RpcPad.h:131
ubit16 m_status
Definition RpcPad.h:134
IdentifierHash m_idHash
Definition RpcPad.h:128
RpcPad(const Identifier &id, const IdentifierHash &idHash, ubit16 onlineId, ubit16 status, ubit16 errorCode, int sector)
full constructor
Definition RpcPad.h:53
friend class RpcPadContainerCnv_p1
Definition RpcPad.h:124
RpcCoinMatrix DIGIT
Definition RpcPad.h:27