client

package
v0.3.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 21, 2022 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	Packer         roc.PackerInterface
	IdGenerator    roc.IdGeneratorInterface
	Serializer     serializer.SerializerInterface
	PushChan       chan string
	ChannelManager *roc.ChannelManager
	Socket         net.Conn
}

func NewAddrClient

func NewAddrClient(addr net.Addr) (*Client, error)

func NewClient

func NewClient(conn net.Conn) *Client

func NewTcpClient

func NewTcpClient(address string) (*Client, error)

func (*Client) FreshSocket

func (c *Client) FreshSocket() error

func (*Client) Loop

func (c *Client) Loop()

func (*Client) Recv

func (c *Client) Recv(id uint32, ret interface{}) exception.ExceptionInterface

func (*Client) SendPacket

func (c *Client) SendPacket(p *roc.Packet) (uint32, error)

func (*Client) SendRequest

func (c *Client) SendRequest(path string, r json.Marshaler) (uint32, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL