Package com.io7m.cedarbridge.runtime.api

# Interface CBProtocolMessageSerializerType<T extends CBProtocolMessageType>

Type Parameters:
  `T` - The precise type of protocol message

All Known Subinterfaces:
  `CBProtocolMessageVersionedSerializerType<T>`

public interface CBProtocolMessageSerializerType<T extends CBProtocolMessageType>
The type of serializers for protocol messages.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `T`
  `deserialize(CBSerializationContextType context)`
  Deserialize a message.
  `Class<T>`
  `messageClass()`
  `void`
  `serialize(CBSerializationContextType context, T value)`
  Serialize a message.

- ## Method Details

  - ### messageClass

    Class<T> messageClass()
    Returns:
      The type of messages handled by this serializer

  - ### serialize

    void serialize(CBSerializationContextType context, T value) throws IOException
    Serialize a message.
    Parameters:
      `context` - The serialization context
      `value` - The message
    Throws:
      `IOException` - On errors

  - ### deserialize

    T deserialize(CBSerializationContextType context) throws IOException
    Deserialize a message.
    Parameters:
      `context` - The serialization context
    Returns:
      The message
    Throws:
      `IOException` - On errors