CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
PixelDetectorConfig.h
Go to the documentation of this file.
1 #ifndef PixelDetectorConfig_h
2 #define PixelDetectorConfig_h
3 
11 //
12 // This class specifies which detector
13 // components are used in the configuration
14 // (and eventually should specify which
15 // xdaq process controlls which components).
16 //
17 //
18 //
19 //
20 
21 #include <vector>
22 #include <set>
23 #include <map>
24 #include <string>
30 
31 namespace pos{
40 
41  public:
42 
43  PixelDetectorConfig(std::vector< std::vector < std::string> > &tableMat);
45 
46  unsigned int getNModules() const;
47 
48  PixelModuleName getModule(unsigned int i) const;
49 
50  const std::vector <PixelModuleName>& getModuleList() const { return modules_; }
51 
52  void addROC( PixelROCName &, std::string statusLabel) ;
53  void addROC( PixelROCName &) ;
54  void removeROC(PixelROCName &) ;
55  const std::map<PixelROCName, PixelROCStatus>& getROCsList() const { return rocs_; } ;
56 
57  void writeASCII(std::string dir="") const;
59  virtual void writeXMLHeader( pos::PixelConfigKey key,
60  int version,
62  std::ofstream *out,
63  std::ofstream *out1 = NULL,
64  std::ofstream *out2 = NULL
65  ) const ;
66  virtual void writeXML( std::ofstream *out,
67  std::ofstream *out1 = NULL ,
68  std::ofstream *out2 = NULL ) const ;
69  virtual void writeXMLTrailer( std::ofstream *out,
70  std::ofstream *out1 = NULL,
71  std::ofstream *out2 = NULL
72  ) const ;
73 
74  bool containsModule(const PixelModuleName& moduleToFind) const ;
75 
76  std::set <unsigned int> getFEDs(PixelNameTranslation* translation) const;
77  std::map <unsigned int, std::set<unsigned int> > getFEDsAndChannels(PixelNameTranslation* translation) const;
78 
79  //friend std::ostream& operator<<(std::ostream& s, const PixelDetectorconfig& config);
80 
81  private:
82 
83  std::vector<PixelModuleName> modules_;
84 
85  std::map<PixelROCName, PixelROCStatus> rocs_;
86 
87  };
88 }
89 /* @} */
90 #endif
int i
Definition: DBlmapReader.cc:9
This file contains the base class for &quot;pixel configuration data&quot; management.
void writeXML(pos::PixelConfigKey key, int version, std::string path) const
std::set< unsigned int > getFEDs(PixelNameTranslation *translation) const
std::map< unsigned int, std::set< unsigned int > > getFEDsAndChannels(PixelNameTranslation *translation) const
virtual void writeXMLHeader(pos::PixelConfigKey key, int version, std::string path, std::ofstream *out, std::ofstream *out1=NULL, std::ofstream *out2=NULL) const
Store mfec, mfecchannel etc.
#define NULL
Definition: scimark2.h:8
unsigned int getNModules() const
This class provides a translation from the naming documents standard to specify the ROC to the corres...
This class implements..
virtual void writeXMLTrailer(std::ofstream *out, std::ofstream *out1=NULL, std::ofstream *out2=NULL) const
This file contains the base class for &quot;pixel configuration data&quot; management.
tuple path
else: Piece not in the list, fine.
PixelDetectorConfig(std::vector< std::vector< std::string > > &tableMat)
std::map< PixelROCName, PixelROCStatus > rocs_
PixelModuleName getModule(unsigned int i) const
This is the documentation about PixelDetectorConfig...
void writeASCII(std::string dir="") const
std::vector< PixelModuleName > modules_
const std::vector< PixelModuleName > & getModuleList() const
This class implements..
tuple out
Definition: dbtoconf.py:99
void addROC(PixelROCName &, std::string statusLabel)
This is the documentation about PixelNameTranslation...
This class implements..
This class implements..
Definition: PixelROCName.h:23
list key
Definition: combine.py:13
bool containsModule(const PixelModuleName &moduleToFind) const
tuple filename
Definition: lut2db_cfg.py:20
dbl *** dir
Definition: mlp_gen.cc:35
const std::map< PixelROCName, PixelROCStatus > & getROCsList() const
void removeROC(PixelROCName &)
This class keeps the possible non-standard status a ROC can have.