Documentation ¶
Index ¶
- Constants
- func BytesToInt32(buf []byte) int32
- func BytesToInt64(buf []byte) int64
- func Init(endian string)
- func Int32ToBytes(num int32) []byte
- func Int64ToBytes(num int64) []byte
- type Default
- type IConnection
- type IPacket
- type PacketConfig
- type Tcp
- func (t *Tcp) Close() error
- func (t *Tcp) Closed() bool
- func (t *Tcp) FD() int
- func (t *Tcp) RQueue() chan IPacket
- func (t *Tcp) Read(hLen, bLen, bLenOffset int) ([]byte, error)
- func (t *Tcp) Send(pack IPacket) error
- func (t *Tcp) SendBytes(buf []byte) error
- func (t *Tcp) WQueue() chan []byte
- func (t *Tcp) Write(pack []byte) (int, error)
- type WebSocket
- func (t *WebSocket) Close() error
- func (t *WebSocket) Closed() bool
- func (t *WebSocket) FD() int
- func (t *WebSocket) RQueue() chan IPacket
- func (t *WebSocket) Read(hLen, bLen, bLenOffset int) ([]byte, error)
- func (t *WebSocket) Send(pack IPacket) error
- func (t *WebSocket) SendBytes(buf []byte) error
- func (t *WebSocket) WQueue() chan []byte
- func (t *WebSocket) Write(pack []byte) (int, error)
Constants ¶
View Source
const ( CHANNEL_PACKET_MAX = 1024 Packet_Max_Len = 2097152 )
Variables ¶
This section is empty.
Functions ¶
func BytesToInt32 ¶
func BytesToInt64 ¶
func Int32ToBytes ¶
func Int64ToBytes ¶
Types ¶
type Default ¶
type Default struct {
// contains filtered or unexported fields
}
func NewDefault ¶
func NewDefault() *Default
func (*Default) BodyOffset ¶
func (*Default) Unserialize ¶
type IConnection ¶
type PacketConfig ¶
Click to show internal directories.
Click to hide internal directories.