private static class MapReduceManagerImpl.DeltaAwareList<E>
extends java.util.LinkedList<E>
implements org.infinispan.atomic.DeltaAware, org.infinispan.atomic.Delta
Modifier and Type | Field and Description |
---|---|
private static long |
serialVersionUID
The serialVersionUID
|
Constructor and Description |
---|
MapReduceManagerImpl.DeltaAwareList(java.util.Collection<? extends E> c) |
MapReduceManagerImpl.DeltaAwareList(E reducedObject) |
Modifier and Type | Method and Description |
---|---|
void |
commit()
Indicate that all deltas collected to date has been extracted (via a call to
DeltaAware.delta() ) and can be
discarded. |
org.infinispan.atomic.Delta |
delta()
Extracts changes made to implementations, in an efficient format that can easily and cheaply be serialized and
deserialized.
|
org.infinispan.atomic.DeltaAware |
merge(org.infinispan.atomic.DeltaAware d)
Merge the current Delta instance with a given
DeltaAware instance, and return a coherent and complete
DeltaAware instance. |
add, add, addAll, addAll, addFirst, addLast, clear, clone, contains, descendingIterator, element, get, getFirst, getLast, indexOf, lastIndexOf, listIterator, offer, offerFirst, offerLast, peek, peekFirst, peekLast, poll, pollFirst, pollLast, pop, push, remove, remove, remove, removeFirst, removeFirstOccurrence, removeLast, removeLastOccurrence, set, size, toArray, toArray
equals, hashCode, listIterator, removeRange, subList
containsAll, isEmpty, removeAll, retainAll, toString
finalize, getClass, notify, notifyAll, wait, wait, wait
private static final long serialVersionUID
public MapReduceManagerImpl.DeltaAwareList(java.util.Collection<? extends E> c)
public MapReduceManagerImpl.DeltaAwareList(E reducedObject)
public org.infinispan.atomic.Delta delta()
org.infinispan.atomic.DeltaAware
delta
in interface org.infinispan.atomic.DeltaAware
public void commit()
org.infinispan.atomic.DeltaAware
DeltaAware.delta()
) and can be
discarded. Often used as an optimization if the delta isn't really needed, but the cleaning and resetting of
internal state is desirable.commit
in interface org.infinispan.atomic.DeltaAware
public org.infinispan.atomic.DeltaAware merge(org.infinispan.atomic.DeltaAware d)
org.infinispan.atomic.Delta
DeltaAware
instance, and return a coherent and complete
DeltaAware
instance. Implementations should be able to deal with null values passed in, or values of a
different type from the expected DeltaAware instance. Usually the approach would be to ignore what is passed in,
create a new instance of the DeltaAware implementation that the current Delta implementation is written for, apply
changes and pass it back.merge
in interface org.infinispan.atomic.Delta
d
- instance to merge with, or null if no merging is needed