Esempio n. 1
0
 public void send_gearUpVer2(GearUp gearUp, Session session)
 #endif
 {
   oprot_.WriteMessageBegin(new TMessage("gearUpVer2", TMessageType.Call, seqid_));
   gearUpVer2_args args = new gearUpVer2_args();
   args.GearUp = gearUp;
   args.Session = session;
   args.Write(oprot_);
   oprot_.WriteMessageEnd();
   #if SILVERLIGHT
   return oprot_.Transport.BeginFlush(callback, state);
   #else
   oprot_.Transport.Flush();
   #endif
 }
Esempio n. 2
0
 public IAsyncResult send_gearUpVer2(AsyncCallback callback, object state, GearUp gearUp, Session session)
Esempio n. 3
0
      public string gearUpVer2(GearUp gearUp, Session session)
      {
        #if !SILVERLIGHT
        send_gearUpVer2(gearUp, session);
        return recv_gearUpVer2();

        #else
        var asyncResult = Begin_gearUpVer2(null, null, gearUp, session);
        return End_gearUpVer2(asyncResult);

        #endif
      }
Esempio n. 4
0
 public IAsyncResult Begin_gearUpVer2(AsyncCallback callback, object state, GearUp gearUp, Session session)
 {
   return send_gearUpVer2(callback, state, gearUp, session);
 }
Esempio n. 5
0
 public void Read (TProtocol iprot)
 {
   TField field;
   iprot.ReadStructBegin();
   while (true)
   {
     field = iprot.ReadFieldBegin();
     if (field.Type == TType.Stop) { 
       break;
     }
     switch (field.ID)
     {
       case 1:
         if (field.Type == TType.Struct) {
           GearUp = new GearUp();
           GearUp.Read(iprot);
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       case 2:
         if (field.Type == TType.Struct) {
           Session = new Session();
           Session.Read(iprot);
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       default: 
         TProtocolUtil.Skip(iprot, field.Type);
         break;
     }
     iprot.ReadFieldEnd();
   }
   iprot.ReadStructEnd();
 }
        public async Task<StatusData<object>> GearUp(ChatRequest.GearUpRequest request, SystemSession session)
        {
            var result = new StatusData<object> { Status = SystemDbStatus.Selected };

            var gearUpObject = new GearUp { UserId = session.UserName, Timestamp = request.TimeStamp, InstanceList = request.InstanceList };

            var response = await Task.Factory.StartNew(() => Client.ChatService.gearUpVer2(gearUpObject, session.GetSession())).ConfigureAwait(false);

            //Helper.Helper.ExtractData(result, response, "error", elementsToBypass: new Collection<string> { "error" });

            result.Data = JArray.Parse(response);
            return result;

            //  return re;
        }