Package jmri.jmrix
Class ReplaceableInputStream
java.lang.Object
java.io.InputStream
jmri.jmrix.ReplaceableInputStream
- All Implemented Interfaces:
Closeable,AutoCloseable
An input stream where the stream can be replaced on the fly.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintvoidclose()voidmark(int readlimit) booleanintread()intread(byte[] b) intread(byte[] b, int off, int len) byte[]intreadNBytes(byte[] b, int off, int len) byte[]readNBytes(int len) voidreplaceStream(InputStream stream) voidreset()longskip(long n) longtransferTo(OutputStream out) Methods inherited from class java.io.InputStream
nullInputStream, skipNBytes
-
Constructor Details
-
ReplaceableInputStream
public ReplaceableInputStream()
-
-
Method Details
-
replaceStream
-
read
- Specified by:
readin classInputStream- Throws:
IOException
-
read
- Overrides:
readin classInputStream- Throws:
IOException
-
read
- Overrides:
readin classInputStream- Throws:
IOException
-
readAllBytes
- Overrides:
readAllBytesin classInputStream- Throws:
IOException
-
readNBytes
- Overrides:
readNBytesin classInputStream- Throws:
IOException
-
readNBytes
- Overrides:
readNBytesin classInputStream- Throws:
IOException
-
skip
- Overrides:
skipin classInputStream- Throws:
IOException
-
available
- Overrides:
availablein classInputStream- Throws:
IOException
-
close
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Overrides:
closein classInputStream- Throws:
IOException
-
mark
- Overrides:
markin classInputStream
-
reset
- Overrides:
resetin classInputStream- Throws:
IOException
-
markSupported
- Overrides:
markSupportedin classInputStream
-
transferTo
- Overrides:
transferToin classInputStream- Throws:
IOException
-