GRSISort
Created by P.C. Bender
Developement Team: P.C. Bender, R. Dunlop, V. Bildstein
An extension of the ROOT analysis Framework
TEagleHit Class Reference

This is class that contains the information about an eagle hit. This class is used to find energy, time, etc. The address is set to 0x100 plus the id of the detector.

Definition at line 29 of file TEagleHit.h.

Public Types

enum  EBitFlag {
  EBitFlag::kIsEnergySet = BIT(0), EBitFlag::kIsChannelSet = BIT(1), EBitFlag::kBit2 = BIT(2), EBitFlag::kBit3 = BIT(3),
  EBitFlag::kIsPPGSet = BIT(4), EBitFlag::kIsTimeSet = BIT(5), EBitFlag::kBit6 = BIT(6), EBitFlag::kBit7 = BIT(7),
  EBitFlag::kBit8 = BIT(8), EBitFlag::kDetHitBit0 = BIT(9), EBitFlag::kDetHitBit1 = BIT(10), EBitFlag::kDetHitBit2 = BIT(11),
  EBitFlag::kDetHitBit3 = BIT(12), EBitFlag::kDetHitBit4 = BIT(13), EBitFlag::kDetHitBit5 = BIT(14), EBitFlag::kDetHitBit6 = BIT(15),
  EBitFlag::kBase = BIT(9), EBitFlag::kIsAllSet = 0xFFFF
}
 
enum  ETimeFlag {
  ETimeFlag::kNoneSet = BIT(0), ETimeFlag::kCFD = BIT(1), ETimeFlag::kWalk = BIT(2), ETimeFlag::kOffset = BIT(3),
  ETimeFlag::kAll = 0xFFFF
}
 

Public Member Functions

 TEagleHit ()
 
 TEagleHit (const TEagleHit &)
 
 TEagleHit (const uint8_t &id, const uint16_t &energy, const uint16_t &time, const uint64_t &eventTime)
 
 ~TEagleHit () override
 
virtual void Add (const TDetectorHit *)
 
void AddWaveformSample (const Short_t &x)
 
virtual void AppendTimeStamp (const Long64_t &x)
 
virtual Float_t Charge () const
 
void Clear (Option_t *opt="") override
 
void ClearChannel ()
 
void ClearEnergy ()
 
virtual void ClearTransients () const
 
void Copy (TObject &) const override
 
void Copy (TObject &, bool) const override
 
virtual void CopyWave (TObject &) const
 
virtual UInt_t GetAddress () const
 
virtual UShort_t GetArrayNumber () const
 
virtual Float_t GetCfd () const
 
TChannelGetChannel () const
 
virtual Float_t GetCharge () const
 
virtual Int_t GetCrystal () const
 
Long64_t GetCycleTimeStamp () const
 
virtual Int_t GetDetector () const
 
virtual double GetEnergy (Option_t *opt="") const
 
virtual Double_t GetEnergyNonlinearity (double energy) const
 
virtual Short_t GetKValue () const
 
const char * GetName () const override
 
TVector3 GetPosition (Double_t dist) const override
 
TVector3 GetPosition () const override
 
EPpgPattern GetPPGStatus () const
 
virtual Int_t GetSegment () const
 
virtual Double_t GetTime (const ETimeFlag &correct_flag=ETimeFlag::kAll, Option_t *opt="") const
 
double GetTimeSinceTapeMove () const
 
virtual Long64_t GetTimeStamp (Option_t *="") const
 
virtual Long64_t GetTimeStampNs (Option_t *opt="") const
 
virtual Int_t GetTimeStampUnit () const
 
const std::vector< Short_t > * GetWaveform () const
 
virtual bool HasWave () const
 
bool operator< (const TDetectorHit &rhs) const
 
void Print (Option_t *opt="") const override
 
void Print (std::ostream &out) const override
 
void SetAddress (const UInt_t &temp_address)
 
virtual void SetCfd (const Float_t &x)
 
virtual void SetCfd (const uint32_t &x)
 
virtual void SetCfd (const Int_t &x)
 
void SetCharge (const Float_t &temp_charge)
 
void SetCharge (const Int_t &temp_charge)
 
