BOSS 7.0.9
BESIII Offline Software System
Loading...
Searching...
No Matches
CalibData::EsTimeCalibData Class Reference

#include <EsTimeCalibData.h>

+ Inheritance diagram for CalibData::EsTimeCalibData:

Public Member Functions

 EsTimeCalibData ()
 
virtual ~EsTimeCalibData ()
 
virtual const CLID & clID () const
 
virtual StatusCode update (CalibBase1 &other, MsgStream *log)
 
void setTestCalibConst (const vector< double > *TestCalibConst)
 
void setToffsetb (const double toffsetb)
 
void setToffsete (const double toffsete)
 
void setBunchTime (const int bunchtime)
 
void setRunFrom (const int runFrom)
 
void setRunTo (const int runTo)
 
void setEventFrom (const int eventFrom)
 
void setEventTo (const int eventTo)
 
double getTestCalibConst (unsigned int No) const
 
int getTestCalibConstNo () const
 
double getToffsetb ()
 
double getToffsetb (unsigned int No)
 
double getToffsete ()
 
double getToffsete (unsigned int No)
 
double getBunchTime ()
 
double getBunchTime (unsigned int No)
 
unsigned int getSize () const
 
int getRunFrom ()
 
int getRunFrom (unsigned int No)
 
int getRunTo ()
 
int getRunTo (unsigned int No)
 
int getEventFrom ()
 
int getEventFrom (unsigned int No)
 
int getEventTo ()
 
int getEventTo (unsigned int No)
 
- Public Member Functions inherited from CalibData::CalibBase1
 CalibBase1 ()
 
 CalibBase1 (int serNo, int runfrm, int runto)
 
 CalibBase1 (int runfrm, int runto)
 
 CalibBase1 (const CalibBase1 &obj)
 
virtual StatusCode update (CalibBase1 &obj, MsgStream *)
 
virtual int getSerNo () const
 Following is intended for deep copy.
 
virtual int getrunfrm () const
 
virtual int getrunto () const
 
void setSerNo (int ser)
 
void setrunfrm (int runfrm)
 
void setrunto (int runto)
 

Static Public Member Functions

static const CLID & classID ()
 

Additional Inherited Members

- Protected Attributes inherited from CalibData::CalibBase1
int m_serNo
 
int m_runfrm
 
int m_runto
 

Detailed Description

Definition at line 18 of file EsTimeCalibData.h.

Constructor & Destructor Documentation

◆ EsTimeCalibData()

EsTimeCalibData::EsTimeCalibData ( )

Definition at line 8 of file EsTimeCalibData.cxx.

8 :m_TestCalibConst(0){
9 // if( m_TestCalibConst) { delete m_TestCalibConst; }
10 if( m_toffsetb.size()>0 ) { m_toffsetb.clear(); }
11 if( m_toffsete.size()>0 ) { m_toffsete.clear(); }
12 if( m_bunchtime.size()>0 ) { m_bunchtime.clear(); }
13 if( m_runFrom.size()>0 ) { m_runFrom.clear(); }
14 if( m_runTo.size()>0 ) { m_runTo.clear(); }
15 if( m_eventFrom.size()>0 ) { m_eventFrom.clear(); }
16 if( m_eventTo.size()>0 ) { m_eventTo.clear(); }
17 return;
18 }

◆ ~EsTimeCalibData()

virtual CalibData::EsTimeCalibData::~EsTimeCalibData ( )
inlinevirtual

Definition at line 22 of file EsTimeCalibData.h.

22 {
23 if( m_TestCalibConst) { delete m_TestCalibConst; }
24 if( m_toffsetb.size()>0 ) { m_toffsetb.clear(); }
25 if( m_toffsete.size()>0 ) { m_toffsete.clear(); }
26 if( m_bunchtime.size()>0 ) { m_bunchtime.clear(); }
27 if( m_runFrom.size()>0 ) { m_runFrom.clear(); }
28 if( m_runTo.size()>0 ) { m_runTo.clear(); }
29 if( m_eventFrom.size()>0 ) { m_eventFrom.clear(); }
30 if( m_eventTo.size()>0 ) { m_eventTo.clear(); }
31 return;
32 }

Member Function Documentation

◆ classID()

static const CLID & CalibData::EsTimeCalibData::classID ( )
inlinestatic

Definition at line 37 of file EsTimeCalibData.h.

37{ return CLID_Calib_EsTimeCal; }
const CLID CLID_Calib_EsTimeCal
Definition: CalibModel.h:51

Referenced by clID().

◆ clID()

virtual const CLID & CalibData::EsTimeCalibData::clID ( ) const
inlinevirtual

Definition at line 35 of file EsTimeCalibData.h.

35{ return classID(); }
static const CLID & classID()

◆ getBunchTime() [1/2]

double EsTimeCalibData::getBunchTime ( )

Definition at line 117 of file EsTimeCalibData.cxx.

