Package org.multiverse.api
Interface TxnFactory
-
- All Known Subinterfaces:
GammaTxnFactory
- All Known Implementing Classes:
GammaStm.NonSpeculativeGammaTxnFactory
,GammaStm.SpeculativeGammaTxnFactory
public interface TxnFactory
A Factory responsible for creating aTxn
. To set properties on Transactions you need to look at theTxnFactoryBuilder
. It could be that over time different types of transactions are returned, e.g. because the speculative behavior is enabled.Thread safety
A TxnFactory is thread-safe and it is expected to be shared between threads (doesn't impose it, but it is the most logical use case). It also is expected to be re-used instead of recreated.
- See Also:
TxnFactoryBuilder
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description TxnConfig
getConfig()
Gets theTxnConfig
used by this TxnFactory.TxnFactoryBuilder
getTxnFactoryBuilder()
Txn
newTxn()
Creates a newTxn
.
-
-
-
Method Detail
-
getTxnFactoryBuilder
TxnFactoryBuilder getTxnFactoryBuilder()
-
-