Package org.bouncycastle.tls
Class HeartbeatMessage
- java.lang.Object
-
- org.bouncycastle.tls.HeartbeatMessage
-
public class HeartbeatMessage extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description HeartbeatMessage(short type, byte[] payload, byte[] padding)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static HeartbeatMessage
create(TlsContext context, short type, byte[] payload)
static HeartbeatMessage
create(TlsContext context, short type, byte[] payload, int paddingLength)
void
encode(java.io.OutputStream output)
Encode thisHeartbeatMessage
to anOutputStream
.int
getPaddingLength()
byte[]
getPayload()
short
getType()
static HeartbeatMessage
parse(java.io.InputStream input)
Parse aHeartbeatMessage
from anInputStream
.
-
-
-
Method Detail
-
create
public static HeartbeatMessage create(TlsContext context, short type, byte[] payload)
-
create
public static HeartbeatMessage create(TlsContext context, short type, byte[] payload, int paddingLength)
-
getPaddingLength
public int getPaddingLength()
-
getPayload
public byte[] getPayload()
-
getType
public short getType()
-
encode
public void encode(java.io.OutputStream output) throws java.io.IOException
Encode thisHeartbeatMessage
to anOutputStream
.- Parameters:
output
- theOutputStream
to encode to.- Throws:
java.io.IOException
-
parse
public static HeartbeatMessage parse(java.io.InputStream input) throws java.io.IOException
Parse aHeartbeatMessage
from anInputStream
.- Parameters:
input
- theInputStream
to parse from.- Returns:
- a
HeartbeatMessage
object. - Throws:
java.io.IOException
-
-