BOSS
7.0.4
BESIII Offline Software System
Loading...
Searching...
No Matches
HepHistID.cxx
Go to the documentation of this file.
1
#include "MdcRecoUtil/HepHistID.h"
2
using
std::string;
3
4
HepHistID::HepHistID
(
int
theNumber) :
5
_numSet(
true
),
6
_stringSet(
false
),
7
_idNumber(theNumber),
8
_idString() {}
9
10
HepHistID::HepHistID
(
const
char
* theString) :
11
_numSet(
false
),
12
_stringSet(
true
),
13
_idNumber(0),
14
_idString(theString) {}
15
16
HepHistID::HepHistID
(
int
theNumber,
string
theString) :
17
_numSet(
true
),
18
_stringSet(
true
),
19
_idNumber(theNumber),
20
_idString(theString) {}
21
22
HepHistID::HepHistID
(
const
HepHistID
& other) :
23
_numSet(other._numSet),
24
_stringSet(other._stringSet),
25
_idNumber(other._idNumber),
26
_idString(other._idString) {}
27
28
// prefix increment number ID
29
HepHistID
&
HepHistID::operator++
() {
30
if
( _numSet ) {
31
++_idNumber;
32
};
33
// return this
34
return
*
this
;
35
}
36
37
// postfix increment number ID
38
const
HepHistID
HepHistID::operator++
(
int
) {
39
// initialize result
40
HepHistID
result(*
this
);
41
// increment this
42
++(*this);
43
// return result
44
return
result;
45
}
46
47
// prefix decrement number ID
48
HepHistID
&
HepHistID::operator--
() {
49
if
( _numSet ) {
50
--_idNumber;
51
};
52
// return this
53
return
*
this
;
54
}
55
56
// postfix decrement number ID
57
const
HepHistID
HepHistID::operator--
(
int
) {
58
// initialize result
59
HepHistID
result(*
this
);
60
// increment this
61
--(*this);
62
// return result
63
return
result;
64
}
true
#define true
Definition:
BesCxxPolicy/BesCxxPolicy-00-01-01/CxxFeatures/config.h:19
false
#define false
Definition:
BesCxxPolicy/BesCxxPolicy-00-01-01/CxxFeatures/config.h:22
HepHistID
Definition:
InstallArea/include/MdcRecoUtil/MdcRecoUtil/HepHistID.h:24
HepHistID::operator++
HepHistID & operator++()
Definition:
HepHistID.cxx:29
HepHistID::HepHistID
HepHistID(int theNumber)
Definition:
HepHistID.cxx:4
HepHistID::operator--
HepHistID & operator--()
Definition:
HepHistID.cxx:48
source
Reconstruction
MdcPatRec
MdcRecoUtil
MdcRecoUtil-00-01-08
src
HepHistID.cxx
Generated by
1.9.6