public void Insert_Process(int seqid, TProtocol iprot, TProtocol oprot) { Insert_args args = new Insert_args(); args.Read(iprot); iprot.ReadMessageEnd(); Insert_result result = new Insert_result(); result.Success = iface_.Insert(args.Entry); oprot.WriteMessageBegin(new TMessage("Insert", TMessageType.Reply, seqid)); result.Write(oprot); oprot.WriteMessageEnd(); oprot.Transport.Flush(); }
public CalculonDb.Result recv_Insert() { TMessage msg = iprot_.ReadMessageBegin(); if (msg.Type == TMessageType.Exception) { TApplicationException x = TApplicationException.Read(iprot_); iprot_.ReadMessageEnd(); throw x; } Insert_result result = new Insert_result(); result.Read(iprot_); iprot_.ReadMessageEnd(); if (result.__isset.success) { return result.Success; } throw new TApplicationException(TApplicationException.ExceptionType.MissingResult, "Insert failed: unknown result"); }