Double_t SetEnergy (const double &en) const
 
void SetHitBit (EBitFlag, Bool_t set=true) const
 
void SetKValue (const Short_t &temp_kval)
 
Double_t SetTime (const Double_t &time) const
 
virtual void SetTimeStamp (const Long64_t &x)
 
void SetWaveform (const std::vector< Short_t > &x)
 
bool TestHitBit (EBitFlag flag) const
 

Static Public Member Functions

static bool CompareEnergy (TDetectorHit *lhs, TDetectorHit *rhs)
 
static TVector3 * GetBeamDirection ()
 
static void SetPPGPtr (TPPG *ptr)
 

Protected Member Functions

Bool_t IsChannelSet () const
 
Bool_t IsEnergySet () const
 
Bool_t IsPPGSet () const
 
Bool_t IsTimeSet () const
 

Protected Attributes

UInt_t fAddress {0}
 
TTransientBits< UChar_t > fBitFlags
 
Float_t fCfd {0}
 
Float_t fCharge {0.}
 
Short_t fKValue {0}
 
Double_t fTime {0.}
 
Long64_t fTimeStamp {0}
 
std::vector< Short_t > fWaveform
 

Static Protected Attributes

static TVector3 fBeamDirection
 
static TPPGfPPG = nullptr
 

Private Member Functions

Double_t GetDefaultDistance () const
 

#include <TEagleHit.h>

+ Inheritance diagram for TEagleHit:
+ Collaboration diagram for TEagleHit:

Member Enumeration Documentation

◆ EBitFlag

enum TDetectorHit::EBitFlag
stronginherited
Enumerator
kIsEnergySet 
kIsChannelSet 
kBit2 
kBit3 
kIsPPGSet 
kIsTimeSet 
kBit6 
kBit7 
kBit8 
kDetHitBit0 
kDetHitBit1 
kDetHitBit2 
kDetHitBit3 
kDetHitBit4 
kDetHitBit5 
kDetHitBit6 
kBase 
kIsAllSet 

Definition at line 52 of file TDetectorHit.h.

◆ ETimeFlag

enum TDetectorHit::ETimeFlag
stronginherited
Enumerator
kNoneSet 
kCFD 
kWalk 
kOffset 
kAll 

Definition at line 79 of file TDetectorHit.h.

Constructor & Destructor Documentation

◆ TEagleHit() [1/3]

TEagleHit::TEagleHit ( )

Definition at line 15 of file TEagleHit.cxx.

◆ ~TEagleHit()

TEagleHit::~TEagleHit ( )
overridedefault

◆ TEagleHit() [2/3]

TEagleHit::TEagleHit ( const TEagleHit rhs)

Definition at line 26 of file TEagleHit.cxx.

References Clear(), and Copy().

◆ TEagleHit() [3/3]

TEagleHit::TEagleHit ( const uint8_t &  id,
const uint16_t &  energy,
const uint16_t &  time,
const uint64_t &  eventTime 
)

Member Function Documentation

◆ Add()

virtual void TDetectorHit::Add ( const TDetectorHit )
inlinevirtualinherited

!

Reimplemented in TTdrTigressHit, TGriffinHit, TTdrCloverHit, TFippsHit, and TIfinHit.

Definition at line 187 of file TDetectorHit.h.

◆ AddWaveformSample()

void TDetectorHit::AddWaveformSample ( const Short_t &  x)
inlineinherited

!

Definition at line 121 of file TDetectorHit.h.

References TDetectorHit::fWaveform.

◆ AppendTimeStamp()

virtual void TDetectorHit::AppendTimeStamp ( const Long64_t &  x)
inlinevirtualinherited

!

Definition at line 123 of file TDetectorHit.h.

References TDetectorHit::fTimeStamp.

◆ Charge()

◆ Clear()

void TEagleHit::Clear ( Option_t *  opt = "")
override

!

Definition at line 72 of file TEagleHit.cxx.

References TDetectorHit::Clear().

Referenced by TEagleHit().

◆ ClearChannel()

void TDetectorHit::ClearChannel ( )
inlineinherited

◆ ClearEnergy()

void TDetectorHit::ClearEnergy ( )
inlineinherited

◆ ClearTransients()

