public class AutoLFInputStream extends InputStream
This is the former EolCanonicalizingInputStream with a new name in order to have same naming for all LF / CRLF streams
| Modifier and Type | Class and Description |
|---|---|
static class |
AutoLFInputStream.IsBinaryException
A special exception thrown when
AutoLFInputStream is told to
throw an exception when attempting to read a binary file. |
| Constructor and Description |
|---|
AutoLFInputStream(InputStream in,
boolean detectBinary)
Creates a new InputStream, wrapping the specified stream
|
AutoLFInputStream(InputStream in,
boolean detectBinary,
boolean abortIfBinary)
Creates a new InputStream, wrapping the specified stream
|
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
boolean |
isBinary()
Whether the stream has detected as a binary so far.
|
int |
read() |
int |
read(byte[] bs,
int off,
int len) |
available, mark, markSupported, read, reset, skippublic AutoLFInputStream(InputStream in, boolean detectBinary)
in - raw input streamdetectBinary - whether binaries should be detectedpublic AutoLFInputStream(InputStream in, boolean detectBinary, boolean abortIfBinary)
in - raw input streamdetectBinary - whether binaries should be detectedabortIfBinary - throw an IOException if the file is binarypublic int read()
throws IOException
read in class InputStreamIOExceptionpublic int read(byte[] bs,
int off,
int len)
throws IOException
read in class InputStreamIOExceptionpublic boolean isBinary()
public void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableclose in class InputStreamIOExceptionCopyright © 2020 Eclipse JGit Project. All rights reserved.