BOSS 7.0.2
BESIII Offline Software System
Loading...
Searching...
No Matches
TTrackHEP Class Reference

A class to represent a GEN_HEPEVT particle in tracking. More...

#include <TTrackHEP.h>

Public Member Functions

virtual ~TTrackHEP ()
 Destructor.
 
std::string name (void) const
 returns name.
 
unsigned id (void) const
 returns an id started from 0.
 
int status (void) const
 returns status.
 
int pType (void) const
 returns particle type.
 
TTrackHEPmother (void) const
 returns a pointer to a mother.
 
TTrackHEPchild (unsigned i) const
 returns a pointer to i'th child.
 
const HepLorentzVector & p (void) const
 returns momentum vector.
 
const Hep3Vector & v (void) const
 returns position vector.
 
void dump (const std::string &message=std::string(""), const std::string &prefix=std::string("")) const
 dumps debug information.
 
const AList< TMDCWireHitMC > & hits (void) const
 returns a list of TMDCWireHitMC.
 
const Gen_hepevtgen (void) const
 returns a pointer to Gen_hepevt.
 
virtual ~TTrackHEP ()
 Destructor.
 
std::string name (void) const
 returns name.
 
unsigned id (void) const
 returns an id started from 0.
 
int status (void) const
 returns status.
 
int pType (void) const
 returns particle type.
 
TTrackHEPmother (void) const
 returns a pointer to a mother.
 
TTrackHEPchild (unsigned i) const
 returns a pointer to i'th child.
 
const HepLorentzVector & p (void) const
 returns momentum vector.
 
const Hep3Vector & v (void) const
 returns position vector.
 
void dump (const std::string &message=std::string(""), const std::string &prefix=std::string("")) const
 dumps debug information.
 
const AList< TMDCWireHitMC > & hits (void) const
 returns a list of TMDCWireHitMC.
 
const Gen_hepevtgen (void) const
 returns a pointer to Gen_hepevt.
 

Static Public Member Functions

static const AList< TTrackHEP > & list (void)
 returns a list of TTrackHEP's.
 
static TTrackHEPhep (const Gen_hepevt *)
 returns a pointer to TTrackHEP of given Gen_hepevt.
 
static const AList< TTrackHEP > & list (void)
 returns a list of TTrackHEP's.
 
static TTrackHEPhep (const Gen_hepevt *)
 returns a pointer to TTrackHEP of given Gen_hepevt.
 

Friends

void TMDC::updateMC (void)
 
void TMDC::updateMC (void)
 

Detailed Description

A class to represent a GEN_HEPEVT particle in tracking.

Definition at line 37 of file InstallArea/include/TrkReco/TrkReco/TTrackHEP.h.

Constructor & Destructor Documentation

◆ ~TTrackHEP() [1/2]

TTrackHEP::~TTrackHEP ( )
virtual

Destructor.

Definition at line 55 of file TTrackHEP.cxx.

55 {
56}

◆ ~TTrackHEP() [2/2]

virtual TTrackHEP::~TTrackHEP ( )
virtual

Destructor.

Member Function Documentation

◆ child() [1/2]

TTrackHEP * TTrackHEP::child ( unsigned  i) const
inline

returns a pointer to i'th child.

Definition at line 146 of file InstallArea/include/TrkReco/TrkReco/TTrackHEP.h.

146 {
147 return _children[i];
148}

◆ child() [2/2]

TTrackHEP * TTrackHEP::child ( unsigned  i) const

returns a pointer to i'th child.

◆ dump() [1/2]

void TTrackHEP::dump ( const std::string &  message = std::string(""),
const std::string &  prefix = std::string("") 
) const

dumps debug information.

Definition at line 59 of file TTrackHEP.cxx.

59 {
60 std::cout << pre;
61
62 std::cout << id() << ":";
63 std::cout << pType() << ":";
64 if (_mother) std::cout << _mother->id();
65 else std::cout << "-";
66 std::cout << ":";
67 std::cout << _p << ":" << _v;
68 std::cout << std::endl;
69}
unsigned id(void) const
returns an id started from 0.
int pType(void) const
returns particle type.

◆ dump() [2/2]

void TTrackHEP::dump ( const std::string &  message = std::string(""),
const std::string &  prefix = std::string("") 
) const

dumps debug information.

◆ gen() [1/2]

const Gen_hepevt * TTrackHEP::gen ( void  ) const
inline

returns a pointer to Gen_hepevt.

Definition at line 184 of file InstallArea/include/TrkReco/TrkReco/TTrackHEP.h.

184 {
185 return _hep;
186}

Referenced by TTrackManager::saveMCTables().

◆ gen() [2/2]

