Package org.syncany.chunk
Interface Chunker.ChunkEnumeration
-
- All Superinterfaces:
java.util.Enumeration<Chunk>
- All Known Implementing Classes:
FixedChunker.FixedChunkEnumeration
,TttdChunker.TTTDEnumeration
- Enclosing class:
- Chunker
public static interface Chunker.ChunkEnumeration extends java.util.Enumeration<Chunk>
The chunk enumeration is implemented by the actual chunkers and emits a new chunk whennextElement()
is called. When no more elements are available,hasMoreElements()
returns false. Any open streams must be closed withclose()
.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
close()
Closes the file opened by thecreateChunks()
method.boolean
hasMoreElements()
Returns true if the chunker can return at least one more chunk.Chunk
nextElement()
Returns the next chunk (if there are any).
-
-
-
Method Detail
-
hasMoreElements
boolean hasMoreElements()
Returns true if the chunker can return at least one more chunk.- Specified by:
hasMoreElements
in interfacejava.util.Enumeration<Chunk>
-
nextElement
Chunk nextElement()
Returns the next chunk (if there are any).- Specified by:
nextElement
in interfacejava.util.Enumeration<Chunk>
-
close
void close()
Closes the file opened by thecreateChunks()
method. This method must be called at the end of processing to release any read-/write locks.
-
-