CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
TIBDetId.cc
Go to the documentation of this file.
2 
4 }
5 TIBDetId::TIBDetId(uint32_t rawid) : SiStripDetId(rawid){
6 }
7 TIBDetId::TIBDetId(const DetId& id) : SiStripDetId(id.rawId()){
8 }
9 
10 bool TIBDetId::isDoubleSide() const {
11  // Double Side: only layers 1 and 2
12  if( this->glued() == 0 && ( this->layer() == 1 || this->layer() == 2 ) ) {
13  return true;
14  } else {
15  return false;
16  }
17 }
18 
19 std::ostream& operator<<(std::ostream& os,const TIBDetId& id) {
20  unsigned int theLayer = id.layer();
21  std::vector<unsigned int> theString = id.string();
22  unsigned int theModule = id.module();
23  std::string side;
24  std::string part;
25  side = (theString[0] == 1 ) ? "-" : "+";
26  part = (theString[1] == 1 ) ? "int" : "ext";
27  std::string type;
28  type = (id.stereo() == 0) ? "r-phi" : "stereo";
29  type = (id.glued() == 0) ? type : type+" glued";
30  type = (id.isDoubleSide()) ? "double side" : type;
31  return os << "TIB" << side
32  << " Layer " << theLayer << " " << part
33  << " String " << theString[2]
34  << " Module " << theModule << " " << type
35  << " (" << id.rawId() << ")";
36 }
37 
type
Definition: HCALResponse.h:22
bool isDoubleSide() const
Definition: TIBDetId.cc:10
TIBDetId()
Definition: TIBDetId.cc:3
std::ostream & operator<<(std::ostream &out, const ALILine &li)
Definition: ALILine.cc:187
Detector identifier class for the strip tracker.
Definition: SiStripDetId.h:17
Definition: DetId.h:20
uint32_t glued() const
Definition: SiStripDetId.h:154
part
Definition: HCALResponse.h:21
unsigned int layer() const
layer id
Definition: TIBDetId.h:41