Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrIncompletePacket = errors.New("incomplete packet")
Functions ¶
This section is empty.
Types ¶
type SimpleCodec ¶
type SimpleCodec struct{}
SimpleCodec Protocol format:
* 0 2 6 * +-----------+-----------------------+ * | magic | body len | * +-----------+-----------+-----------+ * | | * + + * | body bytes | * + + * | ... ... | * +-----------------------------------+
func (*SimpleCodec) Decode ¶
func (codec *SimpleCodec) Decode(c gnet.Conn) ([]byte, error)
Click to show internal directories.
Click to hide internal directories.