public final class Buffer extends Object implements Readable
Modifier and Type | Class and Description |
---|---|
static class |
Buffer.BufferException |
Modifier and Type | Field and Description |
---|---|
static int |
DEFAULT_SIZE |
static int |
MAX_LEN |
Constructor and Description |
---|
Buffer() |
Buffer(byte[] data) |
Buffer(byte[] data,
boolean read) |
Buffer(byte[] data,
int off,
int len) |
Buffer(byte[] data,
int off,
int len,
boolean read) |
Buffer(int size) |
Modifier and Type | Method and Description |
---|---|
byte[] |
array() |
int |
available() |
void |
clear() |
void |
compact() |
boolean |
getBoolean() |
byte |
getByte() |
byte[] |
getBytes() |
byte[] |
getCompactData() |
int |
getInt() |
KeyPair |
getKeyPair() |
long |
getLong() |
BigInteger |
getMPInt() |
byte[] |
getMPIntAsBytes() |
PublicKey |
getPublicKey() |
void |
getRawBytes(byte[] buf) |
void |
getRawBytes(byte[] buf,
int off,
int len) |
PublicKey |
getRawPublicKey() |
String |
getString() |
byte[] |
getStringAsBytes() |
long |
getUInt() |
String |
printHex() |
void |
putBoolean(boolean b) |
void |
putBuffer(Readable buffer) |
void |
putByte(byte b) |
void |
putBytes(byte[] b) |
void |
putBytes(byte[] b,
int off,
int len) |
void |
putInt(long i)
Writes 32 bits
|
void |
putKeyPair(KeyPair key) |
void |
putLong(long i)
Writes 64 bits
|
void |
putMPInt(BigInteger bi) |
void |
putMPInt(byte[] foo) |
void |
putPublicKey(PublicKey key) |
void |
putRawBytes(byte[] d) |
void |
putRawBytes(byte[] d,
int off,
int len) |
void |
putRawPublicKey(PublicKey key) |
void |
putString(byte[] str) |
void |
putString(String string) |
int |
rpos() |
void |
rpos(int rpos) |
String |
toString() |
int |
wpos() |
void |
wpos(int wpos) |
public static final int DEFAULT_SIZE
public static final int MAX_LEN
public Buffer()
public Buffer(int size)
public Buffer(byte[] data)
public Buffer(byte[] data, boolean read)
public Buffer(byte[] data, int off, int len)
public Buffer(byte[] data, int off, int len, boolean read)
public int rpos()
public void rpos(int rpos)
public int wpos()
public void wpos(int wpos)
public byte[] array()
public void compact()
public byte[] getCompactData()
public void clear()
public String printHex()
public byte getByte()
public int getInt()
public long getUInt()
public long getLong()
public boolean getBoolean()
public String getString()
public byte[] getStringAsBytes()
public BigInteger getMPInt()
public byte[] getMPIntAsBytes()
public byte[] getBytes()
public void getRawBytes(byte[] buf)
public void getRawBytes(byte[] buf, int off, int len)
getRawBytes
in interface Readable
public PublicKey getPublicKey() throws SshException
SshException
public PublicKey getRawPublicKey() throws SshException
SshException
public KeyPair getKeyPair() throws SshException
SshException
public void putByte(byte b)
public void putBuffer(Readable buffer)
public void putInt(long i)
i
- public void putLong(long i)
i
- public void putBoolean(boolean b)
public void putBytes(byte[] b)
public void putBytes(byte[] b, int off, int len)
public void putString(String string)
public void putString(byte[] str)
public void putMPInt(BigInteger bi)
public void putMPInt(byte[] foo)
public void putRawBytes(byte[] d)
public void putRawBytes(byte[] d, int off, int len)
public void putPublicKey(PublicKey key)
public void putRawPublicKey(PublicKey key)
public void putKeyPair(KeyPair key)
Copyright © 2008–2016 The Apache Software Foundation. All rights reserved.