public void CallMethod(global::ClosetRpc.IRpcCall rpcCall)
 {
     if (rpcCall.MethodName == "Changed")
     {
         var input = new SettingList();
         input.MergeFrom(new CodedInputStream(rpcCall.CallData));
         this.Impl.OnChanged(input);
     }
     else
     {
         // TODO: Generate diagnostics?.
     }
 }
        public void CallMethod(global::ClosetRpc.IServerContext context, global::ClosetRpc.IRpcCall rpcCall, global::ClosetRpc.IRpcResult rpcResult)
        {
            rpcResult.Status = global::ClosetRpc.RpcStatus.Succeeded;

            if (rpcCall.MethodName == "Get")
            {
                var input = new SettingKeyList();
                input.MergeFrom(new CodedInputStream(rpcCall.CallData));
                var result = this.Impl.Get(context, input);
                rpcResult.ResultData = result.ToByteArray();
            }
            else if (rpcCall.MethodName == "Set")
            {
                var input = new SettingList();
                input.MergeFrom(new CodedInputStream(rpcCall.CallData));
                this.Impl.Set(context, input);
            }
            else
            {
                rpcResult.Status = global::ClosetRpc.RpcStatus.UnknownMethod;
            }

            // TODO: Generate an exception handling code.
        }