Geant4  v4-10.4-release
 모두 클래스 네임스페이스들 파일들 함수 변수 타입정의 열거형 타입 열거형 멤버 Friends 매크로 그룹들 페이지들
G4HCIOcatalog.hh
이 파일의 문서화 페이지로 가기
1 //
2 // ********************************************************************
3 // * License and Disclaimer *
4 // * *
5 // * The Geant4 software is copyright of the Copyright Holders of *
6 // * the Geant4 Collaboration. It is provided under the terms and *
7 // * conditions of the Geant4 Software License, included in the file *
8 // * LICENSE and available at http://cern.ch/geant4/license . These *
9 // * include a list of copyright holders. *
10 // * *
11 // * Neither the authors of this software system, nor their employing *
12 // * institutes,nor the agencies providing financial support for this *
13 // * work make any representation or warranty, express or implied, *
14 // * regarding this software system or assume any liability for its *
15 // * use. Please see the license in the file LICENSE and URL above *
16 // * for the full disclaimer and the limitation of liability. *
17 // * *
18 // * This code implementation is the result of the scientific and *
19 // * technical work of the GEANT4 collaboration. *
20 // * By using, copying, modifying or distributing the software (or *
21 // * any work based on the software) you agree to acknowledge its *
22 // * use in resulting scientific publications, and indicate your *
23 // * acceptance of all terms of the Geant4 Software license. *
24 // ********************************************************************
25 //
26 // File: G4HCIOcatalog.hh
27 //
28 // History:
29 // '01.09.12 Youhei Morita Initial creation
30 
31 #ifndef HCIO_CATALOG_HH
32 #define HCIO_CATALOG_HH 1
33 
34 #include <map>
35 #include "G4Types.hh"
36 #include "G4VPHitsCollectionIO.hh"
37 
39 
40 typedef std::map<std::string, G4VHCIOentry*, std::less<std::string> > HCIOmap;
41 
42 typedef std::map<std::string, G4VPHitsCollectionIO*, std::less<std::string> > HCIOstore;
43 
44 // Class Description:
45 // Catalog for the I/O manager of hits collection for each detector.
46 
48 {
49  public: // With description
50  G4HCIOcatalog();
51  // Constructor
52 
53  virtual ~G4HCIOcatalog() {};
54  // Destructor
55 
56  public: // With description
57  static G4HCIOcatalog* GetHCIOcatalog();
58  // Construct G4HCIOcatalog and returns the pointer
59 
60  void SetVerboseLevel(int v) { m_verbose = v; };
61  // Set verbose level.
62 
64  // Register I/O manager entry
65 
67  // Register I/O manager
68 
69  G4VHCIOentry* GetEntry(std::string name);
70  // Returns the I/O manager entry
71 
73  // Returns the registered I/O manager entry
74 
75  void PrintEntries();
76  // Prints the list of I/O manager entries
77 
78  std::string CurrentHCIOmanager();
79  // Returns the list of I/O managers
80 
81  void PrintHCIOmanager();
82  // Prints the list of I/O managers
83 
84  size_t NumberOfHCIOmanager() { return theStore.size(); };
85  // Returns the number of registered I/O managers.
86 
88  // Returns the n-th registered I/O manager entry
89 
90  private:
91  int m_verbose;
95 
96 }; // End of class G4HCIOcatalog
97 
98 #endif
99 
static G4HCIOcatalog * GetHCIOcatalog()
size_t NumberOfHCIOmanager()
const XML_Char * name
Definition: expat.h:151
virtual ~G4HCIOcatalog()
G4VPHitsCollectionIO * GetHCIOmanager(std::string name)
void RegisterHCIOmanager(G4VPHitsCollectionIO *d)
static G4ThreadLocal G4HCIOcatalog * f_thePointer
HCIOstore theStore
#define G4ThreadLocal
Definition: tls.hh:69
std::string CurrentHCIOmanager()
G4VHCIOentry * GetEntry(std::string name)
void PrintHCIOmanager()
Float_t d
std::map< std::string, G4VPHitsCollectionIO *, std::less< std::string > > HCIOstore
std::map< std::string, G4VHCIOentry *, std::less< std::string > > HCIOmap
void RegisterEntry(G4VHCIOentry *d)
Char_t n[5]
void SetVerboseLevel(int v)
HCIOmap theCatalog