Geant4  10.03.p02
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
ExExChSensitiveDetector Class Reference

#include <ExExChSensitiveDetector.hh>

Inheritance diagram for ExExChSensitiveDetector:
Collaboration diagram for ExExChSensitiveDetector:

Public Member Functions

 ExExChSensitiveDetector (G4String name)
 
virtual ~ExExChSensitiveDetector ()
 
virtual void Initialize (G4HCofThisEvent *HCE)
 
virtual G4bool ProcessHits (G4Step *aStep, G4TouchableHistory *ROhist)
 
virtual void EndOfEvent (G4HCofThisEvent *HCE)
 
- Public Member Functions inherited from G4VSensitiveDetector
 G4VSensitiveDetector (G4String name)
 
 G4VSensitiveDetector (const G4VSensitiveDetector &right)
 
virtual ~G4VSensitiveDetector ()
 
G4VSensitiveDetectoroperator= (const G4VSensitiveDetector &right)
 
G4int operator== (const G4VSensitiveDetector &right) const
 
G4int operator!= (const G4VSensitiveDetector &right) const
 
virtual void clear ()
 
virtual void DrawAll ()
 
virtual void PrintAll ()
 
G4bool Hit (G4Step *aStep)
 
void SetROgeometry (G4VReadOutGeometry *value)
 
void SetFilter (G4VSDFilter *value)
 
G4int GetNumberOfCollections () const
 
G4String GetCollectionName (G4int id) const
 
void SetVerboseLevel (G4int vl)
 
void Activate (G4bool activeFlag)
 
G4bool isActive () const
 
G4String GetName () const
 
G4String GetPathName () const
 
G4String GetFullPathName () const
 
G4VReadOutGeometryGetROgeometry () const
 
G4VSDFilterGetFilter () const
 
virtual G4VSensitiveDetectorClone () const
 

Additional Inherited Members

- Protected Member Functions inherited from G4VSensitiveDetector
virtual G4int GetCollectionID (G4int i)
 
- Protected Attributes inherited from G4VSensitiveDetector
G4CollectionNameVector collectionName
 
G4String SensitiveDetectorName
 
G4String thePathName
 
G4String fullPathName
 
G4int verboseLevel
 
G4bool active
 
G4VReadOutGeometryROgeometry
 
G4VSDFilterfilter
 

Detailed Description

Definition at line 40 of file ExExChSensitiveDetector.hh.

Constructor & Destructor Documentation

ExExChSensitiveDetector::ExExChSensitiveDetector ( G4String  name)

Definition at line 40 of file ExExChSensitiveDetector.cc.

40  :
42  G4String HCname;
43  collectionName.insert(HCname="collection");
44  fHCID = -1;
45 }
G4VSensitiveDetector(G4String name)
G4CollectionNameVector collectionName

Here is the call graph for this function:

ExExChSensitiveDetector::~ExExChSensitiveDetector ( )
virtual

Definition at line 49 of file ExExChSensitiveDetector.cc.

49  {
50 }

Member Function Documentation

void ExExChSensitiveDetector::EndOfEvent ( G4HCofThisEvent HCE)
virtual

Reimplemented from G4VSensitiveDetector.

Definition at line 94 of file ExExChSensitiveDetector.cc.

94  {
95 }
void ExExChSensitiveDetector::Initialize ( G4HCofThisEvent HCE)
virtual

Reimplemented from G4VSensitiveDetector.

Definition at line 54 of file ExExChSensitiveDetector.cc.

54  {
55  fHitsCollection =
57  collectionName[0]);
58  if(fHCID<0){
59  fHCID = G4SDManager::GetSDMpointer()->GetCollectionID(fHitsCollection);
60  }
61  HCE->AddHitsCollection(fHCID,fHitsCollection);
62 }
G4THitsCollection< ExExChSensitiveDetectorHit > ExExChSensitiveDetectorHitsCollection
G4int GetCollectionID(G4String colName)
Definition: G4SDManager.cc:135
void AddHitsCollection(G4int HCID, G4VHitsCollection *aHC)
static G4SDManager * GetSDMpointer()
Definition: G4SDManager.cc:40
G4CollectionNameVector collectionName

Here is the call graph for this function:

G4bool ExExChSensitiveDetector::ProcessHits ( G4Step aStep,
G4TouchableHistory ROhist 
)
virtual

Implements G4VSensitiveDetector.

Definition at line 66 of file ExExChSensitiveDetector.cc.

67  {
68 
69  if(aStep->GetTrack()->GetTrackID()>1) return true;
70 
71  G4StepPoint* postStepPoint = aStep->GetPostStepPoint();
72  if(!(postStepPoint->GetStepStatus() == fGeomBoundary)) return true;
73 
74  G4StepPoint* preStepPoint = aStep->GetPreStepPoint();
75 
76  G4TouchableHistory* theTouchable =
77  (G4TouchableHistory*)(preStepPoint->GetTouchable());
78  G4VPhysicalVolume* thePhysical = theTouchable->GetVolume(0);
79  G4int copyNo = thePhysical->GetCopyNo();
80 
81  G4ThreeVector worldPos = preStepPoint->GetPosition();
82 
84  new ExExChSensitiveDetectorHit(copyNo);
85  aHit->SetLayerID(copyNo);
86  aHit->SetWorldPos(worldPos);
87 
88  fHitsCollection->insert(aHit);
89  return true;
90 }
G4VPhysicalVolume * GetVolume(G4int depth=0) const
G4StepStatus GetStepStatus() const
G4int insert(T *aHit)
const G4VTouchable * GetTouchable() const
int G4int
Definition: G4Types.hh:78
G4StepPoint * GetPreStepPoint() const
const G4ThreeVector & GetPosition() const
G4int GetTrackID() const
G4StepPoint * GetPostStepPoint() const
virtual G4int GetCopyNo() const =0
G4Track * GetTrack() const

Here is the call graph for this function:


The documentation for this class was generated from the following files: