org.openstreetmap.josm.io
Class UTFInputStreamReader
java.lang.Object
java.io.Reader
java.io.InputStreamReader
org.openstreetmap.josm.io.UTFInputStreamReader
- All Implemented Interfaces:
- java.io.Closeable, java.lang.Readable
public class UTFInputStreamReader
- extends java.io.InputStreamReader
Detects the different UTF encodings from byte order mark
Fields inherited from class java.io.Reader |
lock |
Method Summary |
static UTFInputStreamReader |
create(java.io.InputStream input,
java.lang.String defaultEncoding)
converts input stream to reader |
Methods inherited from class java.io.InputStreamReader |
close, getEncoding, read, read, ready |
Methods inherited from class java.io.Reader |
mark, markSupported, read, read, reset, skip |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
UTFInputStreamReader
private UTFInputStreamReader(java.io.InputStream in)
UTFInputStreamReader
private UTFInputStreamReader(java.io.InputStream in,
java.lang.String cs)
throws java.io.UnsupportedEncodingException
- Throws:
java.io.UnsupportedEncodingException
create
public static UTFInputStreamReader create(java.io.InputStream input,
java.lang.String defaultEncoding)
throws java.io.IOException
- converts input stream to reader
- Parameters:
defaultEncoding
- Used, when no BOM was recognized. Can be null.
- Returns:
- A reader with the correct encoding. Starts to read after the BOM.
- Throws:
java.io.IOException
JOSM