コード例 #1
0
ファイル: TalkService.cs プロジェクト: Banandana/LineSharp
 public List<ContactReportResult> recv_reportContacts()
 {
   TMessage msg = iprot_.ReadMessageBegin();
   if (msg.Type == TMessageType.Exception) {
     TApplicationException x = TApplicationException.Read(iprot_);
     iprot_.ReadMessageEnd();
     throw x;
   }
   reportContacts_result result = new reportContacts_result();
   result.Read(iprot_);
   iprot_.ReadMessageEnd();
   if (result.__isset.success) {
     return result.Success;
   }
   if (result.__isset.e) {
     throw result.E;
   }
   throw new TApplicationException(TApplicationException.ExceptionType.MissingResult, "reportContacts failed: unknown result");
 }
コード例 #2
0
ファイル: TalkService.cs プロジェクト: Banandana/LineSharp
 public void reportContacts_Process(int seqid, TProtocol iprot, TProtocol oprot)
 {
   reportContacts_args args = new reportContacts_args();
   args.Read(iprot);
   iprot.ReadMessageEnd();
   reportContacts_result result = new reportContacts_result();
   try {
     result.Success = iface_.reportContacts(args.SyncOpRevision, args.Category, args.ContactReports, args.ActionType);
   } catch (TalkException e) {
     result.E = e;
   }
   oprot.WriteMessageBegin(new TMessage("reportContacts", TMessageType.Reply, seqid)); 
   result.Write(oprot);
   oprot.WriteMessageEnd();
   oprot.Transport.Flush();
 }