public class Pong extends Message
Instances of this class are not safe for use by multiple threads.
cursor, length, MAX_SIZE, offset, params, payload, protocolVersion, recached, serializer, UNKNOWN_LENGTH
Constructor and Description |
---|
Pong(long nonce)
Create a Pong with a nonce value.
|
Pong(NetworkParameters params,
byte[] payloadBytes) |
Modifier and Type | Method and Description |
---|---|
void |
bitcoinSerializeToStream(java.io.OutputStream stream)
Serializes this message to the provided stream.
|
long |
getNonce()
Returns the nonce sent by the remote peer.
|
protected void |
parse() |
adjustLength, bitcoinSerialize, bitcoinSerialize, getHash, getMessageSize, getParams, hasMoreBytes, isCached, isRecached, readByteArray, readBytes, readHash, readInt64, readStr, readUint32, readUint64, readVarInt, readVarInt, unCache, unsafeBitcoinSerialize
public Pong(NetworkParameters params, byte[] payloadBytes) throws ProtocolException
ProtocolException
public Pong(long nonce)
protected void parse() throws ProtocolException
parse
in class Message
ProtocolException
public void bitcoinSerializeToStream(java.io.OutputStream stream) throws java.io.IOException
Message
bitcoinSerializeToStream
in class Message
java.io.IOException
public long getNonce()