package server import ( "git.loafle.net/commons_go/rpc" "git.loafle.net/commons_go/rpc/protocol" ) type ServerHandlers struct { rpc.ServerHandlers RPCRegistry rpc.Registry } func (sh *ServerHandlers) Invoke(codec protocol.RegistryCodec) (result interface{}, err error) { return sh.RPCRegistry.Invoke(codec) } func (sh *ServerHandlers) Validate() { sh.ServerHandlers.Validate() if nil == sh.RPCRegistry { panic("RPCRegistry must be specified.") } }