ATLAS Offline Software
Database
APR
PersistencySvc
PersistencySvc
ITransaction.h
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#ifndef INCLUDE_PERSISTENCYSVC_ITRANSACTION_H
6
#define INCLUDE_PERSISTENCYSVC_ITRANSACTION_H
7
8
/*
9
* POOL namespace declaration
10
*/
11
namespace
pool
{
12
21
class
ITransaction
{
22
protected
:
24
virtual
~ITransaction
() {}
25
26
public
:
28
typedef
enum
{
UNDEFINED
,
29
READ
,
30
UPDATE
}
Type
;
31
33
virtual
bool
start
(
Type
type
=
READ
) = 0;
34
36
virtual
bool
commit
() = 0;
37
39
virtual
bool
commitAndHold
() = 0;
40
42
virtual
void
rollback
() = 0;
43
45
virtual
bool
isActive
()
const
= 0;
46
48
virtual
void
update
() = 0;
49
51
virtual
Type
type
()
const
= 0;
52
};
53
54
}
55
56
#endif
57
pool::ITransaction::rollback
virtual void rollback()=0
Rolls back the transaction.
pool::ITransaction::update
virtual void update()=0
Reverts to update mode.
pool
pool namespace
Definition:
libname.h:15
pool::ITransaction::UPDATE
@ UPDATE
Definition:
ITransaction.h:30
pool::ITransaction::Type
Type
Transaction type enumeration.
Definition:
ITransaction.h:28
pool::ITransaction::~ITransaction
virtual ~ITransaction()
Default destructor.
Definition:
ITransaction.h:24
pool::ITransaction::commitAndHold
virtual bool commitAndHold()=0
Commits the holds transaction.
pool::ITransaction::start
virtual bool start(Type type=READ)=0
Starts a new transaction. Returns the success of the operation.
pool::ITransaction
Definition:
ITransaction.h:21
xAODType
Definition:
ObjectType.h:13
pool::ITransaction::commit
virtual bool commit()=0
Commits the transaction.
pool::ITransaction::READ
@ READ
Definition:
ITransaction.h:29
pool::ITransaction::UNDEFINED
@ UNDEFINED
Definition:
ITransaction.h:28
pool::ITransaction::type
virtual Type type() const =0
Returns the transaction type.
pool::ITransaction::isActive
virtual bool isActive() const =0
Checks if the transaction is active.
Generated on Sun Dec 22 2024 21:12:07 for ATLAS Offline Software by
1.8.18