Phoenix v1.3.0 Phoenix.Transports.Serializer behaviour View Source

Defines a behaviour for Phoenix.Socket.Message serialization.

Link to this section Summary

Callbacks

Encodes Phoenix.Socket.Message struct to transport representation

Translates a Phoenix.Socket.Broadcast struct to fastlane format

Link to this section Callbacks

Link to this callback decode!(iodata, options) View Source
decode!(iodata(), options :: Keyword.t()) :: Phoenix.Socket.Message.t()

Decodes iodata into Phoenix.Socket.Message struct

Encodes Phoenix.Socket.Message struct to transport representation

Translates a Phoenix.Socket.Broadcast struct to fastlane format