virtual void TDetectorHit::ClearTransients ( ) const
inlinevirtualinherited

◆ CompareEnergy()

bool TDetectorHit::CompareEnergy ( TDetectorHit lhs,
TDetectorHit rhs 
)
staticinherited

Definition at line 219 of file TDetectorHit.cxx.

References TDetectorHit::GetEnergy().

◆ Copy() [1/2]

void TEagleHit::Copy ( TObject &  rhs) const
override

!

Definition at line 45 of file TEagleHit.cxx.

References TDetectorHit::Copy().

Referenced by Copy(), and TEagleHit().

◆ Copy() [2/2]

void TEagleHit::Copy ( TObject &  obj,
bool  waveform 
) const
overridevirtual

!

Reimplemented from TDetectorHit.

Definition at line 51 of file TEagleHit.cxx.

References Copy(), and TDetectorHit::CopyWave().

◆ CopyWave()

◆ GetAddress()

◆ GetArrayNumber()

virtual UShort_t TDetectorHit::GetArrayNumber ( ) const
inlinevirtualinherited

! Simply returns the detector number, overwritten for detectors that have crystals/segments

Reimplemented in TTigressHit, TTdrTigressHit, TGriffinHit, TTdrCloverHit, TGriffinBgoHit, TLaBrBgoHit, TFippsBgoHit, TFippsHit, TFippsLaBrBgoHit, TIfinBgoHit, TIfinHit, and TBgoHit.

Definition at line 166 of file TDetectorHit.h.

References TDetectorHit::GetDetector().

Referenced by MakeAnalysisHistograms().

◆ GetBeamDirection()

static TVector3* TDetectorHit::GetBeamDirection ( )
inlinestaticinherited

Definition at line 185 of file TDetectorHit.h.

References TDetectorHit::fBeamDirection.

Referenced by TTigressHit::GetDoppler(), and TSiLiHit::GetDoppler().

◆ GetCfd()

◆ GetChannel()

◆ GetCharge()

◆ GetCrystal()

◆ GetCycleTimeStamp()

◆ GetDefaultDistance()

Double_t TEagleHit::GetDefaultDistance ( ) const
inlineprivate

Definition at line 46 of file TEagleHit.h.

Referenced by GetPosition().

◆ GetDetector()

Int_t TDetectorHit::GetDetector ( ) const
virtualinherited

!

Definition at line 192 of file TDetectorHit.cxx.

References TDetectorHit::GetChannel(), and TChannel::GetDetectorNumber().

Referenced by Addback(), TTigress::AddFragment(), TTigressHit::Compare(), TFipps::CTCorrectedEnergy(), TIfin::CTCorrectedEnergy(), TGriffin::CTCorrectedEnergy(), DefaultFippsSuppression(), DefaultGriffinSuppression(), DefaultIfinSuppression(), DefaultSuppression(), CrossTalk::FillHistograms(), TGriffinBgoHit::GetArrayNumber(), TBgoHit::GetArrayNumber(), TFippsBgoHit::GetArrayNumber(), TIfinBgoHit::GetArrayNumber(), TFippsHit::GetArrayNumber(), TIfinHit::GetArrayNumber(), TLaBrBgoHit::GetArrayNumber(), TFippsLaBrBgoHit::GetArrayNumber(), TTdrCloverHit::GetArrayNumber(), TGriffinHit::GetArrayNumber(), TTigressHit::GetArrayNumber(), TTdrTigressHit::GetArrayNumber(), TDetectorHit::GetArrayNumber(), TSharc::GetDeadLayerThickness(), TSharc::GetDetectorThickness(), TTigressHit::GetLastPosition(), TSharc::GetPadDeadLayerThickness(), TSharc::GetPadThickness(), TPinDiodeHit::GetPosition(), GetPosition(), TFippsLaBrHit::GetPosition(), TFippsHit::GetPosition(), TIfinHit::GetPosition(), TPacesHit::GetPosition(), TTdrSiLiHit::GetPosition(), TTrificHit::GetPosition(), TTdrPlasticHit::GetPosition(), TLaBrHit::GetPosition(), TSceptarHit::GetPosition(), TTigress::GetPosition(), TDescantHit::GetPosition(), TGriffinHit::GetPosition(), TTdrCloverHit::GetPosition(), TTdrTigressHit::GetPosition(), TSharcHit::GetPosition(), TTrific::GetXYGrid(), main(), MakeAnalysisHistograms(), TFippsLaBrHit::Print(), TFippsHit::Print(), TIfinHit::Print(), TPinDiodeHit::Print(), TFippsTACHit::Print(), Print(), TTdrSiLiHit::Print(), TTrificHit::Print(), TPacesHit::Print(), TLaBrHit::Print(), TTdrPlasticHit::Print(), TSharcHit::Print(), TTACHit::Print(), TSceptarHit::Print(), TZeroDegreeHit::Print(), TGriffinHit::Print(), TTdrCloverHit::Print(), TTdrTigressHit::Print(), TDescantHit::Print(), TTipHit::Print(), and PromptCoincidence().

