FairRoot/PandaRoot
Public Member Functions | Protected Attributes | Friends | List of all members
PndRichTSPDHit Class Reference

#include <PndRichTSPDHit.h>

Inheritance diagram for PndRichTSPDHit:

Public Member Functions

 PndRichTSPDHit ()
 
 PndRichTSPDHit (Int_t detID, Int_t sensorId, TVector3 pos, TVector3 dpos, Double_t time, Double_t timeThreshold)
 
virtual ~PndRichTSPDHit ()
 
virtual void Print (const Option_t *opt="") const
 
virtual Double_t GetTime ()
 
virtual Double_t GetTimeThreshold ()
 
Int_t GetSensorId () const
 
std::vector< Int_t > GetIndices () const
 
void AddIndex (int index)
 
void AddIndex (std::vector< Int_t > index)
 
virtual bool equal (FairTimeStamp *data)
 
virtual bool operator< (const PndRichTSPDHit &hit) const
 
virtual bool operator> (const PndRichTSPDHit &hit) const
 
virtual bool operator== (const PndRichTSPDHit &hit) const
 

Protected Attributes

std::vector< Int_t > fIndex
 
Int_t fDetID
 
Int_t fSensorId
 
TVector3 fPos
 
TVector3 fdPos
 
Double_t fTime
 
Double_t fTimeThreshold
 

Friends

std::ostreamoperator<< (std::ostream &out, PndRichTSPDHit &hit)
 

Detailed Description

Definition at line 14 of file PndRichTSPDHit.h.

Constructor & Destructor Documentation

PndRichTSPDHit::PndRichTSPDHit ( )

Default constructor

Definition at line 15 of file PndRichTSPDHit.cxx.

16  :FairTimeStamp(),
17  fSensorId(-1),
18  fTime(-999.),
19  fTimeThreshold(-999.)
20 {
21 }
Double_t fTimeThreshold
PndRichTSPDHit::PndRichTSPDHit ( Int_t  detID,
Int_t  sensorId,
TVector3  pos,
TVector3  dpos,
Double_t  time,
Double_t  timeThreshold 
)

Definition at line 27 of file PndRichTSPDHit.cxx.

33 :FairTimeStamp(),
34  fDetID (detID),
35  fSensorId (sensorId),
36  fPos (pos),
37  fdPos (dpos),
38  fTime (time),
39  fTimeThreshold (timeThreshold)
40 {
41 }
TVector3 pos
Double_t fTimeThreshold
PndRichTSPDHit::~PndRichTSPDHit ( )
virtual

Destructor

Definition at line 44 of file PndRichTSPDHit.cxx.

44 {}

Member Function Documentation

void PndRichTSPDHit::AddIndex ( int  index)
inline

Definition at line 58 of file PndRichTSPDHit.h.

References fIndex.

59  {
60  fIndex.push_back(index);
61  AddLink(FairLink("PndRichPDHit", index));
62  }
std::vector< Int_t > fIndex
void PndRichTSPDHit::AddIndex ( std::vector< Int_t >  index)
inline

Definition at line 64 of file PndRichTSPDHit.h.

References fIndex.

65  {
66  fIndex = index;
67  AddLinks(FairMultiLinkedData("PndRichPDHit", index));
68  }
std::vector< Int_t > fIndex
virtual bool PndRichTSPDHit::equal ( FairTimeStamp *  data)
inlinevirtual

Definition at line 70 of file PndRichTSPDHit.h.

References fSensorId, GetSensorId(), and hit().

70  {
71  PndRichTSPDHit* hit = dynamic_cast <PndRichTSPDHit*> (data);
72  if (hit != 0){
73  if (fSensorId == hit->GetSensorId()) return true;
74  }
75  return false;
76  }
Int_t GetSensorId() const
int hit(Int_t nEvents=0, TString inFile="sim.root", TString parFile="par.root", TString inDigi="digi.root", TString outFile="hit.root", Int_t timeBased=0)
Definition: hit.C:1
std::vector<Int_t> PndRichTSPDHit::GetIndices ( ) const
inline

