Documentation
¶
Index ¶
- Constants
- type Agent
- func (a *Agent) Close()
- func (a *Agent) Kick(reason interface{})
- func (a *Agent) Push(route string, val interface{})
- func (a *Agent) RPC(route string, val interface{}, _ *cherryProto.Response)
- func (a *Agent) RemoteAddr() string
- func (a *Agent) Response(mid uint, v interface{}, isError ...bool)
- func (a *Agent) Run()
- func (a *Agent) Send(typ cherryMessage.Type, route string, mid uint, v interface{}, isError bool)
- func (a *Agent) SendRaw(bytes []byte)
- func (a *Agent) SetLastAt()
- func (a *Agent) SetSession(session *cherrySession.Session)
- type AgentBackend
- func (a *AgentBackend) Close()
- func (a *AgentBackend) Kick(reason interface{})
- func (a *AgentBackend) Push(route string, val interface{})
- func (a *AgentBackend) RPC(route string, val interface{}, rsp *cherryProto.Response)
- func (a *AgentBackend) RemoteAddr() string
- func (a *AgentBackend) Response(mid uint, val interface{}, isError ...bool)
- func (a *AgentBackend) SendRaw(_ []byte)
- func (a *AgentBackend) SetSession(session *cherrySession.Session)
- type Options
Constants ¶
View Source
const (
WriteBacklog = 64
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Agent ¶
type Agent struct { sync.RWMutex *Options cherryFacade.IApplication // contains filtered or unexported fields }
func (*Agent) RemoteAddr ¶
func (*Agent) SetSession ¶ added in v1.1.24
func (a *Agent) SetSession(session *cherrySession.Session)
type AgentBackend ¶ added in v1.1.9
type AgentBackend struct { cherryFacade.IApplication // contains filtered or unexported fields }
func NewAgentBackend ¶ added in v1.1.20
func NewAgentBackend(app cherryFacade.IApplication, rpcClient cherryFacade.RPCClient, ip string) AgentBackend
func (*AgentBackend) Close ¶ added in v1.1.9
func (a *AgentBackend) Close()
func (*AgentBackend) Kick ¶ added in v1.1.9
func (a *AgentBackend) Kick(reason interface{})
func (*AgentBackend) Push ¶ added in v1.1.9
func (a *AgentBackend) Push(route string, val interface{})
func (*AgentBackend) RPC ¶ added in v1.1.9
func (a *AgentBackend) RPC(route string, val interface{}, rsp *cherryProto.Response)
func (*AgentBackend) RemoteAddr ¶ added in v1.1.9
func (a *AgentBackend) RemoteAddr() string
func (*AgentBackend) Response ¶ added in v1.1.9
func (a *AgentBackend) Response(mid uint, val interface{}, isError ...bool)
func (*AgentBackend) SendRaw ¶ added in v1.1.9
func (a *AgentBackend) SendRaw(_ []byte)
func (*AgentBackend) SetSession ¶ added in v1.1.20
func (a *AgentBackend) SetSession(session *cherrySession.Session)
Click to show internal directories.
Click to hide internal directories.