public class ChunkableContent extends Object implements Iterable<ChunkInputStream>, Iterator<ChunkInputStream>
| Constructor and Description |
|---|
ChunkableContent(String contentId,
InputStream largeStream,
long contentSize,
long maxChunkSize) |
ChunkableContent(String contentId,
String contentMimetype,
InputStream largeStream,
long contentSize,
long maxChunkSize) |
| Modifier and Type | Method and Description |
|---|---|
protected int |
calculateBufferSize(long maxChunkSize)
This method finds the maximum 1-KB divisor of arg maxChunkSize that is
less than 8-KB.
|
ChunksManifest |
finalizeManifest() |
ChunksManifest |
getManifest() |
long |
getMaxChunkSize() |
boolean |
hasNext()
This method indicates if there are any more chunks.
|
Iterator<ChunkInputStream> |
iterator() |
ChunkInputStream |
next()
This method returns the next chunk of the wrapped InputStream.
|
void |
remove() |
void |
setPreserveChunkMD5s(boolean preserveChunkMD5s) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforEach, spliteratorforEachRemainingpublic ChunkableContent(String contentId, InputStream largeStream, long contentSize, long maxChunkSize)
public ChunkableContent(String contentId, String contentMimetype, InputStream largeStream, long contentSize, long maxChunkSize)
protected int calculateBufferSize(long maxChunkSize)
maxChunkSize - of chunk streampublic boolean hasNext()
hasNext in interface Iterator<ChunkInputStream>public ChunkInputStream next()
next in interface Iterator<ChunkInputStream>public void remove()
remove in interface Iterator<ChunkInputStream>public Iterator<ChunkInputStream> iterator()
iterator in interface Iterable<ChunkInputStream>public void setPreserveChunkMD5s(boolean preserveChunkMD5s)
public long getMaxChunkSize()
public ChunksManifest getManifest()
public ChunksManifest finalizeManifest()
Copyright © 2009–2017 DuraSpace. All rights reserved.