const Gen_hepevt * TTrackHEP::gen ( void  ) const

returns a pointer to Gen_hepevt.

◆ hep() [1/2]

TTrackHEP * TTrackHEP::hep ( const Gen_hepevt h)
inlinestatic

returns a pointer to TTrackHEP of given Gen_hepevt.

Definition at line 164 of file InstallArea/include/TrkReco/TrkReco/TTrackHEP.h.

164 {
165 if (! h) return 0;
166 unsigned id = h->id - 1;
167 return _list[id];
168}

Referenced by TMDCWireHitMC::TMDCWireHitMC().

◆ hep() [2/2]

static TTrackHEP * TTrackHEP::hep ( const Gen_hepevt )
static

returns a pointer to TTrackHEP of given Gen_hepevt.

◆ hits() [1/2]

const AList< TMDCWireHitMC > & TTrackHEP::hits ( void  ) const
inline

returns a list of TMDCWireHitMC.

Definition at line 172 of file InstallArea/include/TrkReco/TrkReco/TTrackHEP.h.

172 {
173 return _hits;
174}

◆ hits() [2/2]

const AList< TMDCWireHitMC > & TTrackHEP::hits ( void  ) const

returns a list of TMDCWireHitMC.

◆ id() [1/2]

unsigned TTrackHEP::id ( void  ) const
inline

returns an id started from 0.

Definition at line 122 of file InstallArea/include/TrkReco/TrkReco/TTrackHEP.h.

122 {
123 return _hep->id - 1;
124}

Referenced by Dump(), TMDCWireHit::dump(), dump(), hep(), TLine0::refine(), and TMLine::refine().

◆ id() [2/2]

unsigned TTrackHEP::id ( void  ) const

returns an id started from 0.

◆ list() [1/2]

const AList< TTrackHEP > & TTrackHEP::list ( void  )
static

returns a list of TTrackHEP's.

Definition at line 72 of file TTrackHEP.cxx.

72 {
73 return _list;
74}

Referenced by Links2HEP(), and TMDC::updateMC().

◆ list() [2/2]

static const AList< TTrackHEP > & TTrackHEP::list ( void  )
static

returns a list of TTrackHEP's.

◆ mother() [1/2]

TTrackHEP * TTrackHEP::mother ( void  ) const
inline

returns a pointer to a mother.

Definition at line 140 of file InstallArea/include/TrkReco/TrkReco/TTrackHEP.h.

140 {
141 return _mother;
142}

◆ mother() [2/2]

TTrackHEP * TTrackHEP::mother ( void  ) const

returns a pointer to a mother.

◆ name() [1/2]

std::string TTrackHEP::name ( void  ) const
inline

returns name.

Definition at line 178 of file InstallArea/include/TrkReco/TrkReco/TTrackHEP.h.

178 {
179 return "mc" + itostring(id());
180}

◆ name() [2/2]

std::string TTrackHEP::name ( void  ) const

returns name.

◆ p() [1/2]

const HepLorentzVector & TTrackHEP::p ( void  ) const
inline

returns momentum vector.

Definition at line 152 of file InstallArea/include/TrkReco/TrkReco/TTrackHEP.h.

152 {
153 return _p;
154}

◆ p() [2/2]

const HepLorentzVector & TTrackHEP::p ( void  ) const

returns momentum vector.

◆ pType() [1/2]

int TTrackHEP::pType ( void  ) const
inline

returns particle type.

Definition at line 134 of file InstallArea/include/TrkReco/TrkReco/TTrackHEP.h.

134 {
135 return _hep->idhep;
136}

Referenced by TPerfectFinder::doit(), and dump().

◆ pType() [2/2]

int TTrackHEP::pType ( void  ) const

returns particle type.

◆ status() [1/2]

int TTrackHEP::status ( void  ) const
inline

returns status.

Definition at line 128 of file InstallArea/include/TrkReco/TrkReco/TTrackHEP.h.

128 {
129 return _hep->isthep;
130}

◆ status() [2/2]

int TTrackHEP::status ( void  ) const

returns status.

◆ v() [1/2]

const Hep3Vector & TTrackHEP::v ( void  ) const
inline

returns position vector.

Definition at line 158 of file InstallArea/include/TrkReco/TrkReco/TTrackHEP.h.

158 {
159 return _v;
160}

◆ v() [2/2]

const Hep3Vector & TTrackHEP::v ( void  ) const

returns position vector.

Friends And Related Function Documentation

◆ TMDC::updateMC [1/2]

void TMDC::updateMC ( void  )
friend

◆ TMDC::updateMC [2/2]

void TMDC::updateMC ( void  )
friend

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