Package org.ldk.structs
Class ErrorMessage
- java.lang.Object
-
- org.ldk.structs.ErrorMessage
-
public class ErrorMessage extends Object
An error message to be sent or received from a peer
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description ErrorMessage
clone()
Creates a copy of the ErrorMessageprotected void
finalize()
byte[]
get_channel_id()
The channel ID involved in the errorString
get_data()
A possibly human-readable error description.static ErrorMessage
of(byte[] channel_id_arg, String data_arg)
Constructs a new ErrorMessage given each fieldstatic Result_ErrorMessageDecodeErrorZ
read(byte[] ser)
Read a ErrorMessage from a byte array, created by ErrorMessage_writevoid
set_channel_id(byte[] val)
The channel ID involved in the errorvoid
set_data(String val)
A possibly human-readable error description.byte[]
write()
Serialize the ErrorMessage object into a byte array which can be read by ErrorMessage_read
-
-
-
Method Detail
-
finalize
protected void finalize() throws Throwable
-
get_channel_id
public byte[] get_channel_id()
The channel ID involved in the error
-
set_channel_id
public void set_channel_id(byte[] val)
The channel ID involved in the error
-
get_data
public String get_data()
A possibly human-readable error description. The string should be sanitized before it is used (e.g. emitted to logs or printed to stdout). Otherwise, a well crafted error message may trigger a security vulnerability in the terminal emulator or the logging subsystem.
-
set_data
public void set_data(String val)
A possibly human-readable error description. The string should be sanitized before it is used (e.g. emitted to logs or printed to stdout). Otherwise, a well crafted error message may trigger a security vulnerability in the terminal emulator or the logging subsystem.
-
of
public static ErrorMessage of(byte[] channel_id_arg, String data_arg)
Constructs a new ErrorMessage given each field
-
clone
public ErrorMessage clone()
Creates a copy of the ErrorMessage
-
write
public byte[] write()
Serialize the ErrorMessage object into a byte array which can be read by ErrorMessage_read
-
read
public static Result_ErrorMessageDecodeErrorZ read(byte[] ser)
Read a ErrorMessage from a byte array, created by ErrorMessage_write
-
-