Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ArgsForNewConnectionFromUser ¶
type ArgsForNewConnectionFromUser struct {
Name string `json:"name"` // 服务名
}
type ArgsForRegisterAsProxy ¶
type ArgsForRegisterAsProxy struct {
ID string `json:"string"` // 等于请求的command.ID
}
type ArgsNewConnectionFromClient ¶
type ArgsNewConnectionFromClient struct {
ID string `json:"id"` // 响应请求ID
}
type Command ¶
type Command struct { ID string `json:"id,omitempty"` Command CommandType `json:"cmd"` Args []byte `json:"args,omitempty"` }
type CommandType ¶
type CommandType uint32
const ( Noop CommandType = iota RegisterAsControl // xlan-c 向 xlan-s 建立连接, 标记自己身份为控制连接 RegisterAsProxy // xlan-c 向 xlan-s 建立连接, 标记自己身份为代理连接 RegisterService // xlan-c向xlan-s注册服务 NewConnectionFromUser // xlan-s 向 xlan-c 发送命令, 告知有新的 user 请求 )
func (CommandType) String ¶
func (ct CommandType) String() string
Click to show internal directories.
Click to hide internal directories.