org.hypergraphdb.transaction
Interface HGTransaction
- All Known Implementing Classes:
- TransactionBDBImpl, VanillaTransaction
public interface HGTransaction
Represents a transaction object. The interface is minimalistic on purpose, exposing
only the two essential operations one can do one a transaction.
Each transaction can carry an arbitrary set of attributes along with it. This is useful
for attaching contextual information to transactions without intruding to otherwise simple
APIs. When a transaction is committed or aborted, all attributes are removed.
- Author:
- Borislav Iordanov
setAttribute
void setAttribute(java.lang.String name,
java.lang.Object value)
getAttribute
java.lang.Object getAttribute(java.lang.String name)
removeAttribute
void removeAttribute(java.lang.String name)
getAttributeNames
java.util.Iterator<java.lang.String> getAttributeNames()
commit
void commit()
throws HGTransactionException
- Throws:
HGTransactionException
abort
void abort()
throws HGTransactionException
- Throws:
HGTransactionException