- All Implemented Interfaces:
Serializable,Comparable<MessageType>
The types of serializations.
-
Enum Constant Summary
Enum Constants -
Method Summary
Modifier and TypeMethodDescriptionabstract MessageDeprecated, for removal: This API element is subject to removal in a future version.abstract Messagedecode(ByteArray encodedMessage, IOSupplier<TempFileContext> tempFileContextSupplier) Constructs a message of this type from its byte array encoding using the providedtemporary file contextsupplier as-needed.final Messagedecode(ByteArray encodedMessage, TempFileContext tempFileContext) Deprecated.Please useTempFileContextsupplier which may defer creation until first needed.abstract MessageDeprecated, for removal: This API element is subject to removal in a future version.Please useTempFileContextsupplier sinceFile.deleteOnExit()is prone to memory leaks in long-running applications.abstract Messagedecode(String encodedMessage, IOSupplier<TempFileContext> tempFileContextSupplier) Constructs a message of this type from its string encoding using the providedtemporary file contextsupplier as-needed.final Messagedecode(String encodedMessage, TempFileContext tempFileContext) Deprecated.Please useTempFileContextsupplier which may defer creation until first needed.static MessageTypegetFromTypeByte(byte typeByte) Gets the message type for its numeric code.static MessageTypegetFromTypeChar(char typeChar) Gets the message type for its character code.abstract byteGets the single byte that uniquely represents this message type.abstract charGets the single character that uniquely represents this message type.static MessageTypeReturns the enum constant of this type with the specified name.static MessageType[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
BYTE_ARRAY
-
FILE
-
STRING
-
MULTI
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-
getFromTypeByte
Gets the message type for its numeric code. -
getFromTypeChar
Gets the message type for its character code. -
getTypeByte
public abstract byte getTypeByte()Gets the single byte that uniquely represents this message type. -
getTypeChar
public abstract char getTypeChar()Gets the single character that uniquely represents this message type. -
decode
public abstract Message decode(String encodedMessage, IOSupplier<TempFileContext> tempFileContextSupplier) throws IOException Constructs a message of this type from its string encoding using the providedtemporary file contextsupplier as-needed.- Throws:
IOException
-
decode
public final Message decode(String encodedMessage, TempFileContext tempFileContext) throws IOException Deprecated.Please useTempFileContextsupplier which may defer creation until first needed.Constructs a message of this type from its string encoding using the providedtemporary file contextas-needed.- Throws:
IOException- See Also:
-
decode
@Deprecated(forRemoval=true) public abstract Message decode(String encodedMessage) throws IOException Deprecated, for removal: This API element is subject to removal in a future version.Please useTempFileContextsupplier sinceFile.deleteOnExit()is prone to memory leaks in long-running applications.Constructs a message of this type from its string encoding, possibly using temporary files withFile.deleteOnExit()as-needed.- Throws:
IOException- See Also:
-
decode
public abstract Message decode(ByteArray encodedMessage, IOSupplier<TempFileContext> tempFileContextSupplier) throws IOException Constructs a message of this type from its byte array encoding using the providedtemporary file contextsupplier as-needed.- Throws:
IOException
-
decode
public final Message decode(ByteArray encodedMessage, TempFileContext tempFileContext) throws IOException Deprecated.Please useTempFileContextsupplier which may defer creation until first needed.Constructs a message of this type from its byte array encoding using the providedtemporary file contextas-needed.- Throws:
IOException- See Also:
-
decode
@Deprecated(forRemoval=true) public abstract Message decode(ByteArray encodedMessage) throws IOException Deprecated, for removal: This API element is subject to removal in a future version.Please useTempFileContextsupplier sinceFile.deleteOnExit()is prone to memory leaks in long-running applications.Constructs a message of this type from its byte array encoding, possibly using temporary files withFile.deleteOnExit()as-needed.- Throws:
IOException- See Also:
-

TempFileContextsupplier sinceFile.deleteOnExit()is prone to memory leaks in long-running applications.