117 {
118 return getBunchTime(0);
119 }

Referenced by getBunchTime().

◆ getBunchTime() [2/2]

double EsTimeCalibData::getBunchTime ( unsigned int  No)

Definition at line 121 of file EsTimeCalibData.cxx.

121 {
122 double bunchtime = 0.0;
123 if( m_bunchtime.size() != 0 ) {
124 vector<int>::iterator it = m_bunchtime.begin() + No;
125 bunchtime = (*it);
126 }
127 return bunchtime;
128 }

◆ getEventFrom() [1/2]

int CalibData::EsTimeCalibData::getEventFrom ( )

◆ getEventFrom() [2/2]

int EsTimeCalibData::getEventFrom ( unsigned int  No)

Definition at line 156 of file EsTimeCalibData.cxx.

156 {
157 int eventFrom = 0.0;
158 if( m_eventFrom.size() != 0 ) {
159 vector<int>::iterator it = m_eventFrom.begin() + No;
160 eventFrom = (*it);
161 }
162 return eventFrom;
163 }

◆ getEventTo() [1/2]

int EsTimeCalibData::getEventTo ( )

Definition at line 165 of file EsTimeCalibData.cxx.

165 {
166 return getEventTo(0);
167 }

Referenced by getEventTo().

◆ getEventTo() [2/2]

int EsTimeCalibData::getEventTo ( unsigned int  No)

Definition at line 169 of file EsTimeCalibData.cxx.

169 {
170 int eventTo = 0.0;
171 if( m_eventTo.size() != 0 ) {
172 vector<int>::iterator it = m_eventTo.begin() + No;
173 eventTo = (*it);
174 }
175 return eventTo;
176 }

◆ getRunFrom() [1/2]

int EsTimeCalibData::getRunFrom ( )

Definition at line 130 of file EsTimeCalibData.cxx.

130 {
131 return getRunFrom(0);
132 }

Referenced by getRunFrom().

◆ getRunFrom() [2/2]

int EsTimeCalibData::getRunFrom ( unsigned int  No)

Definition at line 134 of file EsTimeCalibData.cxx.

134 {
135 int runFrom = 0.0;
136 if( m_runFrom.size() != 0 ) {
137 vector<int>::iterator it = m_runFrom.begin() + No;
138 runFrom = (*it);
139 }
140 return runFrom;
141 }

◆ getRunTo() [1/2]

int EsTimeCalibData::getRunTo ( )

Definition at line 143 of file EsTimeCalibData.cxx.

143 {
144 return getRunTo(0);
145 }

Referenced by getRunTo().

◆ getRunTo() [2/2]

int EsTimeCalibData::getRunTo ( unsigned int  No)

Definition at line 147 of file EsTimeCalibData.cxx.

147 {
148 int runTo = 0.0;
149 if( m_runTo.size() != 0 ) {
150 vector<int>::iterator it = m_runTo.begin() + No;
151 runTo = (*it);
152 }
153 return runTo;
154 }

◆ getSize()

unsigned int CalibData::EsTimeCalibData::getSize ( ) const
inline

Definition at line 65 of file EsTimeCalibData.h.

65{ return m_bunchtime.size(); }

◆ getTestCalibConst()

double CalibData::EsTimeCalibData::getTestCalibConst ( unsigned int  No) const
inline

Definition at line 52 of file EsTimeCalibData.h.

52{ return *((m_TestCalibConst->begin())+No);}

◆ getTestCalibConstNo()

int CalibData::EsTimeCalibData::getTestCalibConstNo ( ) const
inline

Definition at line 54 of file EsTimeCalibData.h.

54{ return m_TestCalibConst->size();}

◆ getToffsetb() [1/2]

double EsTimeCalibData::getToffsetb ( )

Definition at line 91 of file EsTimeCalibData.cxx.

91 {
92 return getToffsetb(0);
93 }

Referenced by getToffsetb().

◆ getToffsetb() [2/2]

double EsTimeCalibData::getToffsetb ( unsigned int  No)

Definition at line 95 of file EsTimeCalibData.cxx.

95 {
96 double toffsetb = 0.0;
97 if( m_toffsetb.size() != 0 ) {
98 vector<double>::iterator it = m_toffsetb.begin() + No;
99 toffsetb = (*it);
100 }
101 return toffsetb;
102 }

◆ getToffsete() [1/2]

double EsTimeCalibData::getToffsete ( )

Definition at line 104 of file EsTimeCalibData.cxx.

104 {
105 return getToffsete(0);
106 }

Referenced by getToffsete().

◆ getToffsete() [2/2]

double EsTimeCalibData::getToffsete ( unsigned int  No)

Definition at line 108 of file EsTimeCalibData.cxx.

108 {
109 double toffsete = 0.0;
110 if( m_toffsete.size() != 0 ) {
111 vector<double>::iterator it = m_toffsete.begin() + No;
112 toffsete = (*it);
113 }
114 return toffsete;
115 }

