Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrInvalidProtoMessage = errors.New("invalid proto message")
)
Functions ¶
func NewLengthFieldBasedFromDecoder ¶ added in v0.1.6
func NewWebsocketClientDecoder ¶ added in v0.1.6
Types ¶
type JsonCodec ¶ added in v0.1.5
type JsonCodec struct {
}
func NewJsonCodec ¶ added in v0.1.5
func NewJsonCodec() *JsonCodec
type LengthFieldBasedFrameDecoder ¶ added in v0.1.6
func (*LengthFieldBasedFrameDecoder) Read ¶ added in v0.1.6
func (decoder *LengthFieldBasedFrameDecoder) Read(bytes []byte) (n int, err error)
func (*LengthFieldBasedFrameDecoder) SyscallConn ¶ added in v0.1.6
func (c *LengthFieldBasedFrameDecoder) SyscallConn() (syscall.RawConn, error)
SyscallConn prepare for epoll
type Options ¶
type Options struct {
// contains filtered or unexported fields
}
Options represents options options
func DefaultOptions ¶ added in v0.1.5
func DefaultOptions() *Options
Default returns the default options implementation,the packet is composed by : |-------------- header --------------|-------- body --------| |packetLength| action | seq |-------- body --------| | 4 | 2 | 2 | n |
type ProtoCodec ¶ added in v0.1.5
type ProtoCodec struct {
}
func NewProtoCodec ¶ added in v0.1.5
func NewProtoCodec() *ProtoCodec
Click to show internal directories.
Click to hide internal directories.