public final class ReaderInputStream extends InputStream
Constructor and Description |
---|
ReaderInputStream(Reader reader)
Construct a new instance.
|
ReaderInputStream(Reader reader,
Charset charset)
Construct a new instance.
|
ReaderInputStream(Reader reader,
CharsetEncoder encoder)
Construct a new instance.
|
ReaderInputStream(Reader reader,
CharsetEncoder encoder,
int bufferSize)
Construct a new instance.
|
ReaderInputStream(Reader reader,
String charsetName)
Construct a new instance.
|
Modifier and Type | Method and Description |
---|---|
int |
available() |
void |
close() |
int |
read() |
int |
read(byte[] b,
int off,
int len) |
long |
skip(long n) |
String |
toString()
Get a string representation of this object.
|
mark, markSupported, read, reset
public ReaderInputStream(Reader reader)
reader
- the reader to encode frompublic ReaderInputStream(Reader reader, String charsetName) throws UnsupportedEncodingException
reader
- the reader to encode fromcharsetName
- the character set nameUnsupportedEncodingException
- if the character set is not supportedpublic ReaderInputStream(Reader reader, Charset charset)
reader
- the reader to encode fromcharset
- the character setpublic ReaderInputStream(Reader reader, CharsetEncoder encoder)
reader
- the reader to encode fromencoder
- the character set encoderpublic ReaderInputStream(Reader reader, CharsetEncoder encoder, int bufferSize)
reader
- the reader to encode fromencoder
- the character set encoderbufferSize
- the buffer size to usepublic 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
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 interface AutoCloseable
close
in class InputStream
IOException
Copyright © 2020 JBoss by Red Hat. All rights reserved.