|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.io.InputStream
com.perforce.p4java.impl.mapbased.rpc.sys.RpcUnicodeInputStream
public class RpcUnicodeInputStream
InputStream wrapper that detects and skips the Unicode BOM (Byte Order Mark) in Unicode encoded text files.
EF BB BF = UTF-8 BOM FF FE = UTF-16, little-endian BOM FE FF = UTF-16, big-endian BOM FF FE 00 00 = UTF-32, little-endian BOM 00 00 FE FF = UTF-32, big-endian BOM
Nested Class Summary | |
---|---|
static class |
RpcUnicodeInputStream.BOM
Types of Unicode BOMs. |
Constructor Summary | |
---|---|
RpcUnicodeInputStream(InputStream inputStream)
Constructs a new RpcUnicodeInputStream that wraps the InputStream. |
Method Summary | |
---|---|
int |
available()
|
void |
close()
|
RpcUnicodeInputStream.BOM |
getBOM()
Returns the BOM found in the InputStream. |
void |
mark(int readlimit)
|
boolean |
markSupported()
|
int |
read()
|
int |
read(byte[] b)
|
int |
read(byte[] b,
int off,
int len)
|
void |
reset()
|
long |
skip(long n)
|
RpcUnicodeInputStream |
skipBOM()
Skips the BOM found in the InputStream. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public RpcUnicodeInputStream(InputStream inputStream) throws NullPointerException, IOException
NullPointerException
IOException
Method Detail |
---|
public final RpcUnicodeInputStream.BOM getBOM()
public final RpcUnicodeInputStream skipBOM() throws IOException
IOException
public int read() throws IOException
read
in class InputStream
IOException
public int read(byte[] b) throws IOException, NullPointerException
read
in class InputStream
IOException
NullPointerException
public int read(byte[] b, int off, int len) throws IOException, NullPointerException
read
in class InputStream
IOException
NullPointerException
public long skip(long n) throws IOException
skip
in class InputStream
IOException
public int available() throws IOException
available
in class InputStream
IOException
public void close() throws IOException
close
in interface Closeable
close
in class InputStream
IOException
public void mark(int readlimit)
mark
in class InputStream
public void reset() throws IOException
reset
in class InputStream
IOException
public boolean markSupported()
markSupported
in class InputStream
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |