Documentation of 'org.mapdb.TxMaker' Java class
TxMaker
org.mapdb

Class TxMaker

  • All Implemented Interfaces:
    java.io.Closeable, java.lang.AutoCloseable


    public class TxMaker
    extends java.lang.Object
    implements java.io.Closeable
    Transaction factory
    • Constructor Summary

      Constructors 
      Constructor and Description
      TxMaker(Engine engine) 
      TxMaker(Engine engine, boolean strictDBGet, java.util.concurrent.ScheduledExecutorService executor, Fun.Function1<java.lang.Class,java.lang.String> serializerClassLoader) 
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      void close() 
      <A> A execute(Fun.Function1<A,DB> txBlock)
      Executes given block withing single transaction.
      void execute(TxBlock txBlock)
      Executes given block withing single transaction.
      DB makeTx() 
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • TxMaker

        public TxMaker(Engine engine)
      • TxMaker

        public TxMaker(Engine engine,
                       boolean strictDBGet,
                       java.util.concurrent.ScheduledExecutorService executor,
                       Fun.Function1<java.lang.Class,java.lang.String> serializerClassLoader)
    • Method Detail

      • makeTx

        public DB makeTx()
      • close

        public void close()
        Specified by:
        close in interface java.io.Closeable
        Specified by:
        close in interface java.lang.AutoCloseable
      • execute

        public void execute(TxBlock txBlock)
        Executes given block withing single transaction. If block throws TxRollbackException execution is repeated until it does not fail.
        Parameters:
        txBlock -
      • execute

        public <A> A execute(Fun.Function1<A,DB> txBlock)
        Executes given block withing single transaction. If block throws TxRollbackException execution is repeated until it does not fail. This method returns result returned by txBlock.
        Parameters:
        txBlock -

DataMelt 3.0 © DataMelt by jWork.ORG

Ads help maintain this website.