BOSS 7.0.4
BESIII Offline Software System
Loading...
Searching...
No Matches
TrkDetElemId Class Reference

#include <TrkDetElemId.h>

Public Types

enum  systemIndex {
  null =0 , svt =1 , mdc =2 , null =0 ,
  svt =1 , mdc =2
}
 
enum  systemIndex {
  null =0 , svt =1 , mdc =2 , null =0 ,
  svt =1 , mdc =2
}
 

Public Member Functions

 TrkDetElemId (const int &id, TrkDetElemId::systemIndex sysInd)
 
 TrkDetElemId (const TrkDetElemId &)
 
virtual ~TrkDetElemId ()
 
TrkDetElemIdoperator= (const TrkDetElemId &)
 
bool operator== (const TrkDetElemId &rhs) const
 
bool operator< (const TrkDetElemId &rhs) const
 
int elemId () const
 
const int & systemElemId () const
 
const TrkDetElemId::systemIndexsysInd () const
 
void printAll (std::ostream &os=std::cout) const
 
 TrkDetElemId (const int &id, TrkDetElemId::systemIndex sysInd)
 
 TrkDetElemId (const TrkDetElemId &)
 
virtual ~TrkDetElemId ()
 
TrkDetElemIdoperator= (const TrkDetElemId &)
 
bool operator== (const TrkDetElemId &rhs) const
 
bool operator< (const TrkDetElemId &rhs) const
 
int elemId () const
 
const int & systemElemId () const
 
const TrkDetElemId::systemIndexsysInd () const
 
void printAll (std::ostream &os=std::cout) const
 

Static Public Member Functions

static int calcValue (const int &id, TrkDetElemId::systemIndex sysInd)
 
static int calcValue (const int &id, TrkDetElemId::systemIndex sysInd)
 

Detailed Description

Member Enumeration Documentation

◆ systemIndex [1/2]

◆ systemIndex [2/2]

Enumerator
null 
svt 
mdc 
null 
svt 
mdc 

Definition at line 47 of file Reconstruction/MdcPatRec/TrkBase/TrkBase-00-01-12/TrkBase/TrkDetElemId.h.

47 { null=0,
48 svt=1,
49 mdc=2 };

Constructor & Destructor Documentation

◆ TrkDetElemId() [1/4]

TrkDetElemId::TrkDetElemId ( const int &  id,
TrkDetElemId::systemIndex  sysInd 
)

Definition at line 83 of file TrkDetElemId.cxx.

84 :_id(id),_sysInd(sysInd){
85}
const TrkDetElemId::systemIndex & sysInd() const

◆ TrkDetElemId() [2/4]

TrkDetElemId::TrkDetElemId ( const TrkDetElemId rhs)

Definition at line 88 of file TrkDetElemId.cxx.

89 :_id(rhs.systemElemId()),_sysInd(rhs.sysInd()){
90}

◆ ~TrkDetElemId() [1/2]

TrkDetElemId::~TrkDetElemId ( )
virtual

Definition at line 96 of file TrkDetElemId.cxx.

96 {
97}

◆ TrkDetElemId() [3/4]

TrkDetElemId::TrkDetElemId ( const int &  id,
TrkDetElemId::systemIndex  sysInd 
)

◆ TrkDetElemId() [4/4]

TrkDetElemId::TrkDetElemId ( const TrkDetElemId )

◆ ~TrkDetElemId() [2/2]

virtual TrkDetElemId::~TrkDetElemId ( )
virtual

Member Function Documentation

◆ calcValue() [1/2]

int TrkDetElemId::calcValue ( const int &  id,
TrkDetElemId::systemIndex  sysInd 
)
static

Definition at line 59 of file TrkDetElemId.cxx.

60 {
61 int retVal(id);
62 switch (sysInd) {
64 retVal += TrkDetElemId::svtOffset;
65 return retVal;
67 retVal += TrkDetElemId::mdcOffset;
68 return retVal;
69 default:
70 break;
71 }
72 return TrkDetElemId::nullElemID;
73}

