| Modifier and Type | Field and Description |
|---|---|
static int |
COMMAND_SIZE
The number of bytes used to encode a command.
|
static int |
PARAM_SIZE
The number of bytes used to encode a command's attribute.
|
| Constructor and Description |
|---|
TwoArraysPathData(java.nio.ByteBuffer commands,
java.nio.ByteBuffer params)
Creates a decoder that will decode the path encoded in two byte arrays.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
hasRemainingCommand()
Tells whether it remains at least one command to decode.
|
int |
nextCommand()
Gets next encoded command from path.
|
double |
nextCoordinate()
Gets next point coordinate from path.
|
public static final int COMMAND_SIZE
public static final int PARAM_SIZE
public TwoArraysPathData(java.nio.ByteBuffer commands,
java.nio.ByteBuffer params)
commands - the encoded path commands (the first available data is the first path's command)params - the encoded commands' attributes (the first available data is the first command's attribute)public boolean hasRemainingCommand()
PathDatahasRemainingCommand in interface PathDatatrue if, and only if, there is at least one command remaining in this pathpublic int nextCommand()
PathDataCommandDecoder.decodeCommand(int).nextCommand in interface PathDatapublic double nextCoordinate()
PathDatanextCoordinate in interface PathData