◆ GetEnergy()

double TDetectorHit::GetEnergy ( Option_t *  opt = "") const
virtualinherited

Reimplemented in TCSMHit, TSharcHit, and TSiLiHit.

Definition at line 84 of file TDetectorHit.cxx.

References TChannel::CalibrateENG(), TDetectorHit::Charge(), TDetectorHit::fEnergy, TDetectorHit::fKValue, TDetectorHit::GetChannel(), TDetectorHit::GetEnergyNonlinearity(), TDetectorHit::kIsEnergySet, TDetectorHit::SetEnergy(), TDetectorHit::TestHitBit(), and TChannel::UseCalFileIntegration().

Referenced by TFippsHit::Add(), TIfinHit::Add(), TTdrCloverHit::Add(), TGriffinHit::Add(), TTdrTigressHit::Add(), TFippsHit::CompareEnergy(), TIfinHit::CompareEnergy(), TTdrCloverHit::CompareEnergy(), TGriffinHit::CompareEnergy(), TTdrTigressHit::CompareEnergy(), TDetectorHit::CompareEnergy(), TTigressHit::CompareEnergy(), TFipps::CTCorrectedEnergy(), TIfin::CTCorrectedEnergy(), TGriffin::CTCorrectedEnergy(), DefaultFippsSuppression(), DefaultGriffinSuppression(), DefaultIfinSuppression(), DefaultSuppression(), exAnalysis(), GriffinKValueSelector::FillHistograms(), ExampleFragmentSelector::FillHistograms(), CrossTalk::FillHistograms(), TSharcHit::GetDeltaBackE(), TSharcHit::GetDeltaE(), TSharcHit::GetDeltaFrontE(), TTigressHit::GetDoppler(), TSiLiHit::GetEnergy(), TSharcHit::GetEnergy(), TSiLiHit::GetFitEnergy(), TSharcHit::GetPadE(), TDetectorHit::GetTime(), TFragment::GetTZero(), main(), MakeAnalysisHistograms(), MakeGRIFFINEnergyHsts(), TDetectorHit::operator<(), TFippsLaBrHit::Print(), TFippsHit::Print(), TIfinHit::Print(), TFippsTACHit::Print(), TPinDiodeHit::Print(), Print(), TPacesHit::Print(), TTdrSiLiHit::Print(), TTrificHit::Print(), TLaBrHit::Print(), TTdrPlasticHit::Print(), TTACHit::Print(), TSceptarHit::Print(), TZeroDegreeHit::Print(), TTdrCloverHit::Print(), TGriffinHit::Print(), TTdrTigressHit::Print(), TDescantHit::Print(), TTipHit::Print(), TTigressHit::Print(), PromptCoincidence(), and TTigressHit::SumHit().

◆ GetEnergyNonlinearity()

Double_t TDetectorHit::GetEnergyNonlinearity ( double  energy) const
virtualinherited

◆ GetKValue()

◆ GetName()

const char * TDetectorHit::GetName ( ) const
overrideinherited

◆ GetPosition() [1/2]

TVector3 TEagleHit::GetPosition ( Double_t  dist) const
overridevirtual

!

Reimplemented from TDetectorHit.

Definition at line 59 of file TEagleHit.cxx.

References TDetectorHit::GetDetector(), and TEagle::GetPosition().

◆ GetPosition() [2/2]

TVector3 TEagleHit::GetPosition ( ) const
overridevirtual

!

Reimplemented from TDetectorHit.

Definition at line 66 of file TEagleHit.cxx.

References GetDefaultDistance().

◆ GetPPGStatus()

◆ GetSegment()

◆ GetTime()

Double_t TDetectorHit::GetTime ( const ETimeFlag correct_flag = ETimeFlag::kAll,
Option_t *  opt = "" 
) const
virtualinherited

Returns a time value to the nearest nanosecond!

Reimplemented in TCSMHit.

Definition at line 56 of file TDetectorHit.cxx.

References TDetectorHit::fTime, TDetectorHit::GetCfd(), TDetectorHit::GetChannel(), TDetectorHit::GetEnergy(), TChannel::GetTime(), TDetectorHit::GetTimeStamp(), TDetectorHit::IsTimeSet(), and TDetectorHit::SetTime().

Referenced by TFippsHit::Add(), TIfinHit::Add(), TTdrCloverHit::Add(), TGriffinHit::Add(), TTdrTigressHit::Add(), Addback(), TFipps::CTCorrectedEnergy(), TIfin::CTCorrectedEnergy(), TGriffin::CTCorrectedEnergy(), DefaultAddback(), DefaultFippsSuppression(), DefaultGriffinSuppression(), DefaultIfinSuppression(), DefaultSuppression(), exAnalysis(), TSiLi::fCoincidenceTime(), TSharcHit::GetDeltaBackT(), TSharcHit::GetDeltaFrontT(), TSharcHit::GetDeltaT(), TSharcHit::GetPadT(), TFippsTACHit::GetTempCorrectedCharge(), TTACHit::GetTempCorrectedCharge(), TDetectorHit::GetTimeSinceTapeMove(), main(), MakeAnalysisHistograms(), TFippsLaBrHit::Print(), TFippsHit::Print(), TIfinHit::Print(), TPinDiodeHit::Print(), TFippsTACHit::Print(), TTrificHit::Print(), TPacesHit::Print(), TTdrSiLiHit::Print(), TLaBrHit::Print(), TTdrPlasticHit::Print(), TTACHit::Print(), TSceptarHit::Print(), TZeroDegreeHit::Print(), TGriffinHit::Print(), TTdrCloverHit::Print(), TTdrTigressHit::Print(), TDescantHit::Print(), TTipHit::Print(), TDetectorHit::Print(), TTigressHit::Print(), PromptCoincidence(), TTigressHit::SumHit(), TFippsTACHit::TempCorrectedCharge(), and TTACHit::TempCorrectedCharge().

◆ GetTimeSinceTapeMove()

double TDetectorHit::GetTimeSinceTapeMove ( ) const
inherited

returns time in ns, minus the time of the last tape move

Definition at line 274 of file TDetectorHit.cxx.

References TSingleton< TPPG >::Get(), TPPG::GetLastStatusTime(), TDetectorHit::GetTime(), TDetectorHit::GetTimeStampNs(), and kTapeMove.

◆ GetTimeStamp()

◆ GetTimeStampNs()

◆ GetTimeStampUnit()

Int_t TDetectorHit::GetTimeStampUnit ( ) const
virtualinherited

◆ GetWaveform()

const std::vector<Short_t>* TDetectorHit::GetWaveform ( ) const
inlineinherited

◆ HasWave()

virtual bool TDetectorHit::HasWave ( ) const
inlinevirtualinherited

!

Definition at line 107 of file TDetectorHit.h.

References TDetectorHit::fWaveform.

Referenced by TFragment::Print(), and TPulseAnalyzer::SetData().

◆ IsChannelSet()

Bool_t TDetectorHit::IsChannelSet ( ) const
inlineprotectedinherited

◆ IsEnergySet()

Bool_t TDetectorHit::IsEnergySet ( ) const
inlineprotectedinherited

◆ IsPPGSet()

Bool_t TDetectorHit::IsPPGSet ( ) const
inlineprotectedinherited

◆ IsTimeSet()

Bool_t TDetectorHit::IsTimeSet ( ) const
inlineprotectedinherited

