ECCE @ EIC Software
Reference for
ECCE @ EIC
simulation and reconstruction software on GitHub
Home page
Related Pages
Modules
Namespaces
Classes
Files
External Links
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
PgPostCalBankIterator.h
Go to the documentation of this file.
Or view
the newest version in sPHENIX GitHub for file PgPostCalBankIterator.h
1
// Tell emacs that this is a C++ source
2
// -*- C++ -*-.
3
#ifndef PDBCALPG_PGPOSTCALBANKITERATOR_H
4
#define PDBCALPG_PGPOSTCALBANKITERATOR_H
5
6
#include <pdbcalbase/PdbBankID.h>
7
#include <pdbcalbase/PdbCalBankIterator.h>
8
9
#include <
phool/PHTimeStamp.h
>
10
11
#include <ctime>
12
#include <map>
13
#include <iostream>
14
#include <string>
15
16
class
PdbCalBank
;
17
class
PgPostApplication
;
18
class
PgPostBankManager
;
19
class
TSQLResultSet;
20
class
TSQLStatement;
21
22
class
PgPostCalBankIterator
:
public
PdbCalBankIterator
23
{
24
public
:
25
PgPostCalBankIterator
(
PgPostBankManager
& bm);
26
virtual
~PgPostCalBankIterator
();
27
28
virtual
bool
init
(
const
std::string& fulldbname,
const
PdbBankID
& bankid);
29
30
virtual
bool
isValid
()
const
;
31
32
virtual
void
print
(std::ostream& os = std::cout)
const
;
33
34
virtual
void
setBankID
(
const
PdbBankID
&
id
);
35
36
virtual
void
setEndValTimeLimits
(
const
PHTimeStamp
&
min
=
PHTimeStamp
(0),
37
const
PHTimeStamp
&
max
=
PHTimeStamp
(
PHTimeStamp::PHFarFuture
));
38
39
virtual
void
setInsertTimeLimits
(
const
PHTimeStamp
&
min
=
PHTimeStamp
(0),
40
const
PHTimeStamp
&
max
=
PHTimeStamp
(
PHTimeStamp::PHFarFuture
));
41
42
virtual
void
setStartValTimeLimits
(
const
PHTimeStamp
&
min
=
PHTimeStamp
(0),
43
const
PHTimeStamp
&
max
=
PHTimeStamp
(
PHTimeStamp::PHFarFuture
));
44
45
virtual
PdbCalBank
*
next
();
46
47
private
:
48
class
ValPeriod
49
{
50
public
:
51
ValPeriod
(
const
PHTimeStamp
&
min
=
PHTimeStamp
(0),
52
const
PHTimeStamp
&
max
=
PHTimeStamp::PHFarFuture
)
53
:
start_
(
min
)
54
,
end_
(
max
)
55
{
56
}
57
58
time_t
start
()
const
{
return
start_
.
getTics
(); }
59
time_t
end
()
const
{
return
end_
.
getTics
(); }
60
61
private
:
62
PHTimeStamp
start_
;
63
PHTimeStamp
end_
;
64
};
65
66
typedef
std::map<std::string, ValPeriod>
TimeMap
;
67
TimeMap
fTimeMap
;
68
69
PgPostBankManager
&
fBM
;
70
PgPostApplication
*
fApplication
;
71
std::string
fDBName
;
72
std::string
fTableName
;
73
bool
fIsValid
;
74
PdbBankID
fBankID
;
75
TSQLStatement*
fSQLStatement
;
76
TSQLResultSet*
fSQLResultSet
;
77
};
78
79
#endif
coresoftware
blob
master
offline
database
pdbcal
pg
PgPostCalBankIterator.h
Built by
Jin Huang
. updated:
Wed Jun 29 2022 17:24:33
using
1.8.2 with
ECCE GitHub integration