You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
package core
|
|
|
|
import "git.noahlan.cn/noahlan/nnet/packet"
|
|
|
|
type (
|
|
Handler interface {
|
|
Handle(conn *Connection, pkg packet.IPacket)
|
|
}
|
|
|
|
HandlerFunc func(conn *Connection, pkg packet.IPacket)
|
|
)
|
|
|
|
func (f HandlerFunc) Handle(conn *Connection, pkg packet.IPacket) {
|
|
f(conn, pkg)
|
|
}
|