|
||||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | |||||||||
| 概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | |||||||||
java.lang.Objectjava.io.Reader
java.io.FilterReader
org.aminds.io.ReusableFilterReader
org.aminds.io.LookaheadReader
public class LookaheadReader
A Reader that is capable of looking ahead. It allows to read code points as well as chars (Unicode code units).
| フィールドの概要 | |
|---|---|
protected CharQueue |
queue
|
| クラス java.io.FilterReader から継承されたフィールド |
|---|
in |
| クラス java.io.Reader から継承されたフィールド |
|---|
lock |
| コンストラクタの概要 | |
|---|---|
LookaheadReader(Reader in)
|
|
LookaheadReader(Reader in,
int initCapacity)
|
|
| メソッドの概要 | |
|---|---|
void |
close()
|
int |
codePointAt(int index)
|
int |
lookahead(int index)
Look ahead a character at the position specified by the index from the current position of the stream. |
int |
lookaheadCodePoint()
Look ahead a next character as Unicode code point, not as UTF-16 code unit. |
int |
lookaheadCodePoint(int index)
Look ahead a character as Unicode code point, not as UTF-16 code unit, at the position specified. |
void |
mark(int readAheadLimit)
|
boolean |
markSupported()
|
int |
offsetsByCodePoints(int index,
int codePointOffset)
|
int |
read()
|
int |
read(char[] cbuf,
int off,
int len)
|
int |
readCodePoint()
Read a single code point, not a character as UTF-16 code unit, contrasting with read(). |
boolean |
ready()
|
void |
reset()
|
void |
reset(Reader in)
Reset the contained Reader. |
void |
reset(Reader in,
int capacity)
|
long |
skip(long n)
|
long |
skipCodePoint(long n)
Skip characters by units of code point. |
| クラス java.io.Reader から継承されたメソッド |
|---|
read, read |
| クラス java.lang.Object から継承されたメソッド |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| フィールドの詳細 |
|---|
protected CharQueue queue
| コンストラクタの詳細 |
|---|
public LookaheadReader(Reader in)
public LookaheadReader(Reader in,
int initCapacity)
| メソッドの詳細 |
|---|
public int read()
throws IOException
FilterReader 内の readIOException
public int read(char[] cbuf,
int off,
int len)
throws IOException
FilterReader 内の readIOException
public long skip(long n)
throws IOException
FilterReader 内の skipIOException
public boolean ready()
throws IOException
FilterReader 内の readyIOExceptionpublic boolean markSupported()
FilterReader 内の markSupported
public void mark(int readAheadLimit)
throws IOException
FilterReader 内の markIOException
public void reset()
throws IOException
FilterReader 内の resetIOException
public void close()
throws IOException
Closeable 内の closeFilterReader 内の closeIOException
public void reset(Reader in)
throws IOException
ReusableFilterReader の記述:reset() nor close() method
of the underlying Reader,
while FilterReader.reset() does invoke
reset() of the underlying.
ReusableFilterReader 内の resetin - a new Reader
IOException
public void reset(Reader in,
int capacity)
throws IOException
IOException
public int lookahead(int index)
throws IOException
index - a position relative to the current position of the stream, >= 0
IllegalArgumentException - If index is negative.
IOException - If an I/O error occurs
public int readCodePoint()
throws IOException
IOException - If an I/O error occurs
public int lookaheadCodePoint()
throws IOException
IOException - If an I/O error occurs
public int lookaheadCodePoint(int index)
throws IOException
FIXME: we may need faster implementation.
index - index by units of code point, relative to the current position of the stream, >= 0
IllegalArgumentException - If index is negative.
IOException - If an I/O error occurs
public int offsetsByCodePoints(int index,
int codePointOffset)
public int codePointAt(int index)
public long skipCodePoint(long n)
throws IOException
n - The number of code points to skip
IllegalArgumentException - If n is negative.
IOException - If an I/O error occurs
|
||||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | |||||||||
| 概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | |||||||||