Loading [MathJax]/extensions/tex2jax.js
ATLAS Offline Software
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
RootKeyContainer.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 //====================================================================
6 // Root Database implementation
7 //--------------------------------------------------------------------
8 //
9 // Package : RootStorageSvc (The POOL project)
10 //
11 // Author : M.Frank
12 //====================================================================
13 #ifndef POOL_ROOTKEYCONTAINER_H
14 #define POOL_ROOTKEYCONTAINER_H 1
15 
16 // Framework include files
17 #include "StorageSvc/DbDatabase.h"
19 
20 // Forward declarations
21 namespace CINT { class IOHandler; }
22 class TDirectory;
23 class TBuffer;
24 class TClass;
25 
26 namespace pool {
27  // Forward declarations
28  union RootDataPtr;
29  class RootKeyIOHandler;
30 
47  TDirectory* m_dir;
55  int m_policy;
57  int m_ioBytes;
58 
59  protected:
61  virtual DbStatus destroyObject(ActionList::value_type&) override;
63  virtual DbStatus writeObject(ActionList::value_type&) override;
64  public:
68  virtual ~RootKeyContainer();
72  virtual DbStatus close() override;
74  virtual DbStatus open(DbDatabase& dbH,
75  const std::string& nam,
76  const DbTypeInfo* info,
77  DbAccessMode mod) override;
80  const std::string& nam) const override final;
82  virtual DbStatus isShapeSupported(const DbTypeInfo* /* typ */ ) const override
83  { return true; }
85  virtual DbStatus select(DbSelect& criteria) override;
87  virtual uint64_t size() override;
89  virtual uint64_t nextRecordId() override;
91  virtual DbStatus fetch(DbSelect& sel) override;
93  virtual DbStatus fetch( const Token::OID_t& linkH, Token::OID_t& stmt) override;
94 
96 
102  virtual DbStatus loadObject( void** ptr, ShapeH shape,
103  Token::OID_t& oid) override;
104 
106  virtual DbStatus load( void** ptr, ShapeH shape,
107  const Token::OID_t& linkH,
108  Token::OID_t& oid,
109  bool any_next) override;
110 
112 
116  virtual DbStatus getOption(DbOption& opt) override;
117 
119 
123  virtual DbStatus setOption(const DbOption& opt) override;
124 
126 
130  virtual DbStatus transAct(Transaction::Action action) override;
132  };
133 }
134 #endif //POOL_ROOTKEYCONTAINER_H
grepfile.info
info
Definition: grepfile.py:38
pool::DbAccessMode
int DbAccessMode
Definition: Database/APR/StorageSvc/StorageSvc/pool.h:47
pool::RootKeyContainer::operator=
RootKeyContainer & operator=(const RootKeyContainer &)=delete
CINT
Definition: RootKeyContainer.h:21
createCoolChannelIdFile.stmt
stmt
Definition: createCoolChannelIdFile.py:42
pool::RootKeyContainer::nextRecordId
virtual uint64_t nextRecordId() override
Number of record in the container.
pool::RootKeyContainer::m_ioBytes
int m_ioBytes
Number of bytes written/read during last operation. Set to -1 if it failed.
Definition: RootKeyContainer.h:57
pool::DbStatus
Definition: DbStatus.h:67
make_coralServer_rep.opt
opt
Definition: make_coralServer_rep.py:19
pool::RootKeyContainer::getOption
virtual DbStatus getOption(DbOption &opt) override
Access options.
pool::RootKeyContainer::m_ioHandler
RootKeyIOHandler * m_ioHandler
CINT IO handler to allow user overloads....
Definition: RootKeyContainer.h:53
pool::RootKeyContainer::isShapeSupported
virtual DbStatus isShapeSupported(const DbTypeInfo *) const override
Ask if a given shape is supported.
Definition: RootKeyContainer.h:82
pool
pool namespace
Definition: libname.h:15
pool::RootKeyContainer::fetch
virtual DbStatus fetch(DbSelect &sel) override
Fetch next object address of the selection to set token.
pool::RootKeyContainer::m_rootDb
RootDatabase * m_rootDb
Root database file reference.
Definition: RootKeyContainer.h:51
dbg::ptr
void * ptr(T *p)
Definition: SGImplSvc.cxx:74
pool::RootKeyContainer::~RootKeyContainer
virtual ~RootKeyContainer()
Standard destructor.
DbDatabase.h
pool::RootKeyContainer::setOption
virtual DbStatus setOption(const DbOption &opt) override
Set options.
Token::OID_t
Definition: Token.h:24
pool::RootKeyContainer::RootKeyContainer
RootKeyContainer(const RootKeyContainer &)=delete
pool::RootKeyContainer::select
virtual DbStatus select(DbSelect &criteria) override
Define selection criteria.
pool::ShapeH
const class Shape * ShapeH
Definition: DbContainerObj.h:27
pool::RootKeyIOHandler
Definition: RootKeyIOHandler.h:27
maskDeadModules.mod
mod
Definition: maskDeadModules.py:36
pool::DbOption
Definition: DbOption.h:36
sel
sel
Definition: SUSYToolsTester.cxx:97
pool::DbSelect
Definition: DbSelect.h:44
xAOD::uint64_t
uint64_t
Definition: EventInfo_v1.cxx:123
pool::RootKeyContainer::loadObject
virtual DbStatus loadObject(void **ptr, ShapeH shape, Token::OID_t &oid) override
Find object by object identifier and load it into memory.
pool::RootKeyContainer::m_policy
int m_policy
Policy flag.
Definition: RootKeyContainer.h:55
pool::RootKeyContainer::destroyObject
virtual DbStatus destroyObject(ActionList::value_type &) override
Destroy persistent object in the container.
pool::Transaction::Action
Action
Definition: Transaction.h:34
pool::RootKeyContainer::checkAccess
virtual DbStatus checkAccess(DbDatabase &dbH, const std::string &nam) const override final
Check if we can access the container for reading with the given type.
pool::RootKeyContainer::transAct
virtual DbStatus transAct(Transaction::Action action) override
Execute end of object modification requests during a transaction.
pool::RootKeyContainer::open
virtual DbStatus open(DbDatabase &dbH, const std::string &nam, const DbTypeInfo *info, DbAccessMode mod) override
Open the container for object access.
pool::RootDatabase
Definition: RootDatabase.h:59
python.CaloScaleNoiseConfig.action
action
Definition: CaloScaleNoiseConfig.py:77
pool::RootKeyContainer::writeObject
virtual DbStatus writeObject(ActionList::value_type &) override
Commit single entry to container.
pool::RootKeyContainer::size
virtual uint64_t size() override
Number of entries within the container.
DbContainerImp.h
pool::RootKeyContainer::fetch
virtual DbStatus fetch(const Token::OID_t &linkH, Token::OID_t &stmt) override
Fetch a column identified by its link in the container.
pool::RootKeyContainer::RootKeyContainer
RootKeyContainer()
Standard constructor.
pool::RootKeyContainer
Definition: RootKeyContainer.h:45
pool::RootKeyContainer::m_dbH
DbDatabase m_dbH
Parent Database handle.
Definition: RootKeyContainer.h:49
pool::DbContainerImp
Definition: DbContainerImp.h:44
pool::RootKeyContainer::load
virtual DbStatus load(void **ptr, ShapeH shape, const Token::OID_t &linkH, Token::OID_t &oid, bool any_next) override
Interface Implementation: Find entry in container.
pool::DbDatabase
Definition: DbDatabase.h:53
pool::RootKeyContainer::m_dir
TDirectory * m_dir
Reference to the root tree object.
Definition: RootKeyContainer.h:47
pool::DbTypeInfo
Definition: DbTypeInfo.h:47
pool::RootKeyContainer::close
virtual DbStatus close() override
Close the container and deallocate resources.