◆ operator<()

bool TDetectorHit::operator< ( const TDetectorHit rhs) const
inlineinherited

Definition at line 93 of file TDetectorHit.h.

References TDetectorHit::GetEnergy().

◆ Print() [1/2]

void TEagleHit::Print ( Option_t *  opt = "") const
override

!

Prints the EagleHit information

Definition at line 78 of file TEagleHit.cxx.

◆ Print() [2/2]

void TEagleHit::Print ( std::ostream &  out) const
overridevirtual

!

Prints the EagleHit information in a thread-safe way

Reimplemented from TDetectorHit.

Definition at line 84 of file TEagleHit.cxx.

References TDetectorHit::GetAddress(), TDetectorHit::GetCfd(), TDetectorHit::GetDetector(), TDetectorHit::GetEnergy(), TDetectorHit::GetTimeStamp(), and hex().

◆ SetAddress()

void TDetectorHit::SetAddress ( const UInt_t &  temp_address)
inlineinherited

◆ SetCfd() [1/3]

virtual void TDetectorHit::SetCfd ( const Float_t &  x)
inlinevirtualinherited

◆ SetCfd() [2/3]

virtual void TDetectorHit::SetCfd ( const uint32_t &  x)
inlinevirtualinherited

! this function automatically randomizes the integer provided

Definition at line 118 of file TDetectorHit.h.

References TDetectorHit::fCfd.

◆ SetCfd() [3/3]

virtual void TDetectorHit::SetCfd ( const Int_t &  x)
inlinevirtualinherited

! this function automatically randomizes the integer provided

Definition at line 119 of file TDetectorHit.h.

References TDetectorHit::fCfd.

◆ SetCharge() [1/2]

void TDetectorHit::SetCharge ( const Float_t &  temp_charge)
inlineinherited

◆ SetCharge() [2/2]

void TDetectorHit::SetCharge ( const Int_t &  temp_charge)
inlineinherited

! this function automatically randomizes the integer provided

Definition at line 116 of file TDetectorHit.h.

References TDetectorHit::fCharge.

◆ SetEnergy()

◆ SetHitBit()

◆ SetKValue()

void TDetectorHit::SetKValue ( const Short_t &  temp_kval)
inlineinherited

◆ SetPPGPtr()

static void TDetectorHit::SetPPGPtr ( TPPG ptr)
inlinestaticinherited

Definition at line 91 of file TDetectorHit.h.

References TDetectorHit::fPPG.

◆ SetTime()

Double_t TDetectorHit::SetTime ( const Double_t &  time) const
inlineinherited

◆ SetTimeStamp()

virtual void TDetectorHit::SetTimeStamp ( const Long64_t &  x)
inlinevirtualinherited

!

Definition at line 122 of file TDetectorHit.h.

References TDetectorHit::fTimeStamp.

Referenced by TEmma::BuildHits().

◆ SetWaveform()

void TDetectorHit::SetWaveform ( const std::vector< Short_t > &  x)
inlineinherited

◆ TestHitBit()

bool TDetectorHit::TestHitBit ( EBitFlag  flag) const
inlineinherited

Member Data Documentation

◆ fAddress

◆ fBeamDirection

TVector3 TDetectorHit::fBeamDirection
staticprotectedinherited

Definition at line 222 of file TDetectorHit.h.

Referenced by TDetectorHit::GetBeamDirection().

◆ fBitFlags

◆ fCfd

◆ fCharge

Float_t TDetectorHit::fCharge {0.}
protectedinherited

◆ fKValue

◆ fPPG

TPPG * TDetectorHit::fPPG = nullptr
staticprotectedinherited

Definition at line 219 of file TDetectorHit.h.

Referenced by TGriffinHit::Clear(), TGriffinHit::Copy(), and TDetectorHit::SetPPGPtr().

◆ fTime

Double_t TDetectorHit::fTime {0.}
mutableprotectedinherited

! Calibrated Time of the hit

Definition at line 209 of file TDetectorHit.h.

Referenced by TDetectorHit::Clear(), TDetectorHit::Copy(), TDetectorHit::GetTime(), and TDetectorHit::SetTime().

◆ fTimeStamp

◆ fWaveform