public final class StreamReader extends Object
| Constructor and Description |
|---|
StreamReader(Reader reader,
LoadSettings loadSettings) |
StreamReader(String stream,
LoadSettings loadSettings) |
| Modifier and Type | Method and Description |
|---|---|
void |
forward() |
void |
forward(int length)
read the next length characters and move the pointer.
|
int |
getColumn() |
int |
getIndex() |
int |
getLine() |
Optional<Mark> |
getMark() |
static boolean |
isPrintable(int c) |
static boolean |
isPrintable(String data) |
int |
peek() |
int |
peek(int index)
Peek the next index-th code point
|
String |
prefix(int length)
peek the next length code points
|
String |
prefixForward(int length)
prefix(length) immediately followed by forward(length)
|
public StreamReader(Reader reader, LoadSettings loadSettings)
public StreamReader(String stream, LoadSettings loadSettings)
public static final boolean isPrintable(String data)
public static boolean isPrintable(int c)
public void forward()
public void forward(int length)
length - amount of characters to move forwardpublic int peek()
public int peek(int index)
index - to peekpublic String prefix(int length)
length - amount of the characters to peekpublic String prefixForward(int length)
length - amount of characters to getpublic int getColumn()
public int getIndex()
public int getLine()
Copyright © 2018–2019. All rights reserved.