25 lines
393 B
Go
25 lines
393 B
Go
package gateway
|
|
|
|
import (
|
|
"go_dreamfactory/pb"
|
|
|
|
"github.com/liwei1dao/lego/base"
|
|
"github.com/liwei1dao/lego/core"
|
|
)
|
|
|
|
type (
|
|
IAgent interface {
|
|
SessionId() string
|
|
IP() string
|
|
UserId() uint32
|
|
WriteMsg(msg *pb.UserMessage) (err error)
|
|
Close() //主动关闭接口
|
|
}
|
|
IGateway interface {
|
|
core.IModule
|
|
Service() base.IRPCXService
|
|
Connect(a IAgent)
|
|
DisConnect(a IAgent)
|
|
}
|
|
)
|