ATLAS Offline Software
Loading...
Searching...
No Matches
IPersistencySvc.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2026 CERN for the benefit of the ATLAS collaboration
3*/
4
5//$Id: IPersistencySvc.h 739662 2016-04-12 11:55:10Z krasznaa $
6
7#ifndef PERSISTENCYSVC_IPERSISTENCYSVC
8#define PERSISTENCYSVC_IPERSISTENCYSVC
9
11
12#include <string>
13#include <memory>
14
15class Placement;
16class Token;
17
21namespace pool {
22
23 class IFileCatalog;
24 class ISession;
25
33 public:
34
36 static std::unique_ptr<IPersistencySvc> create( IFileCatalog& catalog );
37
39 virtual ~IPersistencySvc() {}
40
53 virtual void* readObject( const Token& token, void* object = 0 ) = 0;
54
65 virtual Token* registerForWrite( const Placement& place,
66 const void* object,
67 const RootType& type ) = 0;
68
70 virtual ISession& session() = 0;
71
72 protected:
77
78 }; // class IPersistencySvc
79
80} // namespace pool
81
82#endif // PERSISTENCYSVC_IPERSISTENCYSVC
TTypeAdapter RootType
Definition RootType.h:211
This class holds all the necessary information to guide the writing of an object in a physical place.
Definition Placement.h:19
This class provides a token that identifies in a unique way objects on the persistent storage.
Definition Token.h:21
virtual Token * registerForWrite(const Placement &place, const void *object, const RootType &type)=0
registerForWrite registers an object for writing to the persistent medium higher level interactions w...
IPersistencySvc()
No copy constructor, and no assignment operator.
virtual ISession & session()=0
Returns the underlying global session.
IPersistencySvc & operator=(const IPersistencySvc &)
static std::unique_ptr< IPersistencySvc > create(IFileCatalog &catalog)
Factory for PersistencySvc.
IPersistencySvc(const IPersistencySvc &)
virtual ~IPersistencySvc()
Empty destructor.
virtual void * readObject(const Token &token, void *object=0)=0
Retrieves an object from persistent store and return with type information The handle to the reflecti...
ISession is the interface class for user (macroscopic) sessions Every transaction and connection to a...
Definition ISession.h:32
pool namespace
Definition libname.h:15