RxJava



rx.operators
Class ChunkedOperation.SizeBasedChunks<T,C>

java.lang.Object
  extended by rx.operators.ChunkedOperation.Chunks<T,C>
      extended by rx.operators.ChunkedOperation.SizeBasedChunks<T,C>
Type Parameters:
T - The type of object all internal ChunkedOperation.Chunk objects record. The type of object being tracked by the ChunkedOperation.Chunk
Enclosing class:
ChunkedOperation

protected static class ChunkedOperation.SizeBasedChunks<T,C>
extends ChunkedOperation.Chunks<T,C>

This class is an extension on the ChunkedOperation.Chunks class. Every internal chunk has a fixed maximum capacity. When the chunk has reached its maximum capacity it is automatically emitted.


Constructor Summary
ChunkedOperation.SizeBasedChunks(Observer<? super C> observer, Func0<? extends ChunkedOperation.Chunk<T,C>> chunkMaker, int size)
           
 
Method Summary
 void pushValue(T value)
          This method pushes a value to all not yet emitted ChunkedOperation.Chunk objects.
 
Methods inherited from class rx.operators.ChunkedOperation.Chunks
createChunk, emitAllChunks, emitChunk, getChunk
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ChunkedOperation.SizeBasedChunks

public ChunkedOperation.SizeBasedChunks(Observer<? super C> observer,
                                        Func0<? extends ChunkedOperation.Chunk<T,C>> chunkMaker,
                                        int size)
Method Detail

pushValue

public void pushValue(T value)
Description copied from class: ChunkedOperation.Chunks
This method pushes a value to all not yet emitted ChunkedOperation.Chunk objects.

Overrides:
pushValue in class ChunkedOperation.Chunks<T,C>
Parameters:
value - The value to push to all not yet emitted ChunkedOperation.Chunk objects.