ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
Database
RDBAccessSvc
src
RDBRecordset.h
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3
*/
4
14
15
16
#ifndef RDBACCESSSVC_RDBRECORDSET_H
17
#define RDBACCESSSVC_RDBRECORDSET_H
18
19
#include "
RDBAccessSvc/IRDBRecordset.h
"
20
#include "
RDBVersionAccessor.h
"
21
#include <string>
22
23
class
RDBAccessSvc
;
24
class
IRDBQuery
;
25
26
namespace
coral
27
{
28
class
ISessionProxy;
29
}
30
37
38
class
RDBRecordset
final:
public
IRDBRecordset
39
{
40
public
:
42
RDBRecordset
(
RDBAccessSvc
* accessSvc)
43
:
m_accessSvc
(accessSvc) {}
44
48
void
getData
(coral::ISessionProxy* session
49
,
const
std::string&
nodeName
50
,
const
std::string&
tagName
51
,
const
std::string& tagId);
52
54
unsigned
int
size
()
const override
;
55
57
std::string
nodeName
()
const override
;
58
60
std::string
tagName
()
const override
;
61
64
const
IRDBRecord
*
operator[]
(
unsigned
int
index
)
const override
;
65
67
IRDBRecordset::const_iterator
begin
()
const override
;
68
70
IRDBRecordset::const_iterator
end
()
const override
;
71
72
// Comparison operator
73
bool
operator!=
(
const
RDBRecordset
& rhs)
const
;
74
75
// Comparison results with other recordset
76
void
compare
(
const
RDBRecordset
& rec, std::ostream& os)
const
;
77
78
// Set table name only when retrieval of data has failed and
79
// an empty recordset needs to be returned to the client
80
void
setNodeName
(
const
std::string&
nodeName
);
81
82
private
:
83
std::string
m_tableName
{};
84
std::string
m_tagName
{};
85
RecordsVector
m_records
;
86
RDBAccessSvc
*
m_accessSvc
{
nullptr
};
87
};
88
89
#endif
IRDBRecordset.h
Definition of the abstract IRDBRecordset interface.
RecordsVector
std::vector< IRDBRecord_ptr > RecordsVector
Definition
IRDBRecordset.h:24
RDBVersionAccessor.h
Definition of RDBVersionAccessor class.
IRDBQuery
Definition
IRDBQuery.h:13
IRDBRecord
IRDBRecord is one record in the IRDBRecordset object.
Definition
IRDBRecord.h:28
IRDBRecordset
IRDBRecordset is an abstract interface to the RDB Recordsets, which represent a snapshot of HVS-tagge...
Definition
IRDBRecordset.h:35
IRDBRecordset::const_iterator
RecordsVector::const_iterator const_iterator
Definition
IRDBRecordset.h:52
RDBAccessSvc
RDBAccessSvc is the implementation of IRDBAccessSvc interface.
Definition
RDBAccessSvc.h:59
RDBRecordset
RDBRecordset is an implementation of IRDBRecordset interface.
Definition
RDBRecordset.h:39
RDBRecordset::nodeName
std::string nodeName() const override
Definition
RDBRecordset.cxx:126
RDBRecordset::end
IRDBRecordset::const_iterator end() const override
Definition
RDBRecordset.cxx:145
RDBRecordset::begin
IRDBRecordset::const_iterator begin() const override
Definition
RDBRecordset.cxx:140
RDBRecordset::compare
void compare(const RDBRecordset &rec, std::ostream &os) const
Definition
RDBRecordset.cxx:165
RDBRecordset::operator!=
bool operator!=(const RDBRecordset &rhs) const
Definition
RDBRecordset.cxx:150
RDBRecordset::setNodeName
void setNodeName(const std::string &nodeName)
Definition
RDBRecordset.cxx:263
RDBRecordset::m_tableName
std::string m_tableName
Definition
RDBRecordset.h:83
RDBRecordset::m_tagName
std::string m_tagName
Definition
RDBRecordset.h:84
RDBRecordset::size
unsigned int size() const override
Definition
RDBRecordset.cxx:121
RDBRecordset::tagName
std::string tagName() const override
Definition
RDBRecordset.cxx:131
RDBRecordset::operator[]
const IRDBRecord * operator[](unsigned int index) const override
Definition
RDBRecordset.cxx:136
RDBRecordset::RDBRecordset
RDBRecordset(RDBAccessSvc *accessSvc)
Construct empty recordset.
Definition
RDBRecordset.h:42
RDBRecordset::m_records
RecordsVector m_records
Definition
RDBRecordset.h:85
RDBRecordset::m_accessSvc
RDBAccessSvc * m_accessSvc
Definition
RDBRecordset.h:86
RDBRecordset::getData
void getData(coral::ISessionProxy *session, const std::string &nodeName, const std::string &tagName, const std::string &tagId)
Constructs SQL query and retrieves the data from DB.
Definition
RDBRecordset.cxx:39
coral
Definition
ISecondaryEventSelector.h:19
index
Definition
index.py:1
Generated on
for ATLAS Offline Software by
1.17.0