PageRenderTime 297ms CodeModel.GetById 17ms RepoModel.GetById 1ms app.codeStats 2ms

/src/main/java/com/evernote/edam/notestore/NoteStore.java

http://github.com/evernote/evernote-sdk-java
Java | 13456 lines | 11499 code | 1487 blank | 470 comment | 3059 complexity | fcb37622fb0c50662ba30817f74025f3 MD5 | raw file
Possible License(s): BSD-3-Clause-No-Nuclear-License-2014

Large files files are truncated, but you can click here to view the full file

  1. /**
  2. * Autogenerated by Thrift
  3. *
  4. * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
  5. */
  6. package com.evernote.edam.notestore;
  7. import java.util.List;
  8. import java.util.ArrayList;
  9. import java.util.Map;
  10. import java.util.HashMap;
  11. import java.util.Set;
  12. import java.util.HashSet;
  13. import com.evernote.thrift.*;
  14. import com.evernote.thrift.protocol.*;
  15. public class NoteStore {
  16. public interface Iface extends NoteStoreIface { }
  17. public static class Client implements TServiceClient, Iface {
  18. public Client(TProtocol prot)
  19. {
  20. this(prot, prot);
  21. }
  22. public Client(TProtocol iprot, TProtocol oprot)
  23. {
  24. iprot_ = iprot;
  25. oprot_ = oprot;
  26. }
  27. protected TProtocol iprot_;
  28. protected TProtocol oprot_;
  29. protected int seqid_;
  30. public TProtocol getInputProtocol()
  31. {
  32. return this.iprot_;
  33. }
  34. public TProtocol getOutputProtocol()
  35. {
  36. return this.oprot_;
  37. }
  38. public SyncState getSyncState(String authenticationToken) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, TException
  39. {
  40. send_getSyncState(authenticationToken);
  41. return recv_getSyncState();
  42. }
  43. public void send_getSyncState(String authenticationToken) throws TException
  44. {
  45. oprot_.writeMessageBegin(new TMessage("getSyncState", TMessageType.CALL, ++seqid_));
  46. getSyncState_args args = new getSyncState_args();
  47. args.setAuthenticationToken(authenticationToken);
  48. args.write(oprot_);
  49. oprot_.writeMessageEnd();
  50. oprot_.getTransport().flush();
  51. }
  52. public SyncState recv_getSyncState() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, TException
  53. {
  54. TMessage msg = iprot_.readMessageBegin();
  55. if (msg.type == TMessageType.EXCEPTION) {
  56. TApplicationException x = TApplicationException.read(iprot_);
  57. iprot_.readMessageEnd();
  58. throw x;
  59. }
  60. if (msg.seqid != seqid_) {
  61. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "getSyncState failed: out of sequence response");
  62. }
  63. getSyncState_result result = new getSyncState_result();
  64. result.read(iprot_);
  65. iprot_.readMessageEnd();
  66. if (result.isSetSuccess()) {
  67. return result.success;
  68. }
  69. if (result.userException != null) {
  70. throw result.userException;
  71. }
  72. if (result.systemException != null) {
  73. throw result.systemException;
  74. }
  75. throw new TApplicationException(TApplicationException.MISSING_RESULT, "getSyncState failed: unknown result");
  76. }
  77. public SyncState getSyncStateWithMetrics(String authenticationToken, ClientUsageMetrics clientMetrics) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, TException
  78. {
  79. send_getSyncStateWithMetrics(authenticationToken, clientMetrics);
  80. return recv_getSyncStateWithMetrics();
  81. }
  82. public void send_getSyncStateWithMetrics(String authenticationToken, ClientUsageMetrics clientMetrics) throws TException
  83. {
  84. oprot_.writeMessageBegin(new TMessage("getSyncStateWithMetrics", TMessageType.CALL, ++seqid_));
  85. getSyncStateWithMetrics_args args = new getSyncStateWithMetrics_args();
  86. args.setAuthenticationToken(authenticationToken);
  87. args.setClientMetrics(clientMetrics);
  88. args.write(oprot_);
  89. oprot_.writeMessageEnd();
  90. oprot_.getTransport().flush();
  91. }
  92. public SyncState recv_getSyncStateWithMetrics() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, TException
  93. {
  94. TMessage msg = iprot_.readMessageBegin();
  95. if (msg.type == TMessageType.EXCEPTION) {
  96. TApplicationException x = TApplicationException.read(iprot_);
  97. iprot_.readMessageEnd();
  98. throw x;
  99. }
  100. if (msg.seqid != seqid_) {
  101. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "getSyncStateWithMetrics failed: out of sequence response");
  102. }
  103. getSyncStateWithMetrics_result result = new getSyncStateWithMetrics_result();
  104. result.read(iprot_);
  105. iprot_.readMessageEnd();
  106. if (result.isSetSuccess()) {
  107. return result.success;
  108. }
  109. if (result.userException != null) {
  110. throw result.userException;
  111. }
  112. if (result.systemException != null) {
  113. throw result.systemException;
  114. }
  115. throw new TApplicationException(TApplicationException.MISSING_RESULT, "getSyncStateWithMetrics failed: unknown result");
  116. }
  117. public SyncChunk getSyncChunk(String authenticationToken, int afterUSN, int maxEntries, boolean fullSyncOnly) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, TException
  118. {
  119. send_getSyncChunk(authenticationToken, afterUSN, maxEntries, fullSyncOnly);
  120. return recv_getSyncChunk();
  121. }
  122. public void send_getSyncChunk(String authenticationToken, int afterUSN, int maxEntries, boolean fullSyncOnly) throws TException
  123. {
  124. oprot_.writeMessageBegin(new TMessage("getSyncChunk", TMessageType.CALL, ++seqid_));
  125. getSyncChunk_args args = new getSyncChunk_args();
  126. args.setAuthenticationToken(authenticationToken);
  127. args.setAfterUSN(afterUSN);
  128. args.setMaxEntries(maxEntries);
  129. args.setFullSyncOnly(fullSyncOnly);
  130. args.write(oprot_);
  131. oprot_.writeMessageEnd();
  132. oprot_.getTransport().flush();
  133. }
  134. public SyncChunk recv_getSyncChunk() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, TException
  135. {
  136. TMessage msg = iprot_.readMessageBegin();
  137. if (msg.type == TMessageType.EXCEPTION) {
  138. TApplicationException x = TApplicationException.read(iprot_);
  139. iprot_.readMessageEnd();
  140. throw x;
  141. }
  142. if (msg.seqid != seqid_) {
  143. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "getSyncChunk failed: out of sequence response");
  144. }
  145. getSyncChunk_result result = new getSyncChunk_result();
  146. result.read(iprot_);
  147. iprot_.readMessageEnd();
  148. if (result.isSetSuccess()) {
  149. return result.success;
  150. }
  151. if (result.userException != null) {
  152. throw result.userException;
  153. }
  154. if (result.systemException != null) {
  155. throw result.systemException;
  156. }
  157. throw new TApplicationException(TApplicationException.MISSING_RESULT, "getSyncChunk failed: unknown result");
  158. }
  159. public SyncChunk getFilteredSyncChunk(String authenticationToken, int afterUSN, int maxEntries, SyncChunkFilter filter) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, TException
  160. {
  161. send_getFilteredSyncChunk(authenticationToken, afterUSN, maxEntries, filter);
  162. return recv_getFilteredSyncChunk();
  163. }
  164. public void send_getFilteredSyncChunk(String authenticationToken, int afterUSN, int maxEntries, SyncChunkFilter filter) throws TException
  165. {
  166. oprot_.writeMessageBegin(new TMessage("getFilteredSyncChunk", TMessageType.CALL, ++seqid_));
  167. getFilteredSyncChunk_args args = new getFilteredSyncChunk_args();
  168. args.setAuthenticationToken(authenticationToken);
  169. args.setAfterUSN(afterUSN);
  170. args.setMaxEntries(maxEntries);
  171. args.setFilter(filter);
  172. args.write(oprot_);
  173. oprot_.writeMessageEnd();
  174. oprot_.getTransport().flush();
  175. }
  176. public SyncChunk recv_getFilteredSyncChunk() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, TException
  177. {
  178. TMessage msg = iprot_.readMessageBegin();
  179. if (msg.type == TMessageType.EXCEPTION) {
  180. TApplicationException x = TApplicationException.read(iprot_);
  181. iprot_.readMessageEnd();
  182. throw x;
  183. }
  184. if (msg.seqid != seqid_) {
  185. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "getFilteredSyncChunk failed: out of sequence response");
  186. }
  187. getFilteredSyncChunk_result result = new getFilteredSyncChunk_result();
  188. result.read(iprot_);
  189. iprot_.readMessageEnd();
  190. if (result.isSetSuccess()) {
  191. return result.success;
  192. }
  193. if (result.userException != null) {
  194. throw result.userException;
  195. }
  196. if (result.systemException != null) {
  197. throw result.systemException;
  198. }
  199. throw new TApplicationException(TApplicationException.MISSING_RESULT, "getFilteredSyncChunk failed: unknown result");
  200. }
  201. public SyncState getLinkedNotebookSyncState(String authenticationToken, com.evernote.edam.type.LinkedNotebook linkedNotebook) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  202. {
  203. send_getLinkedNotebookSyncState(authenticationToken, linkedNotebook);
  204. return recv_getLinkedNotebookSyncState();
  205. }
  206. public void send_getLinkedNotebookSyncState(String authenticationToken, com.evernote.edam.type.LinkedNotebook linkedNotebook) throws TException
  207. {
  208. oprot_.writeMessageBegin(new TMessage("getLinkedNotebookSyncState", TMessageType.CALL, ++seqid_));
  209. getLinkedNotebookSyncState_args args = new getLinkedNotebookSyncState_args();
  210. args.setAuthenticationToken(authenticationToken);
  211. args.setLinkedNotebook(linkedNotebook);
  212. args.write(oprot_);
  213. oprot_.writeMessageEnd();
  214. oprot_.getTransport().flush();
  215. }
  216. public SyncState recv_getLinkedNotebookSyncState() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  217. {
  218. TMessage msg = iprot_.readMessageBegin();
  219. if (msg.type == TMessageType.EXCEPTION) {
  220. TApplicationException x = TApplicationException.read(iprot_);
  221. iprot_.readMessageEnd();
  222. throw x;
  223. }
  224. if (msg.seqid != seqid_) {
  225. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "getLinkedNotebookSyncState failed: out of sequence response");
  226. }
  227. getLinkedNotebookSyncState_result result = new getLinkedNotebookSyncState_result();
  228. result.read(iprot_);
  229. iprot_.readMessageEnd();
  230. if (result.isSetSuccess()) {
  231. return result.success;
  232. }
  233. if (result.userException != null) {
  234. throw result.userException;
  235. }
  236. if (result.systemException != null) {
  237. throw result.systemException;
  238. }
  239. if (result.notFoundException != null) {
  240. throw result.notFoundException;
  241. }
  242. throw new TApplicationException(TApplicationException.MISSING_RESULT, "getLinkedNotebookSyncState failed: unknown result");
  243. }
  244. public SyncChunk getLinkedNotebookSyncChunk(String authenticationToken, com.evernote.edam.type.LinkedNotebook linkedNotebook, int afterUSN, int maxEntries, boolean fullSyncOnly) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  245. {
  246. send_getLinkedNotebookSyncChunk(authenticationToken, linkedNotebook, afterUSN, maxEntries, fullSyncOnly);
  247. return recv_getLinkedNotebookSyncChunk();
  248. }
  249. public void send_getLinkedNotebookSyncChunk(String authenticationToken, com.evernote.edam.type.LinkedNotebook linkedNotebook, int afterUSN, int maxEntries, boolean fullSyncOnly) throws TException
  250. {
  251. oprot_.writeMessageBegin(new TMessage("getLinkedNotebookSyncChunk", TMessageType.CALL, ++seqid_));
  252. getLinkedNotebookSyncChunk_args args = new getLinkedNotebookSyncChunk_args();
  253. args.setAuthenticationToken(authenticationToken);
  254. args.setLinkedNotebook(linkedNotebook);
  255. args.setAfterUSN(afterUSN);
  256. args.setMaxEntries(maxEntries);
  257. args.setFullSyncOnly(fullSyncOnly);
  258. args.write(oprot_);
  259. oprot_.writeMessageEnd();
  260. oprot_.getTransport().flush();
  261. }
  262. public SyncChunk recv_getLinkedNotebookSyncChunk() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  263. {
  264. TMessage msg = iprot_.readMessageBegin();
  265. if (msg.type == TMessageType.EXCEPTION) {
  266. TApplicationException x = TApplicationException.read(iprot_);
  267. iprot_.readMessageEnd();
  268. throw x;
  269. }
  270. if (msg.seqid != seqid_) {
  271. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "getLinkedNotebookSyncChunk failed: out of sequence response");
  272. }
  273. getLinkedNotebookSyncChunk_result result = new getLinkedNotebookSyncChunk_result();
  274. result.read(iprot_);
  275. iprot_.readMessageEnd();
  276. if (result.isSetSuccess()) {
  277. return result.success;
  278. }
  279. if (result.userException != null) {
  280. throw result.userException;
  281. }
  282. if (result.systemException != null) {
  283. throw result.systemException;
  284. }
  285. if (result.notFoundException != null) {
  286. throw result.notFoundException;
  287. }
  288. throw new TApplicationException(TApplicationException.MISSING_RESULT, "getLinkedNotebookSyncChunk failed: unknown result");
  289. }
  290. public List<com.evernote.edam.type.Notebook> listNotebooks(String authenticationToken) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, TException
  291. {
  292. send_listNotebooks(authenticationToken);
  293. return recv_listNotebooks();
  294. }
  295. public void send_listNotebooks(String authenticationToken) throws TException
  296. {
  297. oprot_.writeMessageBegin(new TMessage("listNotebooks", TMessageType.CALL, ++seqid_));
  298. listNotebooks_args args = new listNotebooks_args();
  299. args.setAuthenticationToken(authenticationToken);
  300. args.write(oprot_);
  301. oprot_.writeMessageEnd();
  302. oprot_.getTransport().flush();
  303. }
  304. public List<com.evernote.edam.type.Notebook> recv_listNotebooks() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, TException
  305. {
  306. TMessage msg = iprot_.readMessageBegin();
  307. if (msg.type == TMessageType.EXCEPTION) {
  308. TApplicationException x = TApplicationException.read(iprot_);
  309. iprot_.readMessageEnd();
  310. throw x;
  311. }
  312. if (msg.seqid != seqid_) {
  313. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "listNotebooks failed: out of sequence response");
  314. }
  315. listNotebooks_result result = new listNotebooks_result();
  316. result.read(iprot_);
  317. iprot_.readMessageEnd();
  318. if (result.isSetSuccess()) {
  319. return result.success;
  320. }
  321. if (result.userException != null) {
  322. throw result.userException;
  323. }
  324. if (result.systemException != null) {
  325. throw result.systemException;
  326. }
  327. throw new TApplicationException(TApplicationException.MISSING_RESULT, "listNotebooks failed: unknown result");
  328. }
  329. public com.evernote.edam.type.Notebook getNotebook(String authenticationToken, String guid) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  330. {
  331. send_getNotebook(authenticationToken, guid);
  332. return recv_getNotebook();
  333. }
  334. public void send_getNotebook(String authenticationToken, String guid) throws TException
  335. {
  336. oprot_.writeMessageBegin(new TMessage("getNotebook", TMessageType.CALL, ++seqid_));
  337. getNotebook_args args = new getNotebook_args();
  338. args.setAuthenticationToken(authenticationToken);
  339. args.setGuid(guid);
  340. args.write(oprot_);
  341. oprot_.writeMessageEnd();
  342. oprot_.getTransport().flush();
  343. }
  344. public com.evernote.edam.type.Notebook recv_getNotebook() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  345. {
  346. TMessage msg = iprot_.readMessageBegin();
  347. if (msg.type == TMessageType.EXCEPTION) {
  348. TApplicationException x = TApplicationException.read(iprot_);
  349. iprot_.readMessageEnd();
  350. throw x;
  351. }
  352. if (msg.seqid != seqid_) {
  353. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "getNotebook failed: out of sequence response");
  354. }
  355. getNotebook_result result = new getNotebook_result();
  356. result.read(iprot_);
  357. iprot_.readMessageEnd();
  358. if (result.isSetSuccess()) {
  359. return result.success;
  360. }
  361. if (result.userException != null) {
  362. throw result.userException;
  363. }
  364. if (result.systemException != null) {
  365. throw result.systemException;
  366. }
  367. if (result.notFoundException != null) {
  368. throw result.notFoundException;
  369. }
  370. throw new TApplicationException(TApplicationException.MISSING_RESULT, "getNotebook failed: unknown result");
  371. }
  372. public com.evernote.edam.type.Notebook getDefaultNotebook(String authenticationToken) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, TException
  373. {
  374. send_getDefaultNotebook(authenticationToken);
  375. return recv_getDefaultNotebook();
  376. }
  377. public void send_getDefaultNotebook(String authenticationToken) throws TException
  378. {
  379. oprot_.writeMessageBegin(new TMessage("getDefaultNotebook", TMessageType.CALL, ++seqid_));
  380. getDefaultNotebook_args args = new getDefaultNotebook_args();
  381. args.setAuthenticationToken(authenticationToken);
  382. args.write(oprot_);
  383. oprot_.writeMessageEnd();
  384. oprot_.getTransport().flush();
  385. }
  386. public com.evernote.edam.type.Notebook recv_getDefaultNotebook() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, TException
  387. {
  388. TMessage msg = iprot_.readMessageBegin();
  389. if (msg.type == TMessageType.EXCEPTION) {
  390. TApplicationException x = TApplicationException.read(iprot_);
  391. iprot_.readMessageEnd();
  392. throw x;
  393. }
  394. if (msg.seqid != seqid_) {
  395. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "getDefaultNotebook failed: out of sequence response");
  396. }
  397. getDefaultNotebook_result result = new getDefaultNotebook_result();
  398. result.read(iprot_);
  399. iprot_.readMessageEnd();
  400. if (result.isSetSuccess()) {
  401. return result.success;
  402. }
  403. if (result.userException != null) {
  404. throw result.userException;
  405. }
  406. if (result.systemException != null) {
  407. throw result.systemException;
  408. }
  409. throw new TApplicationException(TApplicationException.MISSING_RESULT, "getDefaultNotebook failed: unknown result");
  410. }
  411. public com.evernote.edam.type.Notebook createNotebook(String authenticationToken, com.evernote.edam.type.Notebook notebook) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, TException
  412. {
  413. send_createNotebook(authenticationToken, notebook);
  414. return recv_createNotebook();
  415. }
  416. public void send_createNotebook(String authenticationToken, com.evernote.edam.type.Notebook notebook) throws TException
  417. {
  418. oprot_.writeMessageBegin(new TMessage("createNotebook", TMessageType.CALL, ++seqid_));
  419. createNotebook_args args = new createNotebook_args();
  420. args.setAuthenticationToken(authenticationToken);
  421. args.setNotebook(notebook);
  422. args.write(oprot_);
  423. oprot_.writeMessageEnd();
  424. oprot_.getTransport().flush();
  425. }
  426. public com.evernote.edam.type.Notebook recv_createNotebook() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, TException
  427. {
  428. TMessage msg = iprot_.readMessageBegin();
  429. if (msg.type == TMessageType.EXCEPTION) {
  430. TApplicationException x = TApplicationException.read(iprot_);
  431. iprot_.readMessageEnd();
  432. throw x;
  433. }
  434. if (msg.seqid != seqid_) {
  435. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "createNotebook failed: out of sequence response");
  436. }
  437. createNotebook_result result = new createNotebook_result();
  438. result.read(iprot_);
  439. iprot_.readMessageEnd();
  440. if (result.isSetSuccess()) {
  441. return result.success;
  442. }
  443. if (result.userException != null) {
  444. throw result.userException;
  445. }
  446. if (result.systemException != null) {
  447. throw result.systemException;
  448. }
  449. throw new TApplicationException(TApplicationException.MISSING_RESULT, "createNotebook failed: unknown result");
  450. }
  451. public int updateNotebook(String authenticationToken, com.evernote.edam.type.Notebook notebook) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  452. {
  453. send_updateNotebook(authenticationToken, notebook);
  454. return recv_updateNotebook();
  455. }
  456. public void send_updateNotebook(String authenticationToken, com.evernote.edam.type.Notebook notebook) throws TException
  457. {
  458. oprot_.writeMessageBegin(new TMessage("updateNotebook", TMessageType.CALL, ++seqid_));
  459. updateNotebook_args args = new updateNotebook_args();
  460. args.setAuthenticationToken(authenticationToken);
  461. args.setNotebook(notebook);
  462. args.write(oprot_);
  463. oprot_.writeMessageEnd();
  464. oprot_.getTransport().flush();
  465. }
  466. public int recv_updateNotebook() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  467. {
  468. TMessage msg = iprot_.readMessageBegin();
  469. if (msg.type == TMessageType.EXCEPTION) {
  470. TApplicationException x = TApplicationException.read(iprot_);
  471. iprot_.readMessageEnd();
  472. throw x;
  473. }
  474. if (msg.seqid != seqid_) {
  475. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "updateNotebook failed: out of sequence response");
  476. }
  477. updateNotebook_result result = new updateNotebook_result();
  478. result.read(iprot_);
  479. iprot_.readMessageEnd();
  480. if (result.isSetSuccess()) {
  481. return result.success;
  482. }
  483. if (result.userException != null) {
  484. throw result.userException;
  485. }
  486. if (result.systemException != null) {
  487. throw result.systemException;
  488. }
  489. if (result.notFoundException != null) {
  490. throw result.notFoundException;
  491. }
  492. throw new TApplicationException(TApplicationException.MISSING_RESULT, "updateNotebook failed: unknown result");
  493. }
  494. public int expungeNotebook(String authenticationToken, String guid) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  495. {
  496. send_expungeNotebook(authenticationToken, guid);
  497. return recv_expungeNotebook();
  498. }
  499. public void send_expungeNotebook(String authenticationToken, String guid) throws TException
  500. {
  501. oprot_.writeMessageBegin(new TMessage("expungeNotebook", TMessageType.CALL, ++seqid_));
  502. expungeNotebook_args args = new expungeNotebook_args();
  503. args.setAuthenticationToken(authenticationToken);
  504. args.setGuid(guid);
  505. args.write(oprot_);
  506. oprot_.writeMessageEnd();
  507. oprot_.getTransport().flush();
  508. }
  509. public int recv_expungeNotebook() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  510. {
  511. TMessage msg = iprot_.readMessageBegin();
  512. if (msg.type == TMessageType.EXCEPTION) {
  513. TApplicationException x = TApplicationException.read(iprot_);
  514. iprot_.readMessageEnd();
  515. throw x;
  516. }
  517. if (msg.seqid != seqid_) {
  518. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "expungeNotebook failed: out of sequence response");
  519. }
  520. expungeNotebook_result result = new expungeNotebook_result();
  521. result.read(iprot_);
  522. iprot_.readMessageEnd();
  523. if (result.isSetSuccess()) {
  524. return result.success;
  525. }
  526. if (result.userException != null) {
  527. throw result.userException;
  528. }
  529. if (result.systemException != null) {
  530. throw result.systemException;
  531. }
  532. if (result.notFoundException != null) {
  533. throw result.notFoundException;
  534. }
  535. throw new TApplicationException(TApplicationException.MISSING_RESULT, "expungeNotebook failed: unknown result");
  536. }
  537. public List<com.evernote.edam.type.Tag> listTags(String authenticationToken) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, TException
  538. {
  539. send_listTags(authenticationToken);
  540. return recv_listTags();
  541. }
  542. public void send_listTags(String authenticationToken) throws TException
  543. {
  544. oprot_.writeMessageBegin(new TMessage("listTags", TMessageType.CALL, ++seqid_));
  545. listTags_args args = new listTags_args();
  546. args.setAuthenticationToken(authenticationToken);
  547. args.write(oprot_);
  548. oprot_.writeMessageEnd();
  549. oprot_.getTransport().flush();
  550. }
  551. public List<com.evernote.edam.type.Tag> recv_listTags() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, TException
  552. {
  553. TMessage msg = iprot_.readMessageBegin();
  554. if (msg.type == TMessageType.EXCEPTION) {
  555. TApplicationException x = TApplicationException.read(iprot_);
  556. iprot_.readMessageEnd();
  557. throw x;
  558. }
  559. if (msg.seqid != seqid_) {
  560. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "listTags failed: out of sequence response");
  561. }
  562. listTags_result result = new listTags_result();
  563. result.read(iprot_);
  564. iprot_.readMessageEnd();
  565. if (result.isSetSuccess()) {
  566. return result.success;
  567. }
  568. if (result.userException != null) {
  569. throw result.userException;
  570. }
  571. if (result.systemException != null) {
  572. throw result.systemException;
  573. }
  574. throw new TApplicationException(TApplicationException.MISSING_RESULT, "listTags failed: unknown result");
  575. }
  576. public List<com.evernote.edam.type.Tag> listTagsByNotebook(String authenticationToken, String notebookGuid) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  577. {
  578. send_listTagsByNotebook(authenticationToken, notebookGuid);
  579. return recv_listTagsByNotebook();
  580. }
  581. public void send_listTagsByNotebook(String authenticationToken, String notebookGuid) throws TException
  582. {
  583. oprot_.writeMessageBegin(new TMessage("listTagsByNotebook", TMessageType.CALL, ++seqid_));
  584. listTagsByNotebook_args args = new listTagsByNotebook_args();
  585. args.setAuthenticationToken(authenticationToken);
  586. args.setNotebookGuid(notebookGuid);
  587. args.write(oprot_);
  588. oprot_.writeMessageEnd();
  589. oprot_.getTransport().flush();
  590. }
  591. public List<com.evernote.edam.type.Tag> recv_listTagsByNotebook() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  592. {
  593. TMessage msg = iprot_.readMessageBegin();
  594. if (msg.type == TMessageType.EXCEPTION) {
  595. TApplicationException x = TApplicationException.read(iprot_);
  596. iprot_.readMessageEnd();
  597. throw x;
  598. }
  599. if (msg.seqid != seqid_) {
  600. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "listTagsByNotebook failed: out of sequence response");
  601. }
  602. listTagsByNotebook_result result = new listTagsByNotebook_result();
  603. result.read(iprot_);
  604. iprot_.readMessageEnd();
  605. if (result.isSetSuccess()) {
  606. return result.success;
  607. }
  608. if (result.userException != null) {
  609. throw result.userException;
  610. }
  611. if (result.systemException != null) {
  612. throw result.systemException;
  613. }
  614. if (result.notFoundException != null) {
  615. throw result.notFoundException;
  616. }
  617. throw new TApplicationException(TApplicationException.MISSING_RESULT, "listTagsByNotebook failed: unknown result");
  618. }
  619. public com.evernote.edam.type.Tag getTag(String authenticationToken, String guid) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  620. {
  621. send_getTag(authenticationToken, guid);
  622. return recv_getTag();
  623. }
  624. public void send_getTag(String authenticationToken, String guid) throws TException
  625. {
  626. oprot_.writeMessageBegin(new TMessage("getTag", TMessageType.CALL, ++seqid_));
  627. getTag_args args = new getTag_args();
  628. args.setAuthenticationToken(authenticationToken);
  629. args.setGuid(guid);
  630. args.write(oprot_);
  631. oprot_.writeMessageEnd();
  632. oprot_.getTransport().flush();
  633. }
  634. public com.evernote.edam.type.Tag recv_getTag() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  635. {
  636. TMessage msg = iprot_.readMessageBegin();
  637. if (msg.type == TMessageType.EXCEPTION) {
  638. TApplicationException x = TApplicationException.read(iprot_);
  639. iprot_.readMessageEnd();
  640. throw x;
  641. }
  642. if (msg.seqid != seqid_) {
  643. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "getTag failed: out of sequence response");
  644. }
  645. getTag_result result = new getTag_result();
  646. result.read(iprot_);
  647. iprot_.readMessageEnd();
  648. if (result.isSetSuccess()) {
  649. return result.success;
  650. }
  651. if (result.userException != null) {
  652. throw result.userException;
  653. }
  654. if (result.systemException != null) {
  655. throw result.systemException;
  656. }
  657. if (result.notFoundException != null) {
  658. throw result.notFoundException;
  659. }
  660. throw new TApplicationException(TApplicationException.MISSING_RESULT, "getTag failed: unknown result");
  661. }
  662. public com.evernote.edam.type.Tag createTag(String authenticationToken, com.evernote.edam.type.Tag tag) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  663. {
  664. send_createTag(authenticationToken, tag);
  665. return recv_createTag();
  666. }
  667. public void send_createTag(String authenticationToken, com.evernote.edam.type.Tag tag) throws TException
  668. {
  669. oprot_.writeMessageBegin(new TMessage("createTag", TMessageType.CALL, ++seqid_));
  670. createTag_args args = new createTag_args();
  671. args.setAuthenticationToken(authenticationToken);
  672. args.setTag(tag);
  673. args.write(oprot_);
  674. oprot_.writeMessageEnd();
  675. oprot_.getTransport().flush();
  676. }
  677. public com.evernote.edam.type.Tag recv_createTag() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  678. {
  679. TMessage msg = iprot_.readMessageBegin();
  680. if (msg.type == TMessageType.EXCEPTION) {
  681. TApplicationException x = TApplicationException.read(iprot_);
  682. iprot_.readMessageEnd();
  683. throw x;
  684. }
  685. if (msg.seqid != seqid_) {
  686. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "createTag failed: out of sequence response");
  687. }
  688. createTag_result result = new createTag_result();
  689. result.read(iprot_);
  690. iprot_.readMessageEnd();
  691. if (result.isSetSuccess()) {
  692. return result.success;
  693. }
  694. if (result.userException != null) {
  695. throw result.userException;
  696. }
  697. if (result.systemException != null) {
  698. throw result.systemException;
  699. }
  700. if (result.notFoundException != null) {
  701. throw result.notFoundException;
  702. }
  703. throw new TApplicationException(TApplicationException.MISSING_RESULT, "createTag failed: unknown result");
  704. }
  705. public int updateTag(String authenticationToken, com.evernote.edam.type.Tag tag) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  706. {
  707. send_updateTag(authenticationToken, tag);
  708. return recv_updateTag();
  709. }
  710. public void send_updateTag(String authenticationToken, com.evernote.edam.type.Tag tag) throws TException
  711. {
  712. oprot_.writeMessageBegin(new TMessage("updateTag", TMessageType.CALL, ++seqid_));
  713. updateTag_args args = new updateTag_args();
  714. args.setAuthenticationToken(authenticationToken);
  715. args.setTag(tag);
  716. args.write(oprot_);
  717. oprot_.writeMessageEnd();
  718. oprot_.getTransport().flush();
  719. }
  720. public int recv_updateTag() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  721. {
  722. TMessage msg = iprot_.readMessageBegin();
  723. if (msg.type == TMessageType.EXCEPTION) {
  724. TApplicationException x = TApplicationException.read(iprot_);
  725. iprot_.readMessageEnd();
  726. throw x;
  727. }
  728. if (msg.seqid != seqid_) {
  729. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "updateTag failed: out of sequence response");
  730. }
  731. updateTag_result result = new updateTag_result();
  732. result.read(iprot_);
  733. iprot_.readMessageEnd();
  734. if (result.isSetSuccess()) {
  735. return result.success;
  736. }
  737. if (result.userException != null) {
  738. throw result.userException;
  739. }
  740. if (result.systemException != null) {
  741. throw result.systemException;
  742. }
  743. if (result.notFoundException != null) {
  744. throw result.notFoundException;
  745. }
  746. throw new TApplicationException(TApplicationException.MISSING_RESULT, "updateTag failed: unknown result");
  747. }
  748. public void untagAll(String authenticationToken, String guid) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  749. {
  750. send_untagAll(authenticationToken, guid);
  751. recv_untagAll();
  752. }
  753. public void send_untagAll(String authenticationToken, String guid) throws TException
  754. {
  755. oprot_.writeMessageBegin(new TMessage("untagAll", TMessageType.CALL, ++seqid_));
  756. untagAll_args args = new untagAll_args();
  757. args.setAuthenticationToken(authenticationToken);
  758. args.setGuid(guid);
  759. args.write(oprot_);
  760. oprot_.writeMessageEnd();
  761. oprot_.getTransport().flush();
  762. }
  763. public void recv_untagAll() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  764. {
  765. TMessage msg = iprot_.readMessageBegin();
  766. if (msg.type == TMessageType.EXCEPTION) {
  767. TApplicationException x = TApplicationException.read(iprot_);
  768. iprot_.readMessageEnd();
  769. throw x;
  770. }
  771. if (msg.seqid != seqid_) {
  772. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "untagAll failed: out of sequence response");
  773. }
  774. untagAll_result result = new untagAll_result();
  775. result.read(iprot_);
  776. iprot_.readMessageEnd();
  777. if (result.userException != null) {
  778. throw result.userException;
  779. }
  780. if (result.systemException != null) {
  781. throw result.systemException;
  782. }
  783. if (result.notFoundException != null) {
  784. throw result.notFoundException;
  785. }
  786. return;
  787. }
  788. public int expungeTag(String authenticationToken, String guid) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  789. {
  790. send_expungeTag(authenticationToken, guid);
  791. return recv_expungeTag();
  792. }
  793. public void send_expungeTag(String authenticationToken, String guid) throws TException
  794. {
  795. oprot_.writeMessageBegin(new TMessage("expungeTag", TMessageType.CALL, ++seqid_));
  796. expungeTag_args args = new expungeTag_args();
  797. args.setAuthenticationToken(authenticationToken);
  798. args.setGuid(guid);
  799. args.write(oprot_);
  800. oprot_.writeMessageEnd();
  801. oprot_.getTransport().flush();
  802. }
  803. public int recv_expungeTag() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  804. {
  805. TMessage msg = iprot_.readMessageBegin();
  806. if (msg.type == TMessageType.EXCEPTION) {
  807. TApplicationException x = TApplicationException.read(iprot_);
  808. iprot_.readMessageEnd();
  809. throw x;
  810. }
  811. if (msg.seqid != seqid_) {
  812. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "expungeTag failed: out of sequence response");
  813. }
  814. expungeTag_result result = new expungeTag_result();
  815. result.read(iprot_);
  816. iprot_.readMessageEnd();
  817. if (result.isSetSuccess()) {
  818. return result.success;
  819. }
  820. if (result.userException != null) {
  821. throw result.userException;
  822. }
  823. if (result.systemException != null) {
  824. throw result.systemException;
  825. }
  826. if (result.notFoundException != null) {
  827. throw result.notFoundException;
  828. }
  829. throw new TApplicationException(TApplicationException.MISSING_RESULT, "expungeTag failed: unknown result");
  830. }
  831. public List<com.evernote.edam.type.SavedSearch> listSearches(String authenticationToken) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, TException
  832. {
  833. send_listSearches(authenticationToken);
  834. return recv_listSearches();
  835. }
  836. public void send_listSearches(String authenticationToken) throws TException
  837. {
  838. oprot_.writeMessageBegin(new TMessage("listSearches", TMessageType.CALL, ++seqid_));
  839. listSearches_args args = new listSearches_args();
  840. args.setAuthenticationToken(authenticationToken);
  841. args.write(oprot_);
  842. oprot_.writeMessageEnd();
  843. oprot_.getTransport().flush();
  844. }
  845. public List<com.evernote.edam.type.SavedSearch> recv_listSearches() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, TException
  846. {
  847. TMessage msg = iprot_.readMessageBegin();
  848. if (msg.type == TMessageType.EXCEPTION) {
  849. TApplicationException x = TApplicationException.read(iprot_);
  850. iprot_.readMessageEnd();
  851. throw x;
  852. }
  853. if (msg.seqid != seqid_) {
  854. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "listSearches failed: out of sequence response");
  855. }
  856. listSearches_result result = new listSearches_result();
  857. result.read(iprot_);
  858. iprot_.readMessageEnd();
  859. if (result.isSetSuccess()) {
  860. return result.success;
  861. }
  862. if (result.userException != null) {
  863. throw result.userException;
  864. }
  865. if (result.systemException != null) {
  866. throw result.systemException;
  867. }
  868. throw new TApplicationException(TApplicationException.MISSING_RESULT, "listSearches failed: unknown result");
  869. }
  870. public com.evernote.edam.type.SavedSearch getSearch(String authenticationToken, String guid) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  871. {
  872. send_getSearch(authenticationToken, guid);
  873. return recv_getSearch();
  874. }
  875. public void send_getSearch(String authenticationToken, String guid) throws TException
  876. {
  877. oprot_.writeMessageBegin(new TMessage("getSearch", TMessageType.CALL, ++seqid_));
  878. getSearch_args args = new getSearch_args();
  879. args.setAuthenticationToken(authenticationToken);
  880. args.setGuid(guid);
  881. args.write(oprot_);
  882. oprot_.writeMessageEnd();
  883. oprot_.getTransport().flush();
  884. }
  885. public com.evernote.edam.type.SavedSearch recv_getSearch() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  886. {
  887. TMessage msg = iprot_.readMessageBegin();
  888. if (msg.type == TMessageType.EXCEPTION) {
  889. TApplicationException x = TApplicationException.read(iprot_);
  890. iprot_.readMessageEnd();
  891. throw x;
  892. }
  893. if (msg.seqid != seqid_) {
  894. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "getSearch failed: out of sequence response");
  895. }
  896. getSearch_result result = new getSearch_result();
  897. result.read(iprot_);
  898. iprot_.readMessageEnd();
  899. if (result.isSetSuccess()) {
  900. return result.success;
  901. }
  902. if (result.userException != null) {
  903. throw result.userException;
  904. }
  905. if (result.systemException != null) {
  906. throw result.systemException;
  907. }
  908. if (result.notFoundException != null) {
  909. throw result.notFoundException;
  910. }
  911. throw new TApplicationException(TApplicationException.MISSING_RESULT, "getSearch failed: unknown result");
  912. }
  913. public com.evernote.edam.type.SavedSearch createSearch(String authenticationToken, com.evernote.edam.type.SavedSearch search) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, TException
  914. {
  915. send_createSearch(authenticationToken, search);
  916. return recv_createSearch();
  917. }
  918. public void send_createSearch(String authenticationToken, com.evernote.edam.type.SavedSearch search) throws TException
  919. {
  920. oprot_.writeMessageBegin(new TMessage("createSearch", TMessageType.CALL, ++seqid_));
  921. createSearch_args args = new createSearch_args();
  922. args.setAuthenticationToken(authenticationToken);
  923. args.setSearch(search);
  924. args.write(oprot_);
  925. oprot_.writeMessageEnd();
  926. oprot_.getTransport().flush();
  927. }
  928. public com.evernote.edam.type.SavedSearch recv_createSearch() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, TException
  929. {
  930. TMessage msg = iprot_.readMessageBegin();
  931. if (msg.type == TMessageType.EXCEPTION) {
  932. TApplicationException x = TApplicationException.read(iprot_);
  933. iprot_.readMessageEnd();
  934. throw x;
  935. }
  936. if (msg.seqid != seqid_) {
  937. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "createSearch failed: out of sequence response");
  938. }
  939. createSearch_result result = new createSearch_result();
  940. result.read(iprot_);
  941. iprot_.readMessageEnd();
  942. if (result.isSetSuccess()) {
  943. return result.success;
  944. }
  945. if (result.userException != null) {
  946. throw result.userException;
  947. }
  948. if (result.systemException != null) {
  949. throw result.systemException;
  950. }
  951. throw new TApplicationException(TApplicationException.MISSING_RESULT, "createSearch failed: unknown result");
  952. }
  953. public int updateSearch(String authenticationToken, com.evernote.edam.type.SavedSearch search) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  954. {
  955. send_updateSearch(authenticationToken, search);
  956. return recv_updateSearch();
  957. }
  958. public void send_updateSearch(String authenticationToken, com.evernote.edam.type.SavedSearch search) throws TException
  959. {
  960. oprot_.writeMessageBegin(new TMessage("updateSearch", TMessageType.CALL, ++seqid_));
  961. updateSearch_args args = new updateSearch_args();
  962. args.setAuthenticationToken(authenticationToken);
  963. args.setSearch(search);
  964. args.write(oprot_);
  965. oprot_.writeMessageEnd();
  966. oprot_.getTransport().flush();
  967. }
  968. public int recv_updateSearch() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  969. {
  970. TMessage msg = iprot_.readMessageBegin();
  971. if (msg.type == TMessageType.EXCEPTION) {
  972. TApplicationException x = TApplicationException.read(iprot_);
  973. iprot_.readMessageEnd();
  974. throw x;
  975. }
  976. if (msg.seqid != seqid_) {
  977. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "updateSearch failed: out of sequence response");
  978. }
  979. updateSearch_result result = new updateSearch_result();
  980. result.read(iprot_);
  981. iprot_.readMessageEnd();
  982. if (result.isSetSuccess()) {
  983. return result.success;
  984. }
  985. if (result.userException != null) {
  986. throw result.userException;
  987. }
  988. if (result.systemException != null) {
  989. throw result.systemException;
  990. }
  991. if (result.notFoundException != null) {
  992. throw result.notFoundException;
  993. }
  994. throw new TApplicationException(TApplicationException.MISSING_RESULT, "updateSearch failed: unknown result");
  995. }
  996. public int expungeSearch(String authenticationToken, String guid) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  997. {
  998. send_expungeSearch(authenticationToken, guid);
  999. return recv_expungeSearch();
  1000. }
  1001. public void send_expungeSearch(String authenticationToken, String guid) throws TException
  1002. {
  1003. oprot_.writeMessageBegin(new TMessage("expungeSearch", TMessageType.CALL, ++seqid_));
  1004. expungeSearch_args args = new expungeSearch_args();
  1005. args.setAuthenticationToken(authenticationToken);
  1006. args.setGuid(guid);
  1007. args.write(oprot_);
  1008. oprot_.writeMessageEnd();
  1009. oprot_.getTransport().flush();
  1010. }
  1011. public int recv_expungeSearch() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  1012. {
  1013. TMessage msg = iprot_.readMessageBegin();
  1014. if (msg.type == TMessageType.EXCEPTION) {
  1015. TApplicationException x = TApplicationException.read(iprot_);
  1016. iprot_.readMessageEnd();
  1017. throw x;
  1018. }
  1019. if (msg.seqid != seqid_) {
  1020. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "expungeSearch failed: out of sequence response");
  1021. }
  1022. expungeSearch_result result = new expungeSearch_result();
  1023. result.read(iprot_);
  1024. iprot_.readMessageEnd();
  1025. if (result.isSetSuccess()) {
  1026. return result.success;
  1027. }
  1028. if (result.userException != null) {
  1029. throw result.userException;
  1030. }
  1031. if (result.systemException != null) {
  1032. throw result.systemException;
  1033. }
  1034. if (result.notFoundException != null) {
  1035. throw result.notFoundException;
  1036. }
  1037. throw new TApplicationException(TApplicationException.MISSING_RESULT, "expungeSearch failed: unknown result");
  1038. }
  1039. public NoteList findNotes(String authenticationToken, NoteFilter filter, int offset, int maxNotes) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  1040. {
  1041. send_findNotes(authenticationToken, filter, offset, maxNotes);
  1042. return recv_findNotes();
  1043. }
  1044. public void send_findNotes(String authenticationToken, NoteFilter filter, int offset, int maxNotes) throws TException
  1045. {
  1046. oprot_.writeMessageBegin(new TMessage("findNotes", TMessageType.CALL, ++seqid_));
  1047. findNotes_args args = new findNotes_args();
  1048. args.setAuthenticationToken(authenticationToken);
  1049. args.setFilter(filter);
  1050. args.setOffset(offset);
  1051. args.setMaxNotes(maxNotes);
  1052. args.write(oprot_);
  1053. oprot_.writeMessageEnd();
  1054. oprot_.getTransport().flush();
  1055. }
  1056. public NoteList recv_findNotes() throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  1057. {
  1058. TMessage msg = iprot_.readMessageBegin();
  1059. if (msg.type == TMessageType.EXCEPTION) {
  1060. TApplicationException x = TApplicationException.read(iprot_);
  1061. iprot_.readMessageEnd();
  1062. throw x;
  1063. }
  1064. if (msg.seqid != seqid_) {
  1065. throw new TApplicationException(TApplicationException.BAD_SEQUENCE_ID, "findNotes failed: out of sequence response");
  1066. }
  1067. findNotes_result result = new findNotes_result();
  1068. result.read(iprot_);
  1069. iprot_.readMessageEnd();
  1070. if (result.isSetSuccess()) {
  1071. return result.success;
  1072. }
  1073. if (result.userException != null) {
  1074. throw result.userException;
  1075. }
  1076. if (result.systemException != null) {
  1077. throw result.systemException;
  1078. }
  1079. if (result.notFoundException != null) {
  1080. throw result.notFoundException;
  1081. }
  1082. throw new TApplicationException(TApplicationException.MISSING_RESULT, "findNotes failed: unknown result");
  1083. }
  1084. public int findNoteOffset(String authenticationToken, NoteFilter filter, String guid) throws com.evernote.edam.error.EDAMUserException, com.evernote.edam.error.EDAMSystemException, com.evernote.edam.error.EDAMNotFoundException, TException
  1085. {
  1086. send_findNoteOffset(authenticationToken, filter, guid);
  1087. return recv_findNoteOffset();
  1088. }
  1089. public void send_findNoteOffset(String authenticationToken, NoteFilter filter, String guid) throws TException
  1090. {
  1091. oprot_.writeMessageBegin(new TMessage("findNoteOffset", TMessageType.CALL, ++seqid_));
  1092. findNoteOffset_args args = new findNo

Large files files are truncated, but you can click here to view the full file