|
ATLAS Offline Software
|
Go to the documentation of this file.
5 #ifndef INCLUDE_PERSISTENCYSVC_DATABASEHANDLER_H
6 #define INCLUDE_PERSISTENCYSVC_DATABASEHANDLER_H
22 class IStorageExplorer;
25 namespace PersistencySvc {
41 const std::string&
fid,
42 const std::string&
pfn,
67 const std::string&
pfn()
const;
70 const std::string&
fid()
const;
93 const std::type_info& typeInfo,
94 const std::string& option );
99 const std::type_info& typeInfo,
100 const std::string& option );
char data[hepevt_bytes_allocation_ATLAS]
IStorageSvc & m_storageSvc
IStorageSvc reference.
FileDescriptor m_fileDescriptor
File descriptor for this database.
IContainer * container(const std::string &containerName)
Returns a container handle.
void rollBackTransaction()
Rolls back the transaction.
bool disconnectTransaction()
Disconnects the transaction.
IStorageExplorer & m_storageExplorer
IStorageExplorer reference.
long m_technology
Technology identifier.
bool attribute(const std::string &attributeName, void *data, const std::type_info &typeInfo, const std::string &option)
Returns an attribute.
This class provides a token that identifies in a unique way objects on the persistent storage.
std::vector< std::string > containers()
Gives the list of containers.
Session * m_session
Pointer to the session for this database.
bool setAttribute(const std::string &attributeName, const void *data, const std::type_info &typeInfo, const std::string &option)
Sets an attrtibute.
void * readObject(const Token &token, void *object=0)
Reads an object given a token.
long m_accessMode
Current access mode.
bool commitTransaction()
Commits the transaction.
long technology() const
Returns the technology identifier.
bool commitAndHoldTransaction()
Commits and holds the transaction.
DatabaseHandler(IStorageSvc &storageSvc, IStorageExplorer &storageExplorer, Session *session, long technology, const std::string &fid, const std::string &pfn, long accessmode)
Constructor. Connects to the database.
long accessMode() const
Returns the access mode.
const std::string & pfn() const
Returns the physical file name.
~DatabaseHandler()
Destructor. Disconnects from the database.
This class provides a encapsulation of a GUID/UUID/CLSID/IID data structure (128 bit number).
const std::string & fid() const
Returns the file identifier.
Token * writeObject(const std::string &containerName, long minorTechnology, const void *object, const RootType &type)
Writes an object and returns a token.
void reconnect(long accessMode)
Reconnects with a new access mode.