org.ektorp.impl
Class DefaultLocalBulkBuffer

java.lang.Object
  extended by org.ektorp.impl.DefaultLocalBulkBuffer
All Implemented Interfaces:
LocalBulkBuffer

public abstract class DefaultLocalBulkBuffer
extends Object
implements LocalBulkBuffer


Constructor Summary
DefaultLocalBulkBuffer()
           
 
Method Summary
 void addToBulkBuffer(Object o)
          Add the object to the bulk buffer attached to the executing thread.
 void clearBulkBuffer()
          Clears the bulk buffer attached the the executing thread.
 List<DocumentOperationResult> flushBulkBuffer()
          Sends the bulk buffer attached the the executing thread to the database (through a executeBulk call).
protected abstract  BulkExecutor<Collection<?>> getBulkExecutor()
           
 boolean isAllOrNothing()
           
 void setAllOrNothing(boolean allOrNothing)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultLocalBulkBuffer

public DefaultLocalBulkBuffer()
Method Detail

addToBulkBuffer

public void addToBulkBuffer(Object o)
Description copied from interface: LocalBulkBuffer
Add the object to the bulk buffer attached to the executing thread. A subsequent call to either flushBulkBuffer or clearBulkBuffer is expected.

Specified by:
addToBulkBuffer in interface LocalBulkBuffer

clearBulkBuffer

public void clearBulkBuffer()
Description copied from interface: LocalBulkBuffer
Clears the bulk buffer attached the the executing thread.

Specified by:
clearBulkBuffer in interface LocalBulkBuffer

flushBulkBuffer

public List<DocumentOperationResult> flushBulkBuffer()
Description copied from interface: LocalBulkBuffer
Sends the bulk buffer attached the the executing thread to the database (through a executeBulk call). The bulk buffer will be cleared when this method is finished.

Specified by:
flushBulkBuffer in interface LocalBulkBuffer

getBulkExecutor

protected abstract BulkExecutor<Collection<?>> getBulkExecutor()

isAllOrNothing

public boolean isAllOrNothing()

setAllOrNothing

public void setAllOrNothing(boolean allOrNothing)


Copyright © 2017. All rights reserved.