Definition at line 56 of file PndRichTSPDHit.h.

References fIndex.

56 { return fIndex;}
std::vector< Int_t > fIndex
Int_t PndRichTSPDHit::GetSensorId ( ) const
inline

Definition at line 55 of file PndRichTSPDHit.h.

References fSensorId.

Referenced by equal(), operator<(), operator==(), and operator>().

55 {return fSensorId;}
virtual Double_t PndRichTSPDHit::GetTime ( )
inlinevirtual

Modifiers Accessors

Definition at line 51 of file PndRichTSPDHit.h.

References fTime.

51 {return fTime;}
virtual Double_t PndRichTSPDHit::GetTimeThreshold ( )
inlinevirtual

Definition at line 52 of file PndRichTSPDHit.h.

References fTimeThreshold.

52 {return fTimeThreshold;}
Double_t fTimeThreshold
virtual bool PndRichTSPDHit::operator< ( const PndRichTSPDHit hit) const
inlinevirtual

Definition at line 78 of file PndRichTSPDHit.h.

References fSensorId, and GetSensorId().

78  {
79  if (fSensorId < hit.GetSensorId()) return true;
80  return false;
81  }
Int_t GetSensorId() const
virtual bool PndRichTSPDHit::operator== ( const PndRichTSPDHit hit) const
inlinevirtual

Definition at line 86 of file PndRichTSPDHit.h.

References fSensorId, and GetSensorId().

86  {
87  if (fSensorId == hit.GetSensorId()) return true;
88  return false;
89  }
Int_t GetSensorId() const
virtual bool PndRichTSPDHit::operator> ( const PndRichTSPDHit hit) const
inlinevirtual

Definition at line 82 of file PndRichTSPDHit.h.

References fSensorId, and GetSensorId().

82  {
83  if (fSensorId > hit.GetSensorId()) return true;
84  return false;
85  }
Int_t GetSensorId() const
void PndRichTSPDHit::Print ( const Option_t *  opt = "") const
virtual

Output to screen

Definition at line 49 of file PndRichTSPDHit.cxx.

References fTime.

49  {
50  cout << "RICH Photon hit: Time = " << fTime << " opt="<<opt<< endl;
51 }

Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream out,
PndRichTSPDHit hit 
)
friend

Definition at line 17 of file PndRichTSPDHit.h.

17  {
18  out << "PndRichTSPDHi in: " << hit.GetSensorId()
19  << ", from Point(s) ";
20  std::vector<Int_t>indices = hit.GetIndices();
21  for (unsigned int i = 0; i < indices.size(); i++){
22  out << indices[i] << " ";
23  }
24  out << std::endl;
25 
26  return out;
27  }
std::vector< Int_t > GetIndices() const
Int_t i
Definition: run_full.C:25
Int_t GetSensorId() const
TFile * out
Definition: reco_muo.C:20

Member Data Documentation

Int_t PndRichTSPDHit::fDetID
protected

Definition at line 94 of file PndRichTSPDHit.h.

TVector3 PndRichTSPDHit::fdPos
protected

Definition at line 97 of file PndRichTSPDHit.h.

std::vector<Int_t> PndRichTSPDHit::fIndex
protected

Definition at line 93 of file PndRichTSPDHit.h.

Referenced by AddIndex(), and GetIndices().

TVector3 PndRichTSPDHit::fPos
protected

Definition at line 96 of file PndRichTSPDHit.h.

Int_t PndRichTSPDHit::fSensorId
protected

Definition at line 95 of file PndRichTSPDHit.h.

Referenced by equal(), GetSensorId(), operator<(), operator==(), and operator>().

Double_t PndRichTSPDHit::fTime
protected

Definition at line 98 of file PndRichTSPDHit.h.

Referenced by GetTime(), and Print().

Double_t PndRichTSPDHit::fTimeThreshold
protected

Definition at line 98 of file PndRichTSPDHit.h.

Referenced by GetTimeThreshold().


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