public void GetUser_Process(int seqid, TProtocol iprot, TProtocol oprot)
            {
                GetUser_args args = new GetUser_args();

                args.Read(iprot);
                iprot.ReadMessageEnd();
                GetUser_result result = new GetUser_result();

                try
                {
                    result.Success = iface_.GetUser(args.UserID.Value);
                    oprot.WriteMessageBegin(new TMessage("GetUser", 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("GetUser", TMessageType.Exception, seqid));
                    x.Write(oprot);
                }
                oprot.WriteMessageEnd();
                oprot.Transport.Flush();
            }
Esempio n. 2
0
            public void send_GetUser(int userId)
            {
                oprot_.WriteMessageBegin(new TMessage("GetUser", TMessageType.Call, seqid_));
                GetUser_args args = new GetUser_args();

                args.UserId = userId;
                args.Write(oprot_);
                oprot_.WriteMessageEnd();
                oprot_.Transport.Flush();
            }
            public void send_GetUser(int UserID)
#endif
            {
                oprot_.WriteMessageBegin(new TMessage("GetUser", TMessageType.Call, seqid_));
                GetUser_args args = new GetUser_args();

                args.UserID = UserID;
                args.Write(oprot_);
                oprot_.WriteMessageEnd();
#if SILVERLIGHT
                return(oprot_.Transport.BeginFlush(callback, state));
#else
                oprot_.Transport.Flush();
#endif
            }
Esempio n. 4
0
            public void GetUser_Process(int seqid, TProtocol iprot, TProtocol oprot)
            {
                GetUser_args args = new GetUser_args();

                args.Read(iprot);
                iprot.ReadMessageEnd();
                GetUser_result result = new GetUser_result();

                try {
                    result.Success = iface_.GetUser(args.UserId);
                } catch (IllegalityUserIdException ex) {
                    result.Ex = ex;
                }
                oprot.WriteMessageBegin(new TMessage("GetUser", TMessageType.Reply, seqid));
                result.Write(oprot);
                oprot.WriteMessageEnd();
                oprot.Transport.Flush();
            }
Esempio n. 5
0
 public void send_GetUser(int userId)
 {
   oprot_.WriteMessageBegin(new TMessage("GetUser", TMessageType.Call, seqid_));
   GetUser_args args = new GetUser_args();
   args.UserId = userId;
   args.Write(oprot_);
   oprot_.WriteMessageEnd();
   oprot_.Transport.Flush();
 }
Esempio n. 6
0
 public void GetUser_Process(int seqid, TProtocol iprot, TProtocol oprot)
 {
   GetUser_args args = new GetUser_args();
   args.Read(iprot);
   iprot.ReadMessageEnd();
   GetUser_result result = new GetUser_result();
   try {
     result.Success = iface_.GetUser(args.UserId);
   } catch (IllegalityUserIdException ex) {
     result.Ex = ex;
   }
   oprot.WriteMessageBegin(new TMessage("GetUser", TMessageType.Reply, seqid)); 
   result.Write(oprot);
   oprot.WriteMessageEnd();
   oprot.Transport.Flush();
 }