CMS 3D CMS Logo

RPCBookFolderStructure.h
Go to the documentation of this file.
1 
7 #ifndef RPCBookFolderStructure_H
8 #define RPCBookFolderStructure_H
9 
11 #include <string>
12 #include <sstream>
14 public:
15  explicit RPCBookFolderStructure(){};
17 
19  std::stringstream myStream;
20  myStream.str("");
21 
22  if (detId.region() == 0)
23  myStream << "Barrel/Wheel_" << detId.ring() << "/sector_" << detId.sector() << "/station_" << detId.station();
24  else if (detId.region() == -1)
25  myStream << "Endcap-/Disk_-" << detId.station() << "/ring_" << detId.ring() << "/sector_" << detId.sector();
26  else if (detId.region() == 1)
27  myStream << "Endcap+/Disk_" << detId.station() << "/ring_" << detId.ring() << "/sector_" << detId.sector();
28  else
29  myStream << "Error/Folder/Creation";
30 
31  return myStream.str();
32  }
33 };
34 #endif
int ring() const
Definition: RPCDetId.h:59
std::string folderStructure(RPCDetId detId)
int sector() const
Sector id: the group of chambers at same phi (and increasing r)
Definition: RPCDetId.h:81
int region() const
Region id: 0 for Barrel, +/-1 For +/- Endcap.
Definition: RPCDetId.h:53
int station() const
Definition: RPCDetId.h:78