Documentation ¶
Index ¶
Constants ¶
View Source
const ( TypeHeaderName = "type" MessageTypeHeaderName = "mtyp" JsonType = "json" GobType = "gob" XmlType = "xml" )
Variables ¶
View Source
var ( ErrMessageTooSmall = errors.New("message is too small") ErrInvalidMessageType = errors.New("invalid message type") )
Functions ¶
This section is empty.
Types ¶
type Codec ¶
type Codec struct {
// contains filtered or unexported fields
}
func (*Codec) AddDecoder ¶
func (c *Codec) AddDecoder(contentType string, decoder DecoderFactory)
func (*Codec) AddEncoder ¶
func (c *Codec) AddEncoder(contentType string, encoder EncoderFactory)
type DecoderFactory ¶
type EncoderFactory ¶
type Envelope ¶
type Envelope struct {
// contains filtered or unexported fields
}
func NewEnvelope ¶
type Factory ¶
type Factory interface { EncoderFactory DecoderFactory }
type Registry ¶
type Registry struct {
// contains filtered or unexported fields
}
func NewRegistry ¶
func NewRegistry() *Registry
func (*Registry) MessageType ¶
type Serializer ¶
type Serializer struct {
// contains filtered or unexported fields
}
func NewSerializer ¶
func NewSerializer(registry *Registry, codec *Codec, defaultType string) *Serializer
Click to show internal directories.
Click to hide internal directories.