public void Add_Process(int seqid, TProtocol iprot, TProtocol oprot) { Add_args args = new Add_args(); args.Read(iprot); iprot.ReadMessageEnd(); Add_result result = new Add_result(); try { result.Success = iface_.@Add(args.I1, args.I2); oprot.WriteMessageBegin(new TMessage("Add", TMessageType.Reply, seqid)); result.Write(oprot); } catch (TTransportException) { throw; } catch (Exception ex) { Console.Error.WriteLine("Error occurred in processor:"); Console.Error.WriteLine(ex.ToString()); TApplicationException x = new TApplicationException(TApplicationException.ExceptionType.InternalError, " Internal error."); oprot.WriteMessageBegin(new TMessage("Add", TMessageType.Exception, seqid)); x.Write(oprot); } oprot.WriteMessageEnd(); oprot.Transport.Flush(); }
public void Add_Process(int seqid, TProtocol iprot, TProtocol oprot) { Add_args args = new Add_args(); args.Read(iprot); iprot.ReadMessageEnd(); Add_result result = new Add_result(); result.Success = iface_.@Add(args.Customer); oprot.WriteMessageBegin(new TMessage("Add", TMessageType.Reply, seqid)); result.Write(oprot); oprot.WriteMessageEnd(); oprot.Transport.Flush(); }
public void send_Add(Customer customer) #endif { oprot_.WriteMessageBegin(new TMessage("Add", TMessageType.Call, seqid_)); Add_args args = new Add_args(); args.Customer = customer; args.Write(oprot_); oprot_.WriteMessageEnd(); #if SILVERLIGHT return(oprot_.Transport.BeginFlush(callback, state)); #else oprot_.Transport.Flush(); #endif }
public void send_Add(int userId, string userName) #endif { oprot_.WriteMessageBegin(new TMessage("Add", TMessageType.Call, seqid_)); Add_args args = new Add_args(); args.UserId = userId; args.UserName = userName; args.Write(oprot_); oprot_.WriteMessageEnd(); #if SILVERLIGHT return(oprot_.Transport.BeginFlush(callback, state)); #else oprot_.Transport.Flush(); #endif }
public void send_Add(Customer customer) #endif { oprot_.WriteMessageBegin(new TMessage("Add", TMessageType.Call, seqid_)); Add_args args = new Add_args(); args.Customer = customer; args.Write(oprot_); oprot_.WriteMessageEnd(); #if SILVERLIGHT return oprot_.Transport.BeginFlush(callback, state); #else oprot_.Transport.Flush(); #endif }