예제 #1
0
 public void listSearches_Process(int seqid, TProtocol iprot, TProtocol oprot)
 {
   listSearches_args args = new listSearches_args();
   args.Read(iprot);
   iprot.ReadMessageEnd();
   listSearches_result result = new listSearches_result();
   try {
     result.Success = iface_.listSearches(args.AuthenticationToken);
   } catch (Evernote.EDAM.Error.EDAMUserException userException) {
     result.UserException = userException;
   } catch (Evernote.EDAM.Error.EDAMSystemException systemException) {
     result.SystemException = systemException;
   }
   oprot.WriteMessageBegin(new TMessage("listSearches", TMessageType.Reply, seqid)); 
   result.Write(oprot);
   oprot.WriteMessageEnd();
   oprot.Transport.Flush();
 }
예제 #2
0
 public List<Evernote.EDAM.Type.SavedSearch> recv_listSearches()
 {
   TMessage msg = iprot_.ReadMessageBegin();
   if (msg.Type == TMessageType.Exception) {
     TApplicationException x = TApplicationException.Read(iprot_);
     iprot_.ReadMessageEnd();
     throw x;
   }
   listSearches_result result = new listSearches_result();
   result.Read(iprot_);
   iprot_.ReadMessageEnd();
   if (result.__isset.success) {
     return result.Success;
   }
   if (result.__isset.userException) {
     throw result.UserException;
   }
   if (result.__isset.systemException) {
     throw result.SystemException;
   }
   throw new TApplicationException(TApplicationException.ExceptionType.MissingResult, "listSearches failed: unknown result");
 }