Documentation ¶
Index ¶
Constants ¶
View Source
const (
PacketHeadSize = 2
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PingPacket ¶
func NewPingPacket ¶
func NewPingPacket(body []byte) *PingPacket
func (*PingPacket) Marshal ¶
func (self *PingPacket) Marshal() []byte
type PingProtocol ¶
type PingProtocol struct {
// contains filtered or unexported fields
}
func (*PingProtocol) OnMessage ¶
func (self *PingProtocol) OnMessage(fn func(c *tcpsock.TcpConn, p *PingPacket))
Click to show internal directories.
Click to hide internal directories.