Photon Server API
Public Member Functions | List of all members
ExitGames.Messaging.Channels.IMessageSerializer< T > Interface Template Reference

The implementor converts a message to a byte array and back. The IMessageSerializer<T> is used to de-/serialize messages to the TopicPublisher<T> and the TopicSubscription<T>. More...

Inheritance diagram for ExitGames.Messaging.Channels.IMessageSerializer< T >:
ExitGames.Messaging.Channels.GenericSerializer< T >

Public Member Functions

Deserialize (byte[] bytes)
 Deserializes a message. More...
 
byte[] Serialize (T message)
 Serialize a message. More...
 

Detailed Description

The implementor converts a message to a byte array and back. The IMessageSerializer<T> is used to de-/serialize messages to the TopicPublisher<T> and the TopicSubscription<T>.

Template Parameters
TThe message type.

Member Function Documentation

T ExitGames.Messaging.Channels.IMessageSerializer< T >.Deserialize ( byte[]  bytes)

Deserializes a message.

Parameters
bytesThe bytes.
Returns
A message.

Implemented in ExitGames.Messaging.Channels.GenericSerializer< T >.

byte [] ExitGames.Messaging.Channels.IMessageSerializer< T >.Serialize ( message)

Serialize a message.

Parameters
messageThe message.
Returns
A byte array.

Implemented in ExitGames.Messaging.Channels.GenericSerializer< T >.