◆ setBunchTime()

void EsTimeCalibData::setBunchTime ( const int  bunchtime)

Definition at line 66 of file EsTimeCalibData.cxx.

66 {
67 m_bunchtime.push_back( bunchtime );
68 return;
69 }

Referenced by RootEsTimeCalibDataCnv::i_createObj(), and TreeEsTimeCalibDataCnv::i_createObj().

◆ setEventFrom()

void EsTimeCalibData::setEventFrom ( const int  eventFrom)

Definition at line 81 of file EsTimeCalibData.cxx.

81 {
82 m_eventFrom.push_back( eventFrom );
83 return;
84 }

Referenced by RootEsTimeCalibDataCnv::i_createObj(), and TreeEsTimeCalibDataCnv::i_createObj().

◆ setEventTo()

void EsTimeCalibData::setEventTo ( const int  eventTo)

Definition at line 86 of file EsTimeCalibData.cxx.

86 {
87 m_eventTo.push_back( eventTo );
88 return;
89 }

Referenced by RootEsTimeCalibDataCnv::i_createObj(), and TreeEsTimeCalibDataCnv::i_createObj().

◆ setRunFrom()

void EsTimeCalibData::setRunFrom ( const int  runFrom)

Definition at line 71 of file EsTimeCalibData.cxx.

71 {
72 m_runFrom.push_back( runFrom );
73 return;
74 }

Referenced by RootEsTimeCalibDataCnv::i_createObj(), and TreeEsTimeCalibDataCnv::i_createObj().

◆ setRunTo()

void EsTimeCalibData::setRunTo ( const int  runTo)

Definition at line 76 of file EsTimeCalibData.cxx.

76 {
77 m_runTo.push_back( runTo );
78 return;
79 }

Referenced by RootEsTimeCalibDataCnv::i_createObj(), and TreeEsTimeCalibDataCnv::i_createObj().

◆ setTestCalibConst()

void EsTimeCalibData::setTestCalibConst ( const vector< double > *  TestCalibConst)

Definition at line 49 of file EsTimeCalibData.cxx.

49 {
50 if(m_TestCalibConst) delete m_TestCalibConst;
51 m_TestCalibConst = new vector<double>(*TestCalibConst);
52 }

◆ setToffsetb()

void EsTimeCalibData::setToffsetb ( const double  toffsetb)

Definition at line 55 of file EsTimeCalibData.cxx.

55 {
56 m_toffsetb.push_back( toffset );
57 return;
58 }

Referenced by RootEsTimeCalibDataCnv::i_createObj(), and TreeEsTimeCalibDataCnv::i_createObj().

◆ setToffsete()

void EsTimeCalibData::setToffsete ( const double  toffsete)

Definition at line 60 of file EsTimeCalibData.cxx.

60 {
61 m_toffsete.push_back( toffset );
62 return;
63 }

Referenced by RootEsTimeCalibDataCnv::i_createObj(), and TreeEsTimeCalibDataCnv::i_createObj().

◆ update()

StatusCode EsTimeCalibData::update ( CalibBase1 other,
MsgStream *  log 
)
virtual

Reimplemented from CalibData::CalibBase1.

Definition at line 20 of file EsTimeCalibData.cxx.

20 {
21 EsTimeCalibData& other1 = dynamic_cast<EsTimeCalibData& >(other);
22 std::cout<<"========================================"<<"\n"
23 <<"here is the update in the EsTimeCalibData"<<"\n"
24 <<"=================================================="<<std::endl;
25 CalibBase1::update(other, log);
26 //set the Calibration Data
27 if( m_TestCalibConst) { delete m_TestCalibConst; }
28 if( m_toffsetb.size()>0 ) { m_toffsetb.clear(); }
29 if( m_toffsete.size()>0 ) { m_toffsete.clear(); }
30 if( m_bunchtime.size()>0 ) { m_bunchtime.clear(); }
31 if( m_runFrom.size()>0 ) { m_runFrom.clear(); }
32 if( m_runTo.size()>0 ) { m_runTo.clear(); }
33 if( m_eventFrom.size()>0 ) { m_eventFrom.clear(); }
34 if( m_eventTo.size()>0 ) { m_eventTo.clear(); }
35
36 m_TestCalibConst = new vector<double>(*other1.m_TestCalibConst);
37 m_toffsetb = other1.m_toffsetb;
38 m_toffsete = other1.m_toffsete;
39 m_bunchtime = other1.m_bunchtime;
40 m_runFrom = other1.m_runFrom;
41 m_runTo = other1.m_runTo;
42 m_eventFrom = other1.m_eventFrom;
43 m_eventTo = other1.m_eventTo;
44
45 return StatusCode::SUCCESS;
46 }
virtual StatusCode update(CalibBase1 &obj, MsgStream *)
Definition: CalibBase1.cxx:33

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