[233] | 1 | #ifndef G4Lab_HitsCollectionAccessor_h |
---|
| 2 | #define G4Lab_HitsCollectionAccessor_h |
---|
| 3 | |
---|
| 4 | // Inheritance : |
---|
| 5 | #include <OnX/Inventor/InventorAccessor.h> |
---|
| 6 | |
---|
| 7 | #include <G4Transform3D.hh> |
---|
| 8 | |
---|
| 9 | class G4VHitsCollection; |
---|
| 10 | class G4VHit; |
---|
| 11 | class G4LogicalVolume; |
---|
| 12 | class G4Colour; |
---|
| 13 | |
---|
| 14 | namespace Slash {namespace Core {class ISession;}} |
---|
| 15 | namespace Slash {namespace Core {class IWriter;}} |
---|
| 16 | |
---|
| 17 | #include <map> |
---|
| 18 | #include <G4AttDef.hh> |
---|
| 19 | #include <G4String.hh> |
---|
| 20 | |
---|
| 21 | namespace G4Lab { |
---|
| 22 | |
---|
| 23 | class HitsCollectionAccessor : public OnX::InventorAccessor { |
---|
| 24 | public: //Slash::Data::IAccessor |
---|
| 25 | virtual std::string name() const; |
---|
| 26 | virtual Slash::Data::IIterator* iterator(); |
---|
| 27 | virtual Slash::Core::IValue* findValue(Slash::Data::IAccessor::Data,const std::string&,void*); |
---|
| 28 | public: //Slash::Data::IVisualizer |
---|
| 29 | virtual void beginVisualize(); |
---|
| 30 | virtual void visualize(Slash::Data::IAccessor::Data,void*); |
---|
| 31 | public: |
---|
| 32 | HitsCollectionAccessor(Slash::Core::ISession&,const std::string& = ""); |
---|
| 33 | virtual ~HitsCollectionAccessor(); |
---|
| 34 | const std::string& HCName() const; |
---|
| 35 | protected: |
---|
| 36 | static G4LogicalVolume* hitLogicalVolume(const G4VHit&); |
---|
| 37 | static G4Transform3D* hitTransform3D(const G4VHit&); |
---|
| 38 | static bool hitColor(const G4VHit&,G4Colour&); |
---|
| 39 | static G4VHitsCollection* getCollection(Slash::Core::IWriter&,const std::string&); |
---|
| 40 | private: |
---|
| 41 | std::string fType; |
---|
| 42 | std::map<G4String,G4AttDef>* fAttDefs; |
---|
| 43 | std::string fHC; |
---|
| 44 | }; |
---|
| 45 | |
---|
| 46 | } |
---|
| 47 | |
---|
| 48 | #endif |
---|