Referenced by elemId().

◆ calcValue() [2/2]

static int TrkDetElemId::calcValue ( const int &  id,
TrkDetElemId::systemIndex  sysInd 
)
static

◆ elemId() [1/2]

int TrkDetElemId::elemId ( ) const
inline

Definition at line 88 of file InstallArea/include/TrkBase/TrkBase/TrkDetElemId.h.

88 {
89 return calcValue(_id,_sysInd);
90 };
static int calcValue(const int &id, TrkDetElemId::systemIndex sysInd)

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

◆ elemId() [2/2]

int TrkDetElemId::elemId ( ) const
inline

Definition at line 88 of file Reconstruction/MdcPatRec/TrkBase/TrkBase-00-01-12/TrkBase/TrkDetElemId.h.

88 {
89 return calcValue(_id,_sysInd);
90 };

◆ operator<() [1/2]

bool TrkDetElemId::operator< ( const TrkDetElemId rhs) const
inline

Definition at line 83 of file InstallArea/include/TrkBase/TrkBase/TrkDetElemId.h.

83 {
84 return elemId() < rhs.elemId();
85 }

◆ operator<() [2/2]

bool TrkDetElemId::operator< ( const TrkDetElemId rhs) const
inline

Definition at line 83 of file Reconstruction/MdcPatRec/TrkBase/TrkBase-00-01-12/TrkBase/TrkDetElemId.h.

83 {
84 return elemId() < rhs.elemId();
85 }

◆ operator=() [1/2]

TrkDetElemId & TrkDetElemId::operator= ( const TrkDetElemId rhs)

Definition at line 104 of file TrkDetElemId.cxx.

104 {
105 _id = rhs.systemElemId();
106 _sysInd = rhs.sysInd();
107 return *this;
108}

◆ operator=() [2/2]

TrkDetElemId & TrkDetElemId::operator= ( const TrkDetElemId )

◆ operator==() [1/2]

bool TrkDetElemId::operator== ( const TrkDetElemId rhs) const
inline

Definition at line 80 of file InstallArea/include/TrkBase/TrkBase/TrkDetElemId.h.

80 {
81 return elemId() == rhs.elemId();
82 }

◆ operator==() [2/2]

bool TrkDetElemId::operator== ( const TrkDetElemId rhs) const
inline

Definition at line 80 of file Reconstruction/MdcPatRec/TrkBase/TrkBase-00-01-12/TrkBase/TrkDetElemId.h.

80 {
81 return elemId() == rhs.elemId();
82 }

◆ printAll() [1/2]

void TrkDetElemId::printAll ( std::ostream &  os = std::cout) const

◆ printAll() [2/2]

void TrkDetElemId::printAll ( std::ostream &  os = std::cout) const

◆ sysInd() [1/2]

const TrkDetElemId::systemIndex & TrkDetElemId::sysInd ( ) const
inline

◆ sysInd() [2/2]

const TrkDetElemId::systemIndex & TrkDetElemId::sysInd ( ) const
inline

Definition at line 96 of file Reconstruction/MdcPatRec/TrkBase/TrkBase-00-01-12/TrkBase/TrkDetElemId.h.

96 {
97 return _sysInd;
98 }

◆ systemElemId() [1/2]

const int & TrkDetElemId::systemElemId ( ) const
inline

Definition at line 92 of file InstallArea/include/TrkBase/TrkBase/TrkDetElemId.h.

92 {
93 return _id;
94 }

Referenced by operator=().

◆ systemElemId() [2/2]

const int & TrkDetElemId::systemElemId ( ) const
inline

Definition at line 92 of file Reconstruction/MdcPatRec/TrkBase/TrkBase-00-01-12/TrkBase/TrkDetElemId.h.

92 {
93 return _id;
94 }

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