public interface Input
| 修飾子とタイプ | インタフェースと説明 |
|---|---|
static class |
Input.AbstractInput
Abstract的な
|
| 修飾子とタイプ | メソッドと説明 |
|---|---|
byte |
get() |
default long |
get(byte[] b) |
long |
get(byte[] b,
int offset,
int length) |
default long |
get(Output out) |
InputStream |
getInputStream()
ストリームと完全互換ではないがそれっぽくしてくれる.
|
long |
length()
読めるサイズ long版.
32ビットでは足りないかもと足してみた
|
int |
read()
InputStreamとの違い
入力ブロックせずに
データ:0-255 または データ無し:-1 を返す
|
int |
read(byte[] d)
配列に読む.
|
int |
read(byte[] buf,
int offset,
int length)
配列の一部に読む.
|
default int |
read(ByteBuffer dst) |
default long |
read(Output dst)
データ移動的なところ (Packet / Block 汎用)
readでもwritwでも同じ
|
Packet |
readPacket(long length)
内部的に分割を高速にしたい処理。
|
int |
size()
読めるサイズ int版.
32ビット内であればそのサイズ、それ以上はIntegerの最大値.
|
long |
skip(long length)
InputStream とあわせる.
|
static long |
skipImpl(Input in,
long length)
物理的に読んで捨てるときに使う.
|
static Packet |
splitImpl(Input in,
long length)
標準的なパケットを返す場合の実装.
|
byte[] |
toByteArray()
byte配列に変換する。
|
InputStream getInputStream()
int read()
int read(byte[] buf,
int offset,
int length)
buf - バッファoffset - バッファ位置length - サイズint read(byte[] d)
d - バッファread(byte[],int,int)default long read(Output dst)
dst - 転送先byte get()
default long get(byte[] b)
long get(byte[] b,
int offset,
int length)
default long get(Output out)
default int read(ByteBuffer dst)
byte[] toByteArray()
Packet readPacket(long length)
length - 長さlong skip(long length)
length - skipするサイズlong length()
int size()
static Packet splitImpl(Input in, long length)
in - ストリームlength - 長さstatic long skipImpl(Input in, long length)
in - ストリーム Packet などlength - サイズCopyright © 2024. All rights reserved.