Interface SerializationService
-
- All Implemented Interfaces:
@DoNotImplement() public interface SerializationService
Allows flows to serialize and deserialize objects to/from byte arrays.
Objects are serialized and deserialized using AMQP serialization.
Corda provides an instance of SerializationService to flows via property injection.
-
-
Method Summary
Modifier and Type Method Description abstract <T> SerializedBytes<T>
serialize(@NotNull() T obj)
Serializes the input obj
.abstract <T> T
deserialize(@NotNull() SerializedBytes<T> serializedBytes, @NotNull() Class<T> clazz)
Deserializes the input serialized bytes into an object of type . abstract <T> T
deserialize(@NotNull() Array<byte> bytes, @NotNull() Class<T> clazz)
Deserializes the input serialized bytes into an object of type . -
-
Method Detail
-
serialize
@NotNull() abstract <T> SerializedBytes<T> serialize(@NotNull() T obj)
Serializes the input
obj
.- Parameters:
obj
- The object to serialize.
-
deserialize
@NotNull() abstract <T> T deserialize(@NotNull() SerializedBytes<T> serializedBytes, @NotNull() Class<T> clazz)
Deserializes the input serialized bytes into an object of type .
- Parameters:
serializedBytes
- The SerializedBytes to deserialize.clazz
- Class containing the type to deserialize to.
-
-
-
-