This version also support mark/reset.
| Modifier and Type | Field and Description |
|---|---|
| private static final Logger | |
| private long | |
| private final File |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public static WrappedFileInputStream | |
| public InputStream | duplicate()
Implements com. Produces a duplicate stream of the source (from its start) that can be used in parallel to the original stream (ie, thread safe). |
| public File | |
| public synchronized void | mark(int
the maximum limit of bytes that can be read before
the mark position becomes invalid. readlimit)Overrides java. Marks the current position in this input stream. |
| public boolean | markSupported()
Overrides java. Tests if this input stream supports the |
| public synchronized void | reset()
Overrides java. Repositions this stream to the position at the time the
|
| LOG | back to summary |
|---|---|
| private static final Logger LOG | |
| markPosition | back to summary |
|---|---|
| private long markPosition | |
| sourceFile | back to summary |
|---|---|
| private final File sourceFile | |
| WrappedFileInputStream | back to summary |
|---|---|
| public WrappedFileInputStream(File file) throws FileNotFoundException | |
| create | back to summary |
|---|---|
| public static WrappedFileInputStream create(File file) Same as calling the ctor, except will throw an unchecked IllegalArgumentException if the file isn't found.
| |
| duplicate | back to summary |
|---|---|
| public InputStream duplicate() Implements com. Doc from com. Produces a duplicate stream of the source (from its start) that can be used in parallel to the original stream (ie, thread safe).
| |
| getSourceFile | back to summary |
|---|---|
| public File getSourceFile() | |
| mark | back to summary |
|---|---|
| public synchronized void mark(int readlimit) Overrides java. Doc from java. Marks the current position in this input stream. A subsequent call to
the The The general contract of Marking a closed stream should not have any effect on the stream.
| |
| markSupported | back to summary |
|---|---|
| public boolean markSupported() Overrides java. Doc from java. Tests if this input stream supports the
| |
| reset | back to summary |
|---|---|
| public synchronized void reset() throws IOException Overrides java. Doc from java. Repositions this stream to the position at the time the
The general contract of
| |