Analysis Software
Documentation for sPHENIX simulation software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
PHG4DisplayAction.h
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file PHG4DisplayAction.h
1 // Tell emacs that this is a C++ source
2 // -*- C++ -*-.
3 #ifndef G4MAIN_PHG4DISPLAYACTION_H
4 #define G4MAIN_PHG4DISPLAYACTION_H
5 
6 #include <string>
7 
9 
11 {
12  public:
14  // delete default ctor, nobody should use it
15  PHG4DisplayAction() = delete;
16  // this is the ctor we use
18  : m_Detector(name)
19  {
20  }
21 
23  virtual ~PHG4DisplayAction() {}
24 
26 
32  virtual void ApplyDisplayAction(G4VPhysicalVolume *physvol) = 0;
33 
34  virtual void SetName(const std::string &name) { m_Detector = name; }
35 
36  virtual std::string GetName() const { return m_Detector; }
37 
38  virtual void Print(const std::string &/*what*/="ALL") {}
39 
41  {
42  ABORT = -1,
43  FAILED = 0,
44  ACCEPT = 1
45  };
46 
47  protected:
49  /*
50  * @param[in] starting volume
51  */
52  int FindVolumes(G4VPhysicalVolume *physvol);
53 
55  /*
56  * @param[in] physical volume to be checked
57  */
58  virtual int CheckVolume(G4VPhysicalVolume */*physvol*/) { return 0; }
59 
61 
64  virtual void ApplyVisAttributes(G4VPhysicalVolume */*physvol*/) { return; }
65 
66  private:
68 };
69 
70 #endif // G4MAIN_PHG4DISPLAYACTION_H