public class ReaderInputStream extends InputStream
CharsetEncoder
class.Constructor and Description |
---|
ReaderInputStream(Reader reader)
Constructor.
|
ReaderInputStream(Reader reader,
CharacterSet characterSet)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
int |
available() |
void |
close()
Closes the wrapped reader.
|
int |
read() |
int |
read(byte[] b,
int off,
int len) |
mark, markSupported, read, reset, skip
public ReaderInputStream(Reader reader) throws IOException
CharacterSet.ISO_8859_1
character set by
default.reader
- The reader to wrap as an input stream.IOException
public ReaderInputStream(Reader reader, CharacterSet characterSet) throws IOException
reader
- The reader to wrap as an input stream.characterSet
- The character set to use for encoding.IOException
public int available() throws IOException
available
in class InputStream
IOException
public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
close
in class InputStream
IOException
public int read() throws IOException
read
in class InputStream
IOException
public int read(byte[] b, int off, int len) throws IOException
read
in class InputStream
IOException
Copyright © 2005–2014. All rights reserved.