Subversion Repositories SmartDukaan

Rev

Rev 3206 | Rev 3374 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
3028 mandeep.dh 1
/**
2
 * Autogenerated by Thrift
3
 *
4
 * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
5
 */
6
package in.shop2020.crm;
7
 
8
import java.util.List;
9
import java.util.ArrayList;
10
import java.util.Map;
11
import java.util.HashMap;
12
import java.util.EnumMap;
13
import java.util.Set;
14
import java.util.HashSet;
15
import java.util.EnumSet;
16
import java.util.Collections;
17
import java.util.BitSet;
18
import java.util.Arrays;
19
import org.slf4j.Logger;
20
import org.slf4j.LoggerFactory;
21
 
22
import org.apache.thrift.*;
23
import org.apache.thrift.meta_data.*;
24
import org.apache.thrift.protocol.*;
25
 
26
public class CRMService {
27
 
28
  public interface Iface {
29
 
30
    public List<Ticket> getTickets(long customerId) throws TException;
31
 
3087 mandeep.dh 32
    public List<Ticket> getAssignedTickets(long agentId) throws TException;
33
 
3137 mandeep.dh 34
    public List<Ticket> getUnassignedTickets() throws TException;
3087 mandeep.dh 35
 
3137 mandeep.dh 36
    public List<Ticket> getAllTickets(long agentId) throws TException;
37
 
3028 mandeep.dh 38
    public Ticket getTicket(long ticketId) throws TException;
39
 
3206 mandeep.dh 40
    public void updateTicket(Ticket ticket, Activity activity) throws TException;
3028 mandeep.dh 41
 
3206 mandeep.dh 42
    public long insertTicket(Ticket ticket, Activity activity) throws TException;
3028 mandeep.dh 43
 
44
    public List<Activity> getActivities(long customerId) throws TException;
45
 
3339 mandeep.dh 46
    public List<Activity> getActivitiesByCreator(long creatorId) throws TException;
47
 
3028 mandeep.dh 48
    public List<Activity> getActivitiesForTicket(long ticketId) throws TException;
49
 
50
    public Activity getActivity(long activityId) throws TException;
51
 
52
    public Activity getLastActivity(long ticketId) throws TException;
53
 
54
    public void insertActivity(Activity activity) throws TException;
55
 
3087 mandeep.dh 56
    public List<Agent> getAllAgents() throws TException;
57
 
3028 mandeep.dh 58
    public Agent getAgent(long agentId) throws TException;
59
 
60
    public Agent getAgentByEmailId(String agentEmailId) throws TException;
61
 
3087 mandeep.dh 62
    public void updatePasswordForAgent(String agentEmailId, String password) throws TException;
63
 
64
    public List<String> getRoleNamesForAgent(String agentEmailId) throws TException;
65
 
66
    public List<String> getPermissionsForRoleName(String roleName) throws TException;
67
 
3339 mandeep.dh 68
    public long getLastEmailProcessedTimestamp() throws TException;
69
 
70
    public void updateLastEmailProcessedTimestamp(long timestamp) throws TException;
71
 
3028 mandeep.dh 72
  }
73
 
74
  public static class Client implements Iface {
75
    public Client(TProtocol prot)
76
    {
77
      this(prot, prot);
78
    }
79
 
80
    public Client(TProtocol iprot, TProtocol oprot)
81
    {
82
      iprot_ = iprot;
83
      oprot_ = oprot;
84
    }
85
 
86
    protected TProtocol iprot_;
87
    protected TProtocol oprot_;
88
 
89
    protected int seqid_;
90
 
91
    public TProtocol getInputProtocol()
92
    {
93
      return this.iprot_;
94
    }
95
 
96
    public TProtocol getOutputProtocol()
97
    {
98
      return this.oprot_;
99
    }
100
 
101
    public List<Ticket> getTickets(long customerId) throws TException
102
    {
103
      send_getTickets(customerId);
104
      return recv_getTickets();
105
    }
106
 
107
    public void send_getTickets(long customerId) throws TException
108
    {
109
      oprot_.writeMessageBegin(new TMessage("getTickets", TMessageType.CALL, seqid_));
110
      getTickets_args args = new getTickets_args();
111
      args.customerId = customerId;
112
      args.write(oprot_);
113
      oprot_.writeMessageEnd();
114
      oprot_.getTransport().flush();
115
    }
116
 
117
    public List<Ticket> recv_getTickets() throws TException
118
    {
119
      TMessage msg = iprot_.readMessageBegin();
120
      if (msg.type == TMessageType.EXCEPTION) {
121
        TApplicationException x = TApplicationException.read(iprot_);
122
        iprot_.readMessageEnd();
123
        throw x;
124
      }
125
      getTickets_result result = new getTickets_result();
126
      result.read(iprot_);
127
      iprot_.readMessageEnd();
128
      if (result.isSetSuccess()) {
129
        return result.success;
130
      }
131
      throw new TApplicationException(TApplicationException.MISSING_RESULT, "getTickets failed: unknown result");
132
    }
133
 
3087 mandeep.dh 134
    public List<Ticket> getAssignedTickets(long agentId) throws TException
135
    {
136
      send_getAssignedTickets(agentId);
137
      return recv_getAssignedTickets();
138
    }
139
 
140
    public void send_getAssignedTickets(long agentId) throws TException
141
    {
142
      oprot_.writeMessageBegin(new TMessage("getAssignedTickets", TMessageType.CALL, seqid_));
143
      getAssignedTickets_args args = new getAssignedTickets_args();
144
      args.agentId = agentId;
145
      args.write(oprot_);
146
      oprot_.writeMessageEnd();
147
      oprot_.getTransport().flush();
148
    }
149
 
150
    public List<Ticket> recv_getAssignedTickets() throws TException
151
    {
152
      TMessage msg = iprot_.readMessageBegin();
153
      if (msg.type == TMessageType.EXCEPTION) {
154
        TApplicationException x = TApplicationException.read(iprot_);
155
        iprot_.readMessageEnd();
156
        throw x;
157
      }
158
      getAssignedTickets_result result = new getAssignedTickets_result();
159
      result.read(iprot_);
160
      iprot_.readMessageEnd();
161
      if (result.isSetSuccess()) {
162
        return result.success;
163
      }
164
      throw new TApplicationException(TApplicationException.MISSING_RESULT, "getAssignedTickets failed: unknown result");
165
    }
166
 
3137 mandeep.dh 167
    public List<Ticket> getUnassignedTickets() throws TException
3087 mandeep.dh 168
    {
3137 mandeep.dh 169
      send_getUnassignedTickets();
170
      return recv_getUnassignedTickets();
3087 mandeep.dh 171
    }
172
 
3137 mandeep.dh 173
    public void send_getUnassignedTickets() throws TException
3087 mandeep.dh 174
    {
3137 mandeep.dh 175
      oprot_.writeMessageBegin(new TMessage("getUnassignedTickets", TMessageType.CALL, seqid_));
176
      getUnassignedTickets_args args = new getUnassignedTickets_args();
3087 mandeep.dh 177
      args.write(oprot_);
178
      oprot_.writeMessageEnd();
179
      oprot_.getTransport().flush();
180
    }
181
 
3137 mandeep.dh 182
    public List<Ticket> recv_getUnassignedTickets() throws TException
3087 mandeep.dh 183
    {
184
      TMessage msg = iprot_.readMessageBegin();
185
      if (msg.type == TMessageType.EXCEPTION) {
186
        TApplicationException x = TApplicationException.read(iprot_);
187
        iprot_.readMessageEnd();
188
        throw x;
189
      }
3137 mandeep.dh 190
      getUnassignedTickets_result result = new getUnassignedTickets_result();
3087 mandeep.dh 191
      result.read(iprot_);
192
      iprot_.readMessageEnd();
193
      if (result.isSetSuccess()) {
194
        return result.success;
195
      }
3137 mandeep.dh 196
      throw new TApplicationException(TApplicationException.MISSING_RESULT, "getUnassignedTickets failed: unknown result");
3087 mandeep.dh 197
    }
198
 
3137 mandeep.dh 199
    public List<Ticket> getAllTickets(long agentId) throws TException
200
    {
201
      send_getAllTickets(agentId);
202
      return recv_getAllTickets();
203
    }
204
 
205
    public void send_getAllTickets(long agentId) throws TException
206
    {
207
      oprot_.writeMessageBegin(new TMessage("getAllTickets", TMessageType.CALL, seqid_));
208
      getAllTickets_args args = new getAllTickets_args();
209
      args.agentId = agentId;
210
      args.write(oprot_);
211
      oprot_.writeMessageEnd();
212
      oprot_.getTransport().flush();
213
    }
214
 
215
    public List<Ticket> recv_getAllTickets() throws TException
216
    {
217
      TMessage msg = iprot_.readMessageBegin();
218
      if (msg.type == TMessageType.EXCEPTION) {
219
        TApplicationException x = TApplicationException.read(iprot_);
220
        iprot_.readMessageEnd();
221
        throw x;
222
      }
223
      getAllTickets_result result = new getAllTickets_result();
224
      result.read(iprot_);
225
      iprot_.readMessageEnd();
226
      if (result.isSetSuccess()) {
227
        return result.success;
228
      }
229
      throw new TApplicationException(TApplicationException.MISSING_RESULT, "getAllTickets failed: unknown result");
230
    }
231
 
3028 mandeep.dh 232
    public Ticket getTicket(long ticketId) throws TException
233
    {
234
      send_getTicket(ticketId);
235
      return recv_getTicket();
236
    }
237
 
238
    public void send_getTicket(long ticketId) throws TException
239
    {
240
      oprot_.writeMessageBegin(new TMessage("getTicket", TMessageType.CALL, seqid_));
241
      getTicket_args args = new getTicket_args();
242
      args.ticketId = ticketId;
243
      args.write(oprot_);
244
      oprot_.writeMessageEnd();
245
      oprot_.getTransport().flush();
246
    }
247
 
248
    public Ticket recv_getTicket() throws TException
249
    {
250
      TMessage msg = iprot_.readMessageBegin();
251
      if (msg.type == TMessageType.EXCEPTION) {
252
        TApplicationException x = TApplicationException.read(iprot_);
253
        iprot_.readMessageEnd();
254
        throw x;
255
      }
256
      getTicket_result result = new getTicket_result();
257
      result.read(iprot_);
258
      iprot_.readMessageEnd();
259
      if (result.isSetSuccess()) {
260
        return result.success;
261
      }
262
      throw new TApplicationException(TApplicationException.MISSING_RESULT, "getTicket failed: unknown result");
263
    }
264
 
3206 mandeep.dh 265
    public void updateTicket(Ticket ticket, Activity activity) throws TException
3028 mandeep.dh 266
    {
3206 mandeep.dh 267
      send_updateTicket(ticket, activity);
3028 mandeep.dh 268
      recv_updateTicket();
269
    }
270
 
3206 mandeep.dh 271
    public void send_updateTicket(Ticket ticket, Activity activity) throws TException
3028 mandeep.dh 272
    {
273
      oprot_.writeMessageBegin(new TMessage("updateTicket", TMessageType.CALL, seqid_));
274
      updateTicket_args args = new updateTicket_args();
275
      args.ticket = ticket;
3206 mandeep.dh 276
      args.activity = activity;
3028 mandeep.dh 277
      args.write(oprot_);
278
      oprot_.writeMessageEnd();
279
      oprot_.getTransport().flush();
280
    }
281
 
282
    public void recv_updateTicket() throws TException
283
    {
284
      TMessage msg = iprot_.readMessageBegin();
285
      if (msg.type == TMessageType.EXCEPTION) {
286
        TApplicationException x = TApplicationException.read(iprot_);
287
        iprot_.readMessageEnd();
288
        throw x;
289
      }
290
      updateTicket_result result = new updateTicket_result();
291
      result.read(iprot_);
292
      iprot_.readMessageEnd();
293
      return;
294
    }
295
 
3206 mandeep.dh 296
    public long insertTicket(Ticket ticket, Activity activity) throws TException
3028 mandeep.dh 297
    {
3206 mandeep.dh 298
      send_insertTicket(ticket, activity);
3028 mandeep.dh 299
      return recv_insertTicket();
300
    }
301
 
3206 mandeep.dh 302
    public void send_insertTicket(Ticket ticket, Activity activity) throws TException
3028 mandeep.dh 303
    {
304
      oprot_.writeMessageBegin(new TMessage("insertTicket", TMessageType.CALL, seqid_));
305
      insertTicket_args args = new insertTicket_args();
306
      args.ticket = ticket;
3206 mandeep.dh 307
      args.activity = activity;
3028 mandeep.dh 308
      args.write(oprot_);
309
      oprot_.writeMessageEnd();
310
      oprot_.getTransport().flush();
311
    }
312
 
313
    public long recv_insertTicket() throws TException
314
    {
315
      TMessage msg = iprot_.readMessageBegin();
316
      if (msg.type == TMessageType.EXCEPTION) {
317
        TApplicationException x = TApplicationException.read(iprot_);
318
        iprot_.readMessageEnd();
319
        throw x;
320
      }
321
      insertTicket_result result = new insertTicket_result();
322
      result.read(iprot_);
323
      iprot_.readMessageEnd();
324
      if (result.isSetSuccess()) {
325
        return result.success;
326
      }
327
      throw new TApplicationException(TApplicationException.MISSING_RESULT, "insertTicket failed: unknown result");
328
    }
329
 
330
    public List<Activity> getActivities(long customerId) throws TException
331
    {
332
      send_getActivities(customerId);
333
      return recv_getActivities();
334
    }
335
 
336
    public void send_getActivities(long customerId) throws TException
337
    {
338
      oprot_.writeMessageBegin(new TMessage("getActivities", TMessageType.CALL, seqid_));
339
      getActivities_args args = new getActivities_args();
340
      args.customerId = customerId;
341
      args.write(oprot_);
342
      oprot_.writeMessageEnd();
343
      oprot_.getTransport().flush();
344
    }
345
 
346
    public List<Activity> recv_getActivities() throws TException
347
    {
348
      TMessage msg = iprot_.readMessageBegin();
349
      if (msg.type == TMessageType.EXCEPTION) {
350
        TApplicationException x = TApplicationException.read(iprot_);
351
        iprot_.readMessageEnd();
352
        throw x;
353
      }
354
      getActivities_result result = new getActivities_result();
355
      result.read(iprot_);
356
      iprot_.readMessageEnd();
357
      if (result.isSetSuccess()) {
358
        return result.success;
359
      }
360
      throw new TApplicationException(TApplicationException.MISSING_RESULT, "getActivities failed: unknown result");
361
    }
362
 
3339 mandeep.dh 363
    public List<Activity> getActivitiesByCreator(long creatorId) throws TException
364
    {
365
      send_getActivitiesByCreator(creatorId);
366
      return recv_getActivitiesByCreator();
367
    }
368
 
369
    public void send_getActivitiesByCreator(long creatorId) throws TException
370
    {
371
      oprot_.writeMessageBegin(new TMessage("getActivitiesByCreator", TMessageType.CALL, seqid_));
372
      getActivitiesByCreator_args args = new getActivitiesByCreator_args();
373
      args.creatorId = creatorId;
374
      args.write(oprot_);
375
      oprot_.writeMessageEnd();
376
      oprot_.getTransport().flush();
377
    }
378
 
379
    public List<Activity> recv_getActivitiesByCreator() throws TException
380
    {
381
      TMessage msg = iprot_.readMessageBegin();
382
      if (msg.type == TMessageType.EXCEPTION) {
383
        TApplicationException x = TApplicationException.read(iprot_);
384
        iprot_.readMessageEnd();
385
        throw x;
386
      }
387
      getActivitiesByCreator_result result = new getActivitiesByCreator_result();
388
      result.read(iprot_);
389
      iprot_.readMessageEnd();
390
      if (result.isSetSuccess()) {
391
        return result.success;
392
      }
393
      throw new TApplicationException(TApplicationException.MISSING_RESULT, "getActivitiesByCreator failed: unknown result");
394
    }
395
 
3028 mandeep.dh 396
    public List<Activity> getActivitiesForTicket(long ticketId) throws TException
397
    {
398
      send_getActivitiesForTicket(ticketId);
399
      return recv_getActivitiesForTicket();
400
    }
401
 
402
    public void send_getActivitiesForTicket(long ticketId) throws TException
403
    {
404
      oprot_.writeMessageBegin(new TMessage("getActivitiesForTicket", TMessageType.CALL, seqid_));
405
      getActivitiesForTicket_args args = new getActivitiesForTicket_args();
406
      args.ticketId = ticketId;
407
      args.write(oprot_);
408
      oprot_.writeMessageEnd();
409
      oprot_.getTransport().flush();
410
    }
411
 
412
    public List<Activity> recv_getActivitiesForTicket() throws TException
413
    {
414
      TMessage msg = iprot_.readMessageBegin();
415
      if (msg.type == TMessageType.EXCEPTION) {
416
        TApplicationException x = TApplicationException.read(iprot_);
417
        iprot_.readMessageEnd();
418
        throw x;
419
      }
420
      getActivitiesForTicket_result result = new getActivitiesForTicket_result();
421
      result.read(iprot_);
422
      iprot_.readMessageEnd();
423
      if (result.isSetSuccess()) {
424
        return result.success;
425
      }
426
      throw new TApplicationException(TApplicationException.MISSING_RESULT, "getActivitiesForTicket failed: unknown result");
427
    }
428
 
429
    public Activity getActivity(long activityId) throws TException
430
    {
431
      send_getActivity(activityId);
432
      return recv_getActivity();
433
    }
434
 
435
    public void send_getActivity(long activityId) throws TException
436
    {
437
      oprot_.writeMessageBegin(new TMessage("getActivity", TMessageType.CALL, seqid_));
438
      getActivity_args args = new getActivity_args();
439
      args.activityId = activityId;
440
      args.write(oprot_);
441
      oprot_.writeMessageEnd();
442
      oprot_.getTransport().flush();
443
    }
444
 
445
    public Activity recv_getActivity() throws TException
446
    {
447
      TMessage msg = iprot_.readMessageBegin();
448
      if (msg.type == TMessageType.EXCEPTION) {
449
        TApplicationException x = TApplicationException.read(iprot_);
450
        iprot_.readMessageEnd();
451
        throw x;
452
      }
453
      getActivity_result result = new getActivity_result();
454
      result.read(iprot_);
455
      iprot_.readMessageEnd();
456
      if (result.isSetSuccess()) {
457
        return result.success;
458
      }
459
      throw new TApplicationException(TApplicationException.MISSING_RESULT, "getActivity failed: unknown result");
460
    }
461
 
462
    public Activity getLastActivity(long ticketId) throws TException
463
    {
464
      send_getLastActivity(ticketId);
465
      return recv_getLastActivity();
466
    }
467
 
468
    public void send_getLastActivity(long ticketId) throws TException
469
    {
470
      oprot_.writeMessageBegin(new TMessage("getLastActivity", TMessageType.CALL, seqid_));
471
      getLastActivity_args args = new getLastActivity_args();
472
      args.ticketId = ticketId;
473
      args.write(oprot_);
474
      oprot_.writeMessageEnd();
475
      oprot_.getTransport().flush();
476
    }
477
 
478
    public Activity recv_getLastActivity() throws TException
479
    {
480
      TMessage msg = iprot_.readMessageBegin();
481
      if (msg.type == TMessageType.EXCEPTION) {
482
        TApplicationException x = TApplicationException.read(iprot_);
483
        iprot_.readMessageEnd();
484
        throw x;
485
      }
486
      getLastActivity_result result = new getLastActivity_result();
487
      result.read(iprot_);
488
      iprot_.readMessageEnd();
489
      if (result.isSetSuccess()) {
490
        return result.success;
491
      }
492
      throw new TApplicationException(TApplicationException.MISSING_RESULT, "getLastActivity failed: unknown result");
493
    }
494
 
495
    public void insertActivity(Activity activity) throws TException
496
    {
497
      send_insertActivity(activity);
498
      recv_insertActivity();
499
    }
500
 
501
    public void send_insertActivity(Activity activity) throws TException
502
    {
503
      oprot_.writeMessageBegin(new TMessage("insertActivity", TMessageType.CALL, seqid_));
504
      insertActivity_args args = new insertActivity_args();
505
      args.activity = activity;
506
      args.write(oprot_);
507
      oprot_.writeMessageEnd();
508
      oprot_.getTransport().flush();
509
    }
510
 
511
    public void recv_insertActivity() throws TException
512
    {
513
      TMessage msg = iprot_.readMessageBegin();
514
      if (msg.type == TMessageType.EXCEPTION) {
515
        TApplicationException x = TApplicationException.read(iprot_);
516
        iprot_.readMessageEnd();
517
        throw x;
518
      }
519
      insertActivity_result result = new insertActivity_result();
520
      result.read(iprot_);
521
      iprot_.readMessageEnd();
522
      return;
523
    }
524
 
3087 mandeep.dh 525
    public List<Agent> getAllAgents() throws TException
526
    {
527
      send_getAllAgents();
528
      return recv_getAllAgents();
529
    }
530
 
531
    public void send_getAllAgents() throws TException
532
    {
533
      oprot_.writeMessageBegin(new TMessage("getAllAgents", TMessageType.CALL, seqid_));
534
      getAllAgents_args args = new getAllAgents_args();
535
      args.write(oprot_);
536
      oprot_.writeMessageEnd();
537
      oprot_.getTransport().flush();
538
    }
539
 
540
    public List<Agent> recv_getAllAgents() throws TException
541
    {
542
      TMessage msg = iprot_.readMessageBegin();
543
      if (msg.type == TMessageType.EXCEPTION) {
544
        TApplicationException x = TApplicationException.read(iprot_);
545
        iprot_.readMessageEnd();
546
        throw x;
547
      }
548
      getAllAgents_result result = new getAllAgents_result();
549
      result.read(iprot_);
550
      iprot_.readMessageEnd();
551
      if (result.isSetSuccess()) {
552
        return result.success;
553
      }
554
      throw new TApplicationException(TApplicationException.MISSING_RESULT, "getAllAgents failed: unknown result");
555
    }
556
 
3028 mandeep.dh 557
    public Agent getAgent(long agentId) throws TException
558
    {
559
      send_getAgent(agentId);
560
      return recv_getAgent();
561
    }
562
 
563
    public void send_getAgent(long agentId) throws TException
564
    {
565
      oprot_.writeMessageBegin(new TMessage("getAgent", TMessageType.CALL, seqid_));
566
      getAgent_args args = new getAgent_args();
567
      args.agentId = agentId;
568
      args.write(oprot_);
569
      oprot_.writeMessageEnd();
570
      oprot_.getTransport().flush();
571
    }
572
 
573
    public Agent recv_getAgent() throws TException
574
    {
575
      TMessage msg = iprot_.readMessageBegin();
576
      if (msg.type == TMessageType.EXCEPTION) {
577
        TApplicationException x = TApplicationException.read(iprot_);
578
        iprot_.readMessageEnd();
579
        throw x;
580
      }
581
      getAgent_result result = new getAgent_result();
582
      result.read(iprot_);
583
      iprot_.readMessageEnd();
584
      if (result.isSetSuccess()) {
585
        return result.success;
586
      }
587
      throw new TApplicationException(TApplicationException.MISSING_RESULT, "getAgent failed: unknown result");
588
    }
589
 
590
    public Agent getAgentByEmailId(String agentEmailId) throws TException
591
    {
592
      send_getAgentByEmailId(agentEmailId);
593
      return recv_getAgentByEmailId();
594
    }
595
 
596
    public void send_getAgentByEmailId(String agentEmailId) throws TException
597
    {
598
      oprot_.writeMessageBegin(new TMessage("getAgentByEmailId", TMessageType.CALL, seqid_));
599
      getAgentByEmailId_args args = new getAgentByEmailId_args();
600
      args.agentEmailId = agentEmailId;
601
      args.write(oprot_);
602
      oprot_.writeMessageEnd();
603
      oprot_.getTransport().flush();
604
    }
605
 
606
    public Agent recv_getAgentByEmailId() throws TException
607
    {
608
      TMessage msg = iprot_.readMessageBegin();
609
      if (msg.type == TMessageType.EXCEPTION) {
610
        TApplicationException x = TApplicationException.read(iprot_);
611
        iprot_.readMessageEnd();
612
        throw x;
613
      }
614
      getAgentByEmailId_result result = new getAgentByEmailId_result();
615
      result.read(iprot_);
616
      iprot_.readMessageEnd();
617
      if (result.isSetSuccess()) {
618
        return result.success;
619
      }
620
      throw new TApplicationException(TApplicationException.MISSING_RESULT, "getAgentByEmailId failed: unknown result");
621
    }
622
 
3087 mandeep.dh 623
    public void updatePasswordForAgent(String agentEmailId, String password) throws TException
624
    {
625
      send_updatePasswordForAgent(agentEmailId, password);
626
      recv_updatePasswordForAgent();
627
    }
628
 
629
    public void send_updatePasswordForAgent(String agentEmailId, String password) throws TException
630
    {
631
      oprot_.writeMessageBegin(new TMessage("updatePasswordForAgent", TMessageType.CALL, seqid_));
632
      updatePasswordForAgent_args args = new updatePasswordForAgent_args();
633
      args.agentEmailId = agentEmailId;
634
      args.password = password;
635
      args.write(oprot_);
636
      oprot_.writeMessageEnd();
637
      oprot_.getTransport().flush();
638
    }
639
 
640
    public void recv_updatePasswordForAgent() throws TException
641
    {
642
      TMessage msg = iprot_.readMessageBegin();
643
      if (msg.type == TMessageType.EXCEPTION) {
644
        TApplicationException x = TApplicationException.read(iprot_);
645
        iprot_.readMessageEnd();
646
        throw x;
647
      }
648
      updatePasswordForAgent_result result = new updatePasswordForAgent_result();
649
      result.read(iprot_);
650
      iprot_.readMessageEnd();
651
      return;
652
    }
653
 
654
    public List<String> getRoleNamesForAgent(String agentEmailId) throws TException
655
    {
656
      send_getRoleNamesForAgent(agentEmailId);
657
      return recv_getRoleNamesForAgent();
658
    }
659
 
660
    public void send_getRoleNamesForAgent(String agentEmailId) throws TException
661
    {
662
      oprot_.writeMessageBegin(new TMessage("getRoleNamesForAgent", TMessageType.CALL, seqid_));
663
      getRoleNamesForAgent_args args = new getRoleNamesForAgent_args();
664
      args.agentEmailId = agentEmailId;
665
      args.write(oprot_);
666
      oprot_.writeMessageEnd();
667
      oprot_.getTransport().flush();
668
    }
669
 
670
    public List<String> recv_getRoleNamesForAgent() throws TException
671
    {
672
      TMessage msg = iprot_.readMessageBegin();
673
      if (msg.type == TMessageType.EXCEPTION) {
674
        TApplicationException x = TApplicationException.read(iprot_);
675
        iprot_.readMessageEnd();
676
        throw x;
677
      }
678
      getRoleNamesForAgent_result result = new getRoleNamesForAgent_result();
679
      result.read(iprot_);
680
      iprot_.readMessageEnd();
681
      if (result.isSetSuccess()) {
682
        return result.success;
683
      }
684
      throw new TApplicationException(TApplicationException.MISSING_RESULT, "getRoleNamesForAgent failed: unknown result");
685
    }
686
 
687
    public List<String> getPermissionsForRoleName(String roleName) throws TException
688
    {
689
      send_getPermissionsForRoleName(roleName);
690
      return recv_getPermissionsForRoleName();
691
    }
692
 
693
    public void send_getPermissionsForRoleName(String roleName) throws TException
694
    {
695
      oprot_.writeMessageBegin(new TMessage("getPermissionsForRoleName", TMessageType.CALL, seqid_));
696
      getPermissionsForRoleName_args args = new getPermissionsForRoleName_args();
697
      args.roleName = roleName;
698
      args.write(oprot_);
699
      oprot_.writeMessageEnd();
700
      oprot_.getTransport().flush();
701
    }
702
 
703
    public List<String> recv_getPermissionsForRoleName() throws TException
704
    {
705
      TMessage msg = iprot_.readMessageBegin();
706
      if (msg.type == TMessageType.EXCEPTION) {
707
        TApplicationException x = TApplicationException.read(iprot_);
708
        iprot_.readMessageEnd();
709
        throw x;
710
      }
711
      getPermissionsForRoleName_result result = new getPermissionsForRoleName_result();
712
      result.read(iprot_);
713
      iprot_.readMessageEnd();
714
      if (result.isSetSuccess()) {
715
        return result.success;
716
      }
717
      throw new TApplicationException(TApplicationException.MISSING_RESULT, "getPermissionsForRoleName failed: unknown result");
718
    }
719
 
3339 mandeep.dh 720
    public long getLastEmailProcessedTimestamp() throws TException
721
    {
722
      send_getLastEmailProcessedTimestamp();
723
      return recv_getLastEmailProcessedTimestamp();
724
    }
725
 
726
    public void send_getLastEmailProcessedTimestamp() throws TException
727
    {
728
      oprot_.writeMessageBegin(new TMessage("getLastEmailProcessedTimestamp", TMessageType.CALL, seqid_));
729
      getLastEmailProcessedTimestamp_args args = new getLastEmailProcessedTimestamp_args();
730
      args.write(oprot_);
731
      oprot_.writeMessageEnd();
732
      oprot_.getTransport().flush();
733
    }
734
 
735
    public long recv_getLastEmailProcessedTimestamp() throws TException
736
    {
737
      TMessage msg = iprot_.readMessageBegin();
738
      if (msg.type == TMessageType.EXCEPTION) {
739
        TApplicationException x = TApplicationException.read(iprot_);
740
        iprot_.readMessageEnd();
741
        throw x;
742
      }
743
      getLastEmailProcessedTimestamp_result result = new getLastEmailProcessedTimestamp_result();
744
      result.read(iprot_);
745
      iprot_.readMessageEnd();
746
      if (result.isSetSuccess()) {
747
        return result.success;
748
      }
749
      throw new TApplicationException(TApplicationException.MISSING_RESULT, "getLastEmailProcessedTimestamp failed: unknown result");
750
    }
751
 
752
    public void updateLastEmailProcessedTimestamp(long timestamp) throws TException
753
    {
754
      send_updateLastEmailProcessedTimestamp(timestamp);
755
      recv_updateLastEmailProcessedTimestamp();
756
    }
757
 
758
    public void send_updateLastEmailProcessedTimestamp(long timestamp) throws TException
759
    {
760
      oprot_.writeMessageBegin(new TMessage("updateLastEmailProcessedTimestamp", TMessageType.CALL, seqid_));
761
      updateLastEmailProcessedTimestamp_args args = new updateLastEmailProcessedTimestamp_args();
762
      args.timestamp = timestamp;
763
      args.write(oprot_);
764
      oprot_.writeMessageEnd();
765
      oprot_.getTransport().flush();
766
    }
767
 
768
    public void recv_updateLastEmailProcessedTimestamp() throws TException
769
    {
770
      TMessage msg = iprot_.readMessageBegin();
771
      if (msg.type == TMessageType.EXCEPTION) {
772
        TApplicationException x = TApplicationException.read(iprot_);
773
        iprot_.readMessageEnd();
774
        throw x;
775
      }
776
      updateLastEmailProcessedTimestamp_result result = new updateLastEmailProcessedTimestamp_result();
777
      result.read(iprot_);
778
      iprot_.readMessageEnd();
779
      return;
780
    }
781
 
3028 mandeep.dh 782
  }
783
  public static class Processor implements TProcessor {
784
    private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
785
    public Processor(Iface iface)
786
    {
787
      iface_ = iface;
788
      processMap_.put("getTickets", new getTickets());
3087 mandeep.dh 789
      processMap_.put("getAssignedTickets", new getAssignedTickets());
3137 mandeep.dh 790
      processMap_.put("getUnassignedTickets", new getUnassignedTickets());
791
      processMap_.put("getAllTickets", new getAllTickets());
3028 mandeep.dh 792
      processMap_.put("getTicket", new getTicket());
793
      processMap_.put("updateTicket", new updateTicket());
794
      processMap_.put("insertTicket", new insertTicket());
795
      processMap_.put("getActivities", new getActivities());
3339 mandeep.dh 796
      processMap_.put("getActivitiesByCreator", new getActivitiesByCreator());
3028 mandeep.dh 797
      processMap_.put("getActivitiesForTicket", new getActivitiesForTicket());
798
      processMap_.put("getActivity", new getActivity());
799
      processMap_.put("getLastActivity", new getLastActivity());
800
      processMap_.put("insertActivity", new insertActivity());
3087 mandeep.dh 801
      processMap_.put("getAllAgents", new getAllAgents());
3028 mandeep.dh 802
      processMap_.put("getAgent", new getAgent());
803
      processMap_.put("getAgentByEmailId", new getAgentByEmailId());
3087 mandeep.dh 804
      processMap_.put("updatePasswordForAgent", new updatePasswordForAgent());
805
      processMap_.put("getRoleNamesForAgent", new getRoleNamesForAgent());
806
      processMap_.put("getPermissionsForRoleName", new getPermissionsForRoleName());
3339 mandeep.dh 807
      processMap_.put("getLastEmailProcessedTimestamp", new getLastEmailProcessedTimestamp());
808
      processMap_.put("updateLastEmailProcessedTimestamp", new updateLastEmailProcessedTimestamp());
3028 mandeep.dh 809
    }
810
 
811
    protected static interface ProcessFunction {
812
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException;
813
    }
814
 
815
    private Iface iface_;
816
    protected final HashMap<String,ProcessFunction> processMap_ = new HashMap<String,ProcessFunction>();
817
 
818
    public boolean process(TProtocol iprot, TProtocol oprot) throws TException
819
    {
820
      TMessage msg = iprot.readMessageBegin();
821
      ProcessFunction fn = processMap_.get(msg.name);
822
      if (fn == null) {
823
        TProtocolUtil.skip(iprot, TType.STRUCT);
824
        iprot.readMessageEnd();
825
        TApplicationException x = new TApplicationException(TApplicationException.UNKNOWN_METHOD, "Invalid method name: '"+msg.name+"'");
826
        oprot.writeMessageBegin(new TMessage(msg.name, TMessageType.EXCEPTION, msg.seqid));
827
        x.write(oprot);
828
        oprot.writeMessageEnd();
829
        oprot.getTransport().flush();
830
        return true;
831
      }
832
      fn.process(msg.seqid, iprot, oprot);
833
      return true;
834
    }
835
 
836
    private class getTickets implements ProcessFunction {
837
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
838
      {
839
        getTickets_args args = new getTickets_args();
840
        args.read(iprot);
841
        iprot.readMessageEnd();
842
        getTickets_result result = new getTickets_result();
843
        result.success = iface_.getTickets(args.customerId);
844
        oprot.writeMessageBegin(new TMessage("getTickets", TMessageType.REPLY, seqid));
845
        result.write(oprot);
846
        oprot.writeMessageEnd();
847
        oprot.getTransport().flush();
848
      }
849
 
850
    }
851
 
3087 mandeep.dh 852
    private class getAssignedTickets implements ProcessFunction {
853
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
854
      {
855
        getAssignedTickets_args args = new getAssignedTickets_args();
856
        args.read(iprot);
857
        iprot.readMessageEnd();
858
        getAssignedTickets_result result = new getAssignedTickets_result();
859
        result.success = iface_.getAssignedTickets(args.agentId);
860
        oprot.writeMessageBegin(new TMessage("getAssignedTickets", TMessageType.REPLY, seqid));
861
        result.write(oprot);
862
        oprot.writeMessageEnd();
863
        oprot.getTransport().flush();
864
      }
865
 
866
    }
867
 
3137 mandeep.dh 868
    private class getUnassignedTickets implements ProcessFunction {
3087 mandeep.dh 869
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
870
      {
3137 mandeep.dh 871
        getUnassignedTickets_args args = new getUnassignedTickets_args();
3087 mandeep.dh 872
        args.read(iprot);
873
        iprot.readMessageEnd();
3137 mandeep.dh 874
        getUnassignedTickets_result result = new getUnassignedTickets_result();
875
        result.success = iface_.getUnassignedTickets();
876
        oprot.writeMessageBegin(new TMessage("getUnassignedTickets", TMessageType.REPLY, seqid));
3087 mandeep.dh 877
        result.write(oprot);
878
        oprot.writeMessageEnd();
879
        oprot.getTransport().flush();
880
      }
881
 
882
    }
883
 
3137 mandeep.dh 884
    private class getAllTickets implements ProcessFunction {
885
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
886
      {
887
        getAllTickets_args args = new getAllTickets_args();
888
        args.read(iprot);
889
        iprot.readMessageEnd();
890
        getAllTickets_result result = new getAllTickets_result();
891
        result.success = iface_.getAllTickets(args.agentId);
892
        oprot.writeMessageBegin(new TMessage("getAllTickets", TMessageType.REPLY, seqid));
893
        result.write(oprot);
894
        oprot.writeMessageEnd();
895
        oprot.getTransport().flush();
896
      }
897
 
898
    }
899
 
3028 mandeep.dh 900
    private class getTicket implements ProcessFunction {
901
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
902
      {
903
        getTicket_args args = new getTicket_args();
904
        args.read(iprot);
905
        iprot.readMessageEnd();
906
        getTicket_result result = new getTicket_result();
907
        result.success = iface_.getTicket(args.ticketId);
908
        oprot.writeMessageBegin(new TMessage("getTicket", TMessageType.REPLY, seqid));
909
        result.write(oprot);
910
        oprot.writeMessageEnd();
911
        oprot.getTransport().flush();
912
      }
913
 
914
    }
915
 
916
    private class updateTicket implements ProcessFunction {
917
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
918
      {
919
        updateTicket_args args = new updateTicket_args();
920
        args.read(iprot);
921
        iprot.readMessageEnd();
922
        updateTicket_result result = new updateTicket_result();
3206 mandeep.dh 923
        iface_.updateTicket(args.ticket, args.activity);
3028 mandeep.dh 924
        oprot.writeMessageBegin(new TMessage("updateTicket", TMessageType.REPLY, seqid));
925
        result.write(oprot);
926
        oprot.writeMessageEnd();
927
        oprot.getTransport().flush();
928
      }
929
 
930
    }
931
 
932
    private class insertTicket implements ProcessFunction {
933
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
934
      {
935
        insertTicket_args args = new insertTicket_args();
936
        args.read(iprot);
937
        iprot.readMessageEnd();
938
        insertTicket_result result = new insertTicket_result();
3206 mandeep.dh 939
        result.success = iface_.insertTicket(args.ticket, args.activity);
3028 mandeep.dh 940
        result.setSuccessIsSet(true);
941
        oprot.writeMessageBegin(new TMessage("insertTicket", TMessageType.REPLY, seqid));
942
        result.write(oprot);
943
        oprot.writeMessageEnd();
944
        oprot.getTransport().flush();
945
      }
946
 
947
    }
948
 
949
    private class getActivities implements ProcessFunction {
950
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
951
      {
952
        getActivities_args args = new getActivities_args();
953
        args.read(iprot);
954
        iprot.readMessageEnd();
955
        getActivities_result result = new getActivities_result();
956
        result.success = iface_.getActivities(args.customerId);
957
        oprot.writeMessageBegin(new TMessage("getActivities", TMessageType.REPLY, seqid));
958
        result.write(oprot);
959
        oprot.writeMessageEnd();
960
        oprot.getTransport().flush();
961
      }
962
 
963
    }
964
 
3339 mandeep.dh 965
    private class getActivitiesByCreator implements ProcessFunction {
966
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
967
      {
968
        getActivitiesByCreator_args args = new getActivitiesByCreator_args();
969
        args.read(iprot);
970
        iprot.readMessageEnd();
971
        getActivitiesByCreator_result result = new getActivitiesByCreator_result();
972
        result.success = iface_.getActivitiesByCreator(args.creatorId);
973
        oprot.writeMessageBegin(new TMessage("getActivitiesByCreator", TMessageType.REPLY, seqid));
974
        result.write(oprot);
975
        oprot.writeMessageEnd();
976
        oprot.getTransport().flush();
977
      }
978
 
979
    }
980
 
3028 mandeep.dh 981
    private class getActivitiesForTicket implements ProcessFunction {
982
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
983
      {
984
        getActivitiesForTicket_args args = new getActivitiesForTicket_args();
985
        args.read(iprot);
986
        iprot.readMessageEnd();
987
        getActivitiesForTicket_result result = new getActivitiesForTicket_result();
988
        result.success = iface_.getActivitiesForTicket(args.ticketId);
989
        oprot.writeMessageBegin(new TMessage("getActivitiesForTicket", TMessageType.REPLY, seqid));
990
        result.write(oprot);
991
        oprot.writeMessageEnd();
992
        oprot.getTransport().flush();
993
      }
994
 
995
    }
996
 
997
    private class getActivity implements ProcessFunction {
998
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
999
      {
1000
        getActivity_args args = new getActivity_args();
1001
        args.read(iprot);
1002
        iprot.readMessageEnd();
1003
        getActivity_result result = new getActivity_result();
1004
        result.success = iface_.getActivity(args.activityId);
1005
        oprot.writeMessageBegin(new TMessage("getActivity", TMessageType.REPLY, seqid));
1006
        result.write(oprot);
1007
        oprot.writeMessageEnd();
1008
        oprot.getTransport().flush();
1009
      }
1010
 
1011
    }
1012
 
1013
    private class getLastActivity implements ProcessFunction {
1014
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
1015
      {
1016
        getLastActivity_args args = new getLastActivity_args();
1017
        args.read(iprot);
1018
        iprot.readMessageEnd();
1019
        getLastActivity_result result = new getLastActivity_result();
1020
        result.success = iface_.getLastActivity(args.ticketId);
1021
        oprot.writeMessageBegin(new TMessage("getLastActivity", TMessageType.REPLY, seqid));
1022
        result.write(oprot);
1023
        oprot.writeMessageEnd();
1024
        oprot.getTransport().flush();
1025
      }
1026
 
1027
    }
1028
 
1029
    private class insertActivity implements ProcessFunction {
1030
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
1031
      {
1032
        insertActivity_args args = new insertActivity_args();
1033
        args.read(iprot);
1034
        iprot.readMessageEnd();
1035
        insertActivity_result result = new insertActivity_result();
1036
        iface_.insertActivity(args.activity);
1037
        oprot.writeMessageBegin(new TMessage("insertActivity", TMessageType.REPLY, seqid));
1038
        result.write(oprot);
1039
        oprot.writeMessageEnd();
1040
        oprot.getTransport().flush();
1041
      }
1042
 
1043
    }
1044
 
3087 mandeep.dh 1045
    private class getAllAgents implements ProcessFunction {
1046
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
1047
      {
1048
        getAllAgents_args args = new getAllAgents_args();
1049
        args.read(iprot);
1050
        iprot.readMessageEnd();
1051
        getAllAgents_result result = new getAllAgents_result();
1052
        result.success = iface_.getAllAgents();
1053
        oprot.writeMessageBegin(new TMessage("getAllAgents", TMessageType.REPLY, seqid));
1054
        result.write(oprot);
1055
        oprot.writeMessageEnd();
1056
        oprot.getTransport().flush();
1057
      }
1058
 
1059
    }
1060
 
3028 mandeep.dh 1061
    private class getAgent implements ProcessFunction {
1062
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
1063
      {
1064
        getAgent_args args = new getAgent_args();
1065
        args.read(iprot);
1066
        iprot.readMessageEnd();
1067
        getAgent_result result = new getAgent_result();
1068
        result.success = iface_.getAgent(args.agentId);
1069
        oprot.writeMessageBegin(new TMessage("getAgent", TMessageType.REPLY, seqid));
1070
        result.write(oprot);
1071
        oprot.writeMessageEnd();
1072
        oprot.getTransport().flush();
1073
      }
1074
 
1075
    }
1076
 
1077
    private class getAgentByEmailId implements ProcessFunction {
1078
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
1079
      {
1080
        getAgentByEmailId_args args = new getAgentByEmailId_args();
1081
        args.read(iprot);
1082
        iprot.readMessageEnd();
1083
        getAgentByEmailId_result result = new getAgentByEmailId_result();
1084
        result.success = iface_.getAgentByEmailId(args.agentEmailId);
1085
        oprot.writeMessageBegin(new TMessage("getAgentByEmailId", TMessageType.REPLY, seqid));
1086
        result.write(oprot);
1087
        oprot.writeMessageEnd();
1088
        oprot.getTransport().flush();
1089
      }
1090
 
1091
    }
1092
 
3087 mandeep.dh 1093
    private class updatePasswordForAgent implements ProcessFunction {
1094
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
1095
      {
1096
        updatePasswordForAgent_args args = new updatePasswordForAgent_args();
1097
        args.read(iprot);
1098
        iprot.readMessageEnd();
1099
        updatePasswordForAgent_result result = new updatePasswordForAgent_result();
1100
        iface_.updatePasswordForAgent(args.agentEmailId, args.password);
1101
        oprot.writeMessageBegin(new TMessage("updatePasswordForAgent", TMessageType.REPLY, seqid));
1102
        result.write(oprot);
1103
        oprot.writeMessageEnd();
1104
        oprot.getTransport().flush();
1105
      }
1106
 
1107
    }
1108
 
1109
    private class getRoleNamesForAgent implements ProcessFunction {
1110
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
1111
      {
1112
        getRoleNamesForAgent_args args = new getRoleNamesForAgent_args();
1113
        args.read(iprot);
1114
        iprot.readMessageEnd();
1115
        getRoleNamesForAgent_result result = new getRoleNamesForAgent_result();
1116
        result.success = iface_.getRoleNamesForAgent(args.agentEmailId);
1117
        oprot.writeMessageBegin(new TMessage("getRoleNamesForAgent", TMessageType.REPLY, seqid));
1118
        result.write(oprot);
1119
        oprot.writeMessageEnd();
1120
        oprot.getTransport().flush();
1121
      }
1122
 
1123
    }
1124
 
1125
    private class getPermissionsForRoleName implements ProcessFunction {
1126
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
1127
      {
1128
        getPermissionsForRoleName_args args = new getPermissionsForRoleName_args();
1129
        args.read(iprot);
1130
        iprot.readMessageEnd();
1131
        getPermissionsForRoleName_result result = new getPermissionsForRoleName_result();
1132
        result.success = iface_.getPermissionsForRoleName(args.roleName);
1133
        oprot.writeMessageBegin(new TMessage("getPermissionsForRoleName", TMessageType.REPLY, seqid));
1134
        result.write(oprot);
1135
        oprot.writeMessageEnd();
1136
        oprot.getTransport().flush();
1137
      }
1138
 
1139
    }
1140
 
3339 mandeep.dh 1141
    private class getLastEmailProcessedTimestamp implements ProcessFunction {
1142
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
1143
      {
1144
        getLastEmailProcessedTimestamp_args args = new getLastEmailProcessedTimestamp_args();
1145
        args.read(iprot);
1146
        iprot.readMessageEnd();
1147
        getLastEmailProcessedTimestamp_result result = new getLastEmailProcessedTimestamp_result();
1148
        result.success = iface_.getLastEmailProcessedTimestamp();
1149
        result.setSuccessIsSet(true);
1150
        oprot.writeMessageBegin(new TMessage("getLastEmailProcessedTimestamp", TMessageType.REPLY, seqid));
1151
        result.write(oprot);
1152
        oprot.writeMessageEnd();
1153
        oprot.getTransport().flush();
1154
      }
1155
 
1156
    }
1157
 
1158
    private class updateLastEmailProcessedTimestamp implements ProcessFunction {
1159
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException
1160
      {
1161
        updateLastEmailProcessedTimestamp_args args = new updateLastEmailProcessedTimestamp_args();
1162
        args.read(iprot);
1163
        iprot.readMessageEnd();
1164
        updateLastEmailProcessedTimestamp_result result = new updateLastEmailProcessedTimestamp_result();
1165
        iface_.updateLastEmailProcessedTimestamp(args.timestamp);
1166
        oprot.writeMessageBegin(new TMessage("updateLastEmailProcessedTimestamp", TMessageType.REPLY, seqid));
1167
        result.write(oprot);
1168
        oprot.writeMessageEnd();
1169
        oprot.getTransport().flush();
1170
      }
1171
 
1172
    }
1173
 
3028 mandeep.dh 1174
  }
1175
 
1176
  public static class getTickets_args implements TBase<getTickets_args._Fields>, java.io.Serializable, Cloneable, Comparable<getTickets_args>   {
1177
    private static final TStruct STRUCT_DESC = new TStruct("getTickets_args");
1178
 
1179
    private static final TField CUSTOMER_ID_FIELD_DESC = new TField("customerId", TType.I64, (short)1);
1180
 
1181
    private long customerId;
1182
 
1183
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
1184
    public enum _Fields implements TFieldIdEnum {
1185
      CUSTOMER_ID((short)1, "customerId");
1186
 
1187
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
1188
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
1189
 
1190
      static {
1191
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
1192
          byId.put((int)field._thriftId, field);
1193
          byName.put(field.getFieldName(), field);
1194
        }
1195
      }
1196
 
1197
      /**
1198
       * Find the _Fields constant that matches fieldId, or null if its not found.
1199
       */
1200
      public static _Fields findByThriftId(int fieldId) {
1201
        return byId.get(fieldId);
1202
      }
1203
 
1204
      /**
1205
       * Find the _Fields constant that matches fieldId, throwing an exception
1206
       * if it is not found.
1207
       */
1208
      public static _Fields findByThriftIdOrThrow(int fieldId) {
1209
        _Fields fields = findByThriftId(fieldId);
1210
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
1211
        return fields;
1212
      }
1213
 
1214
      /**
1215
       * Find the _Fields constant that matches name, or null if its not found.
1216
       */
1217
      public static _Fields findByName(String name) {
1218
        return byName.get(name);
1219
      }
1220
 
1221
      private final short _thriftId;
1222
      private final String _fieldName;
1223
 
1224
      _Fields(short thriftId, String fieldName) {
1225
        _thriftId = thriftId;
1226
        _fieldName = fieldName;
1227
      }
1228
 
1229
      public short getThriftFieldId() {
1230
        return _thriftId;
1231
      }
1232
 
1233
      public String getFieldName() {
1234
        return _fieldName;
1235
      }
1236
    }
1237
 
1238
    // isset id assignments
1239
    private static final int __CUSTOMERID_ISSET_ID = 0;
1240
    private BitSet __isset_bit_vector = new BitSet(1);
1241
 
1242
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
1243
      put(_Fields.CUSTOMER_ID, new FieldMetaData("customerId", TFieldRequirementType.DEFAULT, 
1244
          new FieldValueMetaData(TType.I64)));
1245
    }});
1246
 
1247
    static {
1248
      FieldMetaData.addStructMetaDataMap(getTickets_args.class, metaDataMap);
1249
    }
1250
 
1251
    public getTickets_args() {
1252
    }
1253
 
1254
    public getTickets_args(
1255
      long customerId)
1256
    {
1257
      this();
1258
      this.customerId = customerId;
1259
      setCustomerIdIsSet(true);
1260
    }
1261
 
1262
    /**
1263
     * Performs a deep copy on <i>other</i>.
1264
     */
1265
    public getTickets_args(getTickets_args other) {
1266
      __isset_bit_vector.clear();
1267
      __isset_bit_vector.or(other.__isset_bit_vector);
1268
      this.customerId = other.customerId;
1269
    }
1270
 
1271
    public getTickets_args deepCopy() {
1272
      return new getTickets_args(this);
1273
    }
1274
 
1275
    @Deprecated
1276
    public getTickets_args clone() {
1277
      return new getTickets_args(this);
1278
    }
1279
 
1280
    public long getCustomerId() {
1281
      return this.customerId;
1282
    }
1283
 
1284
    public getTickets_args setCustomerId(long customerId) {
1285
      this.customerId = customerId;
1286
      setCustomerIdIsSet(true);
1287
      return this;
1288
    }
1289
 
1290
    public void unsetCustomerId() {
1291
      __isset_bit_vector.clear(__CUSTOMERID_ISSET_ID);
1292
    }
1293
 
1294
    /** Returns true if field customerId is set (has been asigned a value) and false otherwise */
1295
    public boolean isSetCustomerId() {
1296
      return __isset_bit_vector.get(__CUSTOMERID_ISSET_ID);
1297
    }
1298
 
1299
    public void setCustomerIdIsSet(boolean value) {
1300
      __isset_bit_vector.set(__CUSTOMERID_ISSET_ID, value);
1301
    }
1302
 
1303
    public void setFieldValue(_Fields field, Object value) {
1304
      switch (field) {
1305
      case CUSTOMER_ID:
1306
        if (value == null) {
1307
          unsetCustomerId();
1308
        } else {
1309
          setCustomerId((Long)value);
1310
        }
1311
        break;
1312
 
1313
      }
1314
    }
1315
 
1316
    public void setFieldValue(int fieldID, Object value) {
1317
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
1318
    }
1319
 
1320
    public Object getFieldValue(_Fields field) {
1321
      switch (field) {
1322
      case CUSTOMER_ID:
1323
        return new Long(getCustomerId());
1324
 
1325
      }
1326
      throw new IllegalStateException();
1327
    }
1328
 
1329
    public Object getFieldValue(int fieldId) {
1330
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
1331
    }
1332
 
1333
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
1334
    public boolean isSet(_Fields field) {
1335
      switch (field) {
1336
      case CUSTOMER_ID:
1337
        return isSetCustomerId();
1338
      }
1339
      throw new IllegalStateException();
1340
    }
1341
 
1342
    public boolean isSet(int fieldID) {
1343
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
1344
    }
1345
 
1346
    @Override
1347
    public boolean equals(Object that) {
1348
      if (that == null)
1349
        return false;
1350
      if (that instanceof getTickets_args)
1351
        return this.equals((getTickets_args)that);
1352
      return false;
1353
    }
1354
 
1355
    public boolean equals(getTickets_args that) {
1356
      if (that == null)
1357
        return false;
1358
 
1359
      boolean this_present_customerId = true;
1360
      boolean that_present_customerId = true;
1361
      if (this_present_customerId || that_present_customerId) {
1362
        if (!(this_present_customerId && that_present_customerId))
1363
          return false;
1364
        if (this.customerId != that.customerId)
1365
          return false;
1366
      }
1367
 
1368
      return true;
1369
    }
1370
 
1371
    @Override
1372
    public int hashCode() {
1373
      return 0;
1374
    }
1375
 
1376
    public int compareTo(getTickets_args other) {
1377
      if (!getClass().equals(other.getClass())) {
1378
        return getClass().getName().compareTo(other.getClass().getName());
1379
      }
1380
 
1381
      int lastComparison = 0;
1382
      getTickets_args typedOther = (getTickets_args)other;
1383
 
1384
      lastComparison = Boolean.valueOf(isSetCustomerId()).compareTo(isSetCustomerId());
1385
      if (lastComparison != 0) {
1386
        return lastComparison;
1387
      }
1388
      lastComparison = TBaseHelper.compareTo(customerId, typedOther.customerId);
1389
      if (lastComparison != 0) {
1390
        return lastComparison;
1391
      }
1392
      return 0;
1393
    }
1394
 
1395
    public void read(TProtocol iprot) throws TException {
1396
      TField field;
1397
      iprot.readStructBegin();
1398
      while (true)
1399
      {
1400
        field = iprot.readFieldBegin();
1401
        if (field.type == TType.STOP) { 
1402
          break;
1403
        }
1404
        _Fields fieldId = _Fields.findByThriftId(field.id);
1405
        if (fieldId == null) {
1406
          TProtocolUtil.skip(iprot, field.type);
1407
        } else {
1408
          switch (fieldId) {
1409
            case CUSTOMER_ID:
1410
              if (field.type == TType.I64) {
1411
                this.customerId = iprot.readI64();
1412
                setCustomerIdIsSet(true);
1413
              } else { 
1414
                TProtocolUtil.skip(iprot, field.type);
1415
              }
1416
              break;
1417
          }
1418
          iprot.readFieldEnd();
1419
        }
1420
      }
1421
      iprot.readStructEnd();
1422
      validate();
1423
    }
1424
 
1425
    public void write(TProtocol oprot) throws TException {
1426
      validate();
1427
 
1428
      oprot.writeStructBegin(STRUCT_DESC);
1429
      oprot.writeFieldBegin(CUSTOMER_ID_FIELD_DESC);
1430
      oprot.writeI64(this.customerId);
1431
      oprot.writeFieldEnd();
1432
      oprot.writeFieldStop();
1433
      oprot.writeStructEnd();
1434
    }
1435
 
1436
    @Override
1437
    public String toString() {
1438
      StringBuilder sb = new StringBuilder("getTickets_args(");
1439
      boolean first = true;
1440
 
1441
      sb.append("customerId:");
1442
      sb.append(this.customerId);
1443
      first = false;
1444
      sb.append(")");
1445
      return sb.toString();
1446
    }
1447
 
1448
    public void validate() throws TException {
1449
      // check for required fields
1450
    }
1451
 
1452
  }
1453
 
1454
  public static class getTickets_result implements TBase<getTickets_result._Fields>, java.io.Serializable, Cloneable, Comparable<getTickets_result>   {
1455
    private static final TStruct STRUCT_DESC = new TStruct("getTickets_result");
1456
 
1457
    private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.LIST, (short)0);
1458
 
1459
    private List<Ticket> success;
1460
 
1461
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
1462
    public enum _Fields implements TFieldIdEnum {
1463
      SUCCESS((short)0, "success");
1464
 
1465
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
1466
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
1467
 
1468
      static {
1469
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
1470
          byId.put((int)field._thriftId, field);
1471
          byName.put(field.getFieldName(), field);
1472
        }
1473
      }
1474
 
1475
      /**
1476
       * Find the _Fields constant that matches fieldId, or null if its not found.
1477
       */
1478
      public static _Fields findByThriftId(int fieldId) {
1479
        return byId.get(fieldId);
1480
      }
1481
 
1482
      /**
1483
       * Find the _Fields constant that matches fieldId, throwing an exception
1484
       * if it is not found.
1485
       */
1486
      public static _Fields findByThriftIdOrThrow(int fieldId) {
1487
        _Fields fields = findByThriftId(fieldId);
1488
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
1489
        return fields;
1490
      }
1491
 
1492
      /**
1493
       * Find the _Fields constant that matches name, or null if its not found.
1494
       */
1495
      public static _Fields findByName(String name) {
1496
        return byName.get(name);
1497
      }
1498
 
1499
      private final short _thriftId;
1500
      private final String _fieldName;
1501
 
1502
      _Fields(short thriftId, String fieldName) {
1503
        _thriftId = thriftId;
1504
        _fieldName = fieldName;
1505
      }
1506
 
1507
      public short getThriftFieldId() {
1508
        return _thriftId;
1509
      }
1510
 
1511
      public String getFieldName() {
1512
        return _fieldName;
1513
      }
1514
    }
1515
 
1516
    // isset id assignments
1517
 
1518
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
1519
      put(_Fields.SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, 
1520
          new ListMetaData(TType.LIST, 
1521
              new StructMetaData(TType.STRUCT, Ticket.class))));
1522
    }});
1523
 
1524
    static {
1525
      FieldMetaData.addStructMetaDataMap(getTickets_result.class, metaDataMap);
1526
    }
1527
 
1528
    public getTickets_result() {
1529
    }
1530
 
1531
    public getTickets_result(
1532
      List<Ticket> success)
1533
    {
1534
      this();
1535
      this.success = success;
1536
    }
1537
 
1538
    /**
1539
     * Performs a deep copy on <i>other</i>.
1540
     */
1541
    public getTickets_result(getTickets_result other) {
1542
      if (other.isSetSuccess()) {
1543
        List<Ticket> __this__success = new ArrayList<Ticket>();
1544
        for (Ticket other_element : other.success) {
1545
          __this__success.add(new Ticket(other_element));
1546
        }
1547
        this.success = __this__success;
1548
      }
1549
    }
1550
 
1551
    public getTickets_result deepCopy() {
1552
      return new getTickets_result(this);
1553
    }
1554
 
1555
    @Deprecated
1556
    public getTickets_result clone() {
1557
      return new getTickets_result(this);
1558
    }
1559
 
1560
    public int getSuccessSize() {
1561
      return (this.success == null) ? 0 : this.success.size();
1562
    }
1563
 
1564
    public java.util.Iterator<Ticket> getSuccessIterator() {
1565
      return (this.success == null) ? null : this.success.iterator();
1566
    }
1567
 
1568
    public void addToSuccess(Ticket elem) {
1569
      if (this.success == null) {
1570
        this.success = new ArrayList<Ticket>();
1571
      }
1572
      this.success.add(elem);
1573
    }
1574
 
1575
    public List<Ticket> getSuccess() {
1576
      return this.success;
1577
    }
1578
 
1579
    public getTickets_result setSuccess(List<Ticket> success) {
1580
      this.success = success;
1581
      return this;
1582
    }
1583
 
1584
    public void unsetSuccess() {
1585
      this.success = null;
1586
    }
1587
 
1588
    /** Returns true if field success is set (has been asigned a value) and false otherwise */
1589
    public boolean isSetSuccess() {
1590
      return this.success != null;
1591
    }
1592
 
1593
    public void setSuccessIsSet(boolean value) {
1594
      if (!value) {
1595
        this.success = null;
1596
      }
1597
    }
1598
 
1599
    public void setFieldValue(_Fields field, Object value) {
1600
      switch (field) {
1601
      case SUCCESS:
1602
        if (value == null) {
1603
          unsetSuccess();
1604
        } else {
1605
          setSuccess((List<Ticket>)value);
1606
        }
1607
        break;
1608
 
1609
      }
1610
    }
1611
 
1612
    public void setFieldValue(int fieldID, Object value) {
1613
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
1614
    }
1615
 
1616
    public Object getFieldValue(_Fields field) {
1617
      switch (field) {
1618
      case SUCCESS:
1619
        return getSuccess();
1620
 
1621
      }
1622
      throw new IllegalStateException();
1623
    }
1624
 
1625
    public Object getFieldValue(int fieldId) {
1626
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
1627
    }
1628
 
1629
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
1630
    public boolean isSet(_Fields field) {
1631
      switch (field) {
1632
      case SUCCESS:
1633
        return isSetSuccess();
1634
      }
1635
      throw new IllegalStateException();
1636
    }
1637
 
1638
    public boolean isSet(int fieldID) {
1639
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
1640
    }
1641
 
1642
    @Override
1643
    public boolean equals(Object that) {
1644
      if (that == null)
1645
        return false;
1646
      if (that instanceof getTickets_result)
1647
        return this.equals((getTickets_result)that);
1648
      return false;
1649
    }
1650
 
1651
    public boolean equals(getTickets_result that) {
1652
      if (that == null)
1653
        return false;
1654
 
1655
      boolean this_present_success = true && this.isSetSuccess();
1656
      boolean that_present_success = true && that.isSetSuccess();
1657
      if (this_present_success || that_present_success) {
1658
        if (!(this_present_success && that_present_success))
1659
          return false;
1660
        if (!this.success.equals(that.success))
1661
          return false;
1662
      }
1663
 
1664
      return true;
1665
    }
1666
 
1667
    @Override
1668
    public int hashCode() {
1669
      return 0;
1670
    }
1671
 
1672
    public int compareTo(getTickets_result other) {
1673
      if (!getClass().equals(other.getClass())) {
1674
        return getClass().getName().compareTo(other.getClass().getName());
1675
      }
1676
 
1677
      int lastComparison = 0;
1678
      getTickets_result typedOther = (getTickets_result)other;
1679
 
1680
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(isSetSuccess());
1681
      if (lastComparison != 0) {
1682
        return lastComparison;
1683
      }
1684
      lastComparison = TBaseHelper.compareTo(success, typedOther.success);
1685
      if (lastComparison != 0) {
1686
        return lastComparison;
1687
      }
1688
      return 0;
1689
    }
1690
 
1691
    public void read(TProtocol iprot) throws TException {
1692
      TField field;
1693
      iprot.readStructBegin();
1694
      while (true)
1695
      {
1696
        field = iprot.readFieldBegin();
1697
        if (field.type == TType.STOP) { 
1698
          break;
1699
        }
1700
        _Fields fieldId = _Fields.findByThriftId(field.id);
1701
        if (fieldId == null) {
1702
          TProtocolUtil.skip(iprot, field.type);
1703
        } else {
1704
          switch (fieldId) {
1705
            case SUCCESS:
1706
              if (field.type == TType.LIST) {
1707
                {
1708
                  TList _list0 = iprot.readListBegin();
1709
                  this.success = new ArrayList<Ticket>(_list0.size);
1710
                  for (int _i1 = 0; _i1 < _list0.size; ++_i1)
1711
                  {
1712
                    Ticket _elem2;
1713
                    _elem2 = new Ticket();
1714
                    _elem2.read(iprot);
1715
                    this.success.add(_elem2);
1716
                  }
1717
                  iprot.readListEnd();
1718
                }
1719
              } else { 
1720
                TProtocolUtil.skip(iprot, field.type);
1721
              }
1722
              break;
1723
          }
1724
          iprot.readFieldEnd();
1725
        }
1726
      }
1727
      iprot.readStructEnd();
1728
      validate();
1729
    }
1730
 
1731
    public void write(TProtocol oprot) throws TException {
1732
      oprot.writeStructBegin(STRUCT_DESC);
1733
 
1734
      if (this.isSetSuccess()) {
1735
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
1736
        {
1737
          oprot.writeListBegin(new TList(TType.STRUCT, this.success.size()));
1738
          for (Ticket _iter3 : this.success)
1739
          {
1740
            _iter3.write(oprot);
1741
          }
1742
          oprot.writeListEnd();
1743
        }
1744
        oprot.writeFieldEnd();
1745
      }
1746
      oprot.writeFieldStop();
1747
      oprot.writeStructEnd();
1748
    }
1749
 
1750
    @Override
1751
    public String toString() {
1752
      StringBuilder sb = new StringBuilder("getTickets_result(");
1753
      boolean first = true;
1754
 
1755
      sb.append("success:");
1756
      if (this.success == null) {
1757
        sb.append("null");
1758
      } else {
1759
        sb.append(this.success);
1760
      }
1761
      first = false;
1762
      sb.append(")");
1763
      return sb.toString();
1764
    }
1765
 
1766
    public void validate() throws TException {
1767
      // check for required fields
1768
    }
1769
 
1770
  }
1771
 
3087 mandeep.dh 1772
  public static class getAssignedTickets_args implements TBase<getAssignedTickets_args._Fields>, java.io.Serializable, Cloneable, Comparable<getAssignedTickets_args>   {
1773
    private static final TStruct STRUCT_DESC = new TStruct("getAssignedTickets_args");
1774
 
1775
    private static final TField AGENT_ID_FIELD_DESC = new TField("agentId", TType.I64, (short)1);
1776
 
1777
    private long agentId;
1778
 
1779
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
1780
    public enum _Fields implements TFieldIdEnum {
1781
      AGENT_ID((short)1, "agentId");
1782
 
1783
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
1784
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
1785
 
1786
      static {
1787
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
1788
          byId.put((int)field._thriftId, field);
1789
          byName.put(field.getFieldName(), field);
1790
        }
1791
      }
1792
 
1793
      /**
1794
       * Find the _Fields constant that matches fieldId, or null if its not found.
1795
       */
1796
      public static _Fields findByThriftId(int fieldId) {
1797
        return byId.get(fieldId);
1798
      }
1799
 
1800
      /**
1801
       * Find the _Fields constant that matches fieldId, throwing an exception
1802
       * if it is not found.
1803
       */
1804
      public static _Fields findByThriftIdOrThrow(int fieldId) {
1805
        _Fields fields = findByThriftId(fieldId);
1806
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
1807
        return fields;
1808
      }
1809
 
1810
      /**
1811
       * Find the _Fields constant that matches name, or null if its not found.
1812
       */
1813
      public static _Fields findByName(String name) {
1814
        return byName.get(name);
1815
      }
1816
 
1817
      private final short _thriftId;
1818
      private final String _fieldName;
1819
 
1820
      _Fields(short thriftId, String fieldName) {
1821
        _thriftId = thriftId;
1822
        _fieldName = fieldName;
1823
      }
1824
 
1825
      public short getThriftFieldId() {
1826
        return _thriftId;
1827
      }
1828
 
1829
      public String getFieldName() {
1830
        return _fieldName;
1831
      }
1832
    }
1833
 
1834
    // isset id assignments
1835
    private static final int __AGENTID_ISSET_ID = 0;
1836
    private BitSet __isset_bit_vector = new BitSet(1);
1837
 
1838
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
1839
      put(_Fields.AGENT_ID, new FieldMetaData("agentId", TFieldRequirementType.DEFAULT, 
1840
          new FieldValueMetaData(TType.I64)));
1841
    }});
1842
 
1843
    static {
1844
      FieldMetaData.addStructMetaDataMap(getAssignedTickets_args.class, metaDataMap);
1845
    }
1846
 
1847
    public getAssignedTickets_args() {
1848
    }
1849
 
1850
    public getAssignedTickets_args(
1851
      long agentId)
1852
    {
1853
      this();
1854
      this.agentId = agentId;
1855
      setAgentIdIsSet(true);
1856
    }
1857
 
1858
    /**
1859
     * Performs a deep copy on <i>other</i>.
1860
     */
1861
    public getAssignedTickets_args(getAssignedTickets_args other) {
1862
      __isset_bit_vector.clear();
1863
      __isset_bit_vector.or(other.__isset_bit_vector);
1864
      this.agentId = other.agentId;
1865
    }
1866
 
1867
    public getAssignedTickets_args deepCopy() {
1868
      return new getAssignedTickets_args(this);
1869
    }
1870
 
1871
    @Deprecated
1872
    public getAssignedTickets_args clone() {
1873
      return new getAssignedTickets_args(this);
1874
    }
1875
 
1876
    public long getAgentId() {
1877
      return this.agentId;
1878
    }
1879
 
1880
    public getAssignedTickets_args setAgentId(long agentId) {
1881
      this.agentId = agentId;
1882
      setAgentIdIsSet(true);
1883
      return this;
1884
    }
1885
 
1886
    public void unsetAgentId() {
1887
      __isset_bit_vector.clear(__AGENTID_ISSET_ID);
1888
    }
1889
 
1890
    /** Returns true if field agentId is set (has been asigned a value) and false otherwise */
1891
    public boolean isSetAgentId() {
1892
      return __isset_bit_vector.get(__AGENTID_ISSET_ID);
1893
    }
1894
 
1895
    public void setAgentIdIsSet(boolean value) {
1896
      __isset_bit_vector.set(__AGENTID_ISSET_ID, value);
1897
    }
1898
 
1899
    public void setFieldValue(_Fields field, Object value) {
1900
      switch (field) {
1901
      case AGENT_ID:
1902
        if (value == null) {
1903
          unsetAgentId();
1904
        } else {
1905
          setAgentId((Long)value);
1906
        }
1907
        break;
1908
 
1909
      }
1910
    }
1911
 
1912
    public void setFieldValue(int fieldID, Object value) {
1913
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
1914
    }
1915
 
1916
    public Object getFieldValue(_Fields field) {
1917
      switch (field) {
1918
      case AGENT_ID:
1919
        return new Long(getAgentId());
1920
 
1921
      }
1922
      throw new IllegalStateException();
1923
    }
1924
 
1925
    public Object getFieldValue(int fieldId) {
1926
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
1927
    }
1928
 
1929
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
1930
    public boolean isSet(_Fields field) {
1931
      switch (field) {
1932
      case AGENT_ID:
1933
        return isSetAgentId();
1934
      }
1935
      throw new IllegalStateException();
1936
    }
1937
 
1938
    public boolean isSet(int fieldID) {
1939
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
1940
    }
1941
 
1942
    @Override
1943
    public boolean equals(Object that) {
1944
      if (that == null)
1945
        return false;
1946
      if (that instanceof getAssignedTickets_args)
1947
        return this.equals((getAssignedTickets_args)that);
1948
      return false;
1949
    }
1950
 
1951
    public boolean equals(getAssignedTickets_args that) {
1952
      if (that == null)
1953
        return false;
1954
 
1955
      boolean this_present_agentId = true;
1956
      boolean that_present_agentId = true;
1957
      if (this_present_agentId || that_present_agentId) {
1958
        if (!(this_present_agentId && that_present_agentId))
1959
          return false;
1960
        if (this.agentId != that.agentId)
1961
          return false;
1962
      }
1963
 
1964
      return true;
1965
    }
1966
 
1967
    @Override
1968
    public int hashCode() {
1969
      return 0;
1970
    }
1971
 
1972
    public int compareTo(getAssignedTickets_args other) {
1973
      if (!getClass().equals(other.getClass())) {
1974
        return getClass().getName().compareTo(other.getClass().getName());
1975
      }
1976
 
1977
      int lastComparison = 0;
1978
      getAssignedTickets_args typedOther = (getAssignedTickets_args)other;
1979
 
1980
      lastComparison = Boolean.valueOf(isSetAgentId()).compareTo(isSetAgentId());
1981
      if (lastComparison != 0) {
1982
        return lastComparison;
1983
      }
1984
      lastComparison = TBaseHelper.compareTo(agentId, typedOther.agentId);
1985
      if (lastComparison != 0) {
1986
        return lastComparison;
1987
      }
1988
      return 0;
1989
    }
1990
 
1991
    public void read(TProtocol iprot) throws TException {
1992
      TField field;
1993
      iprot.readStructBegin();
1994
      while (true)
1995
      {
1996
        field = iprot.readFieldBegin();
1997
        if (field.type == TType.STOP) { 
1998
          break;
1999
        }
2000
        _Fields fieldId = _Fields.findByThriftId(field.id);
2001
        if (fieldId == null) {
2002
          TProtocolUtil.skip(iprot, field.type);
2003
        } else {
2004
          switch (fieldId) {
2005
            case AGENT_ID:
2006
              if (field.type == TType.I64) {
2007
                this.agentId = iprot.readI64();
2008
                setAgentIdIsSet(true);
2009
              } else { 
2010
                TProtocolUtil.skip(iprot, field.type);
2011
              }
2012
              break;
2013
          }
2014
          iprot.readFieldEnd();
2015
        }
2016
      }
2017
      iprot.readStructEnd();
2018
      validate();
2019
    }
2020
 
2021
    public void write(TProtocol oprot) throws TException {
2022
      validate();
2023
 
2024
      oprot.writeStructBegin(STRUCT_DESC);
2025
      oprot.writeFieldBegin(AGENT_ID_FIELD_DESC);
2026
      oprot.writeI64(this.agentId);
2027
      oprot.writeFieldEnd();
2028
      oprot.writeFieldStop();
2029
      oprot.writeStructEnd();
2030
    }
2031
 
2032
    @Override
2033
    public String toString() {
2034
      StringBuilder sb = new StringBuilder("getAssignedTickets_args(");
2035
      boolean first = true;
2036
 
2037
      sb.append("agentId:");
2038
      sb.append(this.agentId);
2039
      first = false;
2040
      sb.append(")");
2041
      return sb.toString();
2042
    }
2043
 
2044
    public void validate() throws TException {
2045
      // check for required fields
2046
    }
2047
 
2048
  }
2049
 
2050
  public static class getAssignedTickets_result implements TBase<getAssignedTickets_result._Fields>, java.io.Serializable, Cloneable, Comparable<getAssignedTickets_result>   {
2051
    private static final TStruct STRUCT_DESC = new TStruct("getAssignedTickets_result");
2052
 
2053
    private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.LIST, (short)0);
2054
 
2055
    private List<Ticket> success;
2056
 
2057
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
2058
    public enum _Fields implements TFieldIdEnum {
2059
      SUCCESS((short)0, "success");
2060
 
2061
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
2062
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
2063
 
2064
      static {
2065
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
2066
          byId.put((int)field._thriftId, field);
2067
          byName.put(field.getFieldName(), field);
2068
        }
2069
      }
2070
 
2071
      /**
2072
       * Find the _Fields constant that matches fieldId, or null if its not found.
2073
       */
2074
      public static _Fields findByThriftId(int fieldId) {
2075
        return byId.get(fieldId);
2076
      }
2077
 
2078
      /**
2079
       * Find the _Fields constant that matches fieldId, throwing an exception
2080
       * if it is not found.
2081
       */
2082
      public static _Fields findByThriftIdOrThrow(int fieldId) {
2083
        _Fields fields = findByThriftId(fieldId);
2084
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
2085
        return fields;
2086
      }
2087
 
2088
      /**
2089
       * Find the _Fields constant that matches name, or null if its not found.
2090
       */
2091
      public static _Fields findByName(String name) {
2092
        return byName.get(name);
2093
      }
2094
 
2095
      private final short _thriftId;
2096
      private final String _fieldName;
2097
 
2098
      _Fields(short thriftId, String fieldName) {
2099
        _thriftId = thriftId;
2100
        _fieldName = fieldName;
2101
      }
2102
 
2103
      public short getThriftFieldId() {
2104
        return _thriftId;
2105
      }
2106
 
2107
      public String getFieldName() {
2108
        return _fieldName;
2109
      }
2110
    }
2111
 
2112
    // isset id assignments
2113
 
2114
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
2115
      put(_Fields.SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, 
2116
          new ListMetaData(TType.LIST, 
2117
              new StructMetaData(TType.STRUCT, Ticket.class))));
2118
    }});
2119
 
2120
    static {
2121
      FieldMetaData.addStructMetaDataMap(getAssignedTickets_result.class, metaDataMap);
2122
    }
2123
 
2124
    public getAssignedTickets_result() {
2125
    }
2126
 
2127
    public getAssignedTickets_result(
2128
      List<Ticket> success)
2129
    {
2130
      this();
2131
      this.success = success;
2132
    }
2133
 
2134
    /**
2135
     * Performs a deep copy on <i>other</i>.
2136
     */
2137
    public getAssignedTickets_result(getAssignedTickets_result other) {
2138
      if (other.isSetSuccess()) {
2139
        List<Ticket> __this__success = new ArrayList<Ticket>();
2140
        for (Ticket other_element : other.success) {
2141
          __this__success.add(new Ticket(other_element));
2142
        }
2143
        this.success = __this__success;
2144
      }
2145
    }
2146
 
2147
    public getAssignedTickets_result deepCopy() {
2148
      return new getAssignedTickets_result(this);
2149
    }
2150
 
2151
    @Deprecated
2152
    public getAssignedTickets_result clone() {
2153
      return new getAssignedTickets_result(this);
2154
    }
2155
 
2156
    public int getSuccessSize() {
2157
      return (this.success == null) ? 0 : this.success.size();
2158
    }
2159
 
2160
    public java.util.Iterator<Ticket> getSuccessIterator() {
2161
      return (this.success == null) ? null : this.success.iterator();
2162
    }
2163
 
2164
    public void addToSuccess(Ticket elem) {
2165
      if (this.success == null) {
2166
        this.success = new ArrayList<Ticket>();
2167
      }
2168
      this.success.add(elem);
2169
    }
2170
 
2171
    public List<Ticket> getSuccess() {
2172
      return this.success;
2173
    }
2174
 
2175
    public getAssignedTickets_result setSuccess(List<Ticket> success) {
2176
      this.success = success;
2177
      return this;
2178
    }
2179
 
2180
    public void unsetSuccess() {
2181
      this.success = null;
2182
    }
2183
 
2184
    /** Returns true if field success is set (has been asigned a value) and false otherwise */
2185
    public boolean isSetSuccess() {
2186
      return this.success != null;
2187
    }
2188
 
2189
    public void setSuccessIsSet(boolean value) {
2190
      if (!value) {
2191
        this.success = null;
2192
      }
2193
    }
2194
 
2195
    public void setFieldValue(_Fields field, Object value) {
2196
      switch (field) {
2197
      case SUCCESS:
2198
        if (value == null) {
2199
          unsetSuccess();
2200
        } else {
2201
          setSuccess((List<Ticket>)value);
2202
        }
2203
        break;
2204
 
2205
      }
2206
    }
2207
 
2208
    public void setFieldValue(int fieldID, Object value) {
2209
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
2210
    }
2211
 
2212
    public Object getFieldValue(_Fields field) {
2213
      switch (field) {
2214
      case SUCCESS:
2215
        return getSuccess();
2216
 
2217
      }
2218
      throw new IllegalStateException();
2219
    }
2220
 
2221
    public Object getFieldValue(int fieldId) {
2222
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
2223
    }
2224
 
2225
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
2226
    public boolean isSet(_Fields field) {
2227
      switch (field) {
2228
      case SUCCESS:
2229
        return isSetSuccess();
2230
      }
2231
      throw new IllegalStateException();
2232
    }
2233
 
2234
    public boolean isSet(int fieldID) {
2235
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
2236
    }
2237
 
2238
    @Override
2239
    public boolean equals(Object that) {
2240
      if (that == null)
2241
        return false;
2242
      if (that instanceof getAssignedTickets_result)
2243
        return this.equals((getAssignedTickets_result)that);
2244
      return false;
2245
    }
2246
 
2247
    public boolean equals(getAssignedTickets_result that) {
2248
      if (that == null)
2249
        return false;
2250
 
2251
      boolean this_present_success = true && this.isSetSuccess();
2252
      boolean that_present_success = true && that.isSetSuccess();
2253
      if (this_present_success || that_present_success) {
2254
        if (!(this_present_success && that_present_success))
2255
          return false;
2256
        if (!this.success.equals(that.success))
2257
          return false;
2258
      }
2259
 
2260
      return true;
2261
    }
2262
 
2263
    @Override
2264
    public int hashCode() {
2265
      return 0;
2266
    }
2267
 
2268
    public int compareTo(getAssignedTickets_result other) {
2269
      if (!getClass().equals(other.getClass())) {
2270
        return getClass().getName().compareTo(other.getClass().getName());
2271
      }
2272
 
2273
      int lastComparison = 0;
2274
      getAssignedTickets_result typedOther = (getAssignedTickets_result)other;
2275
 
2276
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(isSetSuccess());
2277
      if (lastComparison != 0) {
2278
        return lastComparison;
2279
      }
2280
      lastComparison = TBaseHelper.compareTo(success, typedOther.success);
2281
      if (lastComparison != 0) {
2282
        return lastComparison;
2283
      }
2284
      return 0;
2285
    }
2286
 
2287
    public void read(TProtocol iprot) throws TException {
2288
      TField field;
2289
      iprot.readStructBegin();
2290
      while (true)
2291
      {
2292
        field = iprot.readFieldBegin();
2293
        if (field.type == TType.STOP) { 
2294
          break;
2295
        }
2296
        _Fields fieldId = _Fields.findByThriftId(field.id);
2297
        if (fieldId == null) {
2298
          TProtocolUtil.skip(iprot, field.type);
2299
        } else {
2300
          switch (fieldId) {
2301
            case SUCCESS:
2302
              if (field.type == TType.LIST) {
2303
                {
2304
                  TList _list4 = iprot.readListBegin();
2305
                  this.success = new ArrayList<Ticket>(_list4.size);
2306
                  for (int _i5 = 0; _i5 < _list4.size; ++_i5)
2307
                  {
2308
                    Ticket _elem6;
2309
                    _elem6 = new Ticket();
2310
                    _elem6.read(iprot);
2311
                    this.success.add(_elem6);
2312
                  }
2313
                  iprot.readListEnd();
2314
                }
2315
              } else { 
2316
                TProtocolUtil.skip(iprot, field.type);
2317
              }
2318
              break;
2319
          }
2320
          iprot.readFieldEnd();
2321
        }
2322
      }
2323
      iprot.readStructEnd();
2324
      validate();
2325
    }
2326
 
2327
    public void write(TProtocol oprot) throws TException {
2328
      oprot.writeStructBegin(STRUCT_DESC);
2329
 
2330
      if (this.isSetSuccess()) {
2331
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
2332
        {
2333
          oprot.writeListBegin(new TList(TType.STRUCT, this.success.size()));
2334
          for (Ticket _iter7 : this.success)
2335
          {
2336
            _iter7.write(oprot);
2337
          }
2338
          oprot.writeListEnd();
2339
        }
2340
        oprot.writeFieldEnd();
2341
      }
2342
      oprot.writeFieldStop();
2343
      oprot.writeStructEnd();
2344
    }
2345
 
2346
    @Override
2347
    public String toString() {
2348
      StringBuilder sb = new StringBuilder("getAssignedTickets_result(");
2349
      boolean first = true;
2350
 
2351
      sb.append("success:");
2352
      if (this.success == null) {
2353
        sb.append("null");
2354
      } else {
2355
        sb.append(this.success);
2356
      }
2357
      first = false;
2358
      sb.append(")");
2359
      return sb.toString();
2360
    }
2361
 
2362
    public void validate() throws TException {
2363
      // check for required fields
2364
    }
2365
 
2366
  }
2367
 
3137 mandeep.dh 2368
  public static class getUnassignedTickets_args implements TBase<getUnassignedTickets_args._Fields>, java.io.Serializable, Cloneable, Comparable<getUnassignedTickets_args>   {
2369
    private static final TStruct STRUCT_DESC = new TStruct("getUnassignedTickets_args");
3087 mandeep.dh 2370
 
2371
 
2372
 
2373
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
2374
    public enum _Fields implements TFieldIdEnum {
2375
;
2376
 
2377
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
2378
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
2379
 
2380
      static {
2381
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
2382
          byId.put((int)field._thriftId, field);
2383
          byName.put(field.getFieldName(), field);
2384
        }
2385
      }
2386
 
2387
      /**
2388
       * Find the _Fields constant that matches fieldId, or null if its not found.
2389
       */
2390
      public static _Fields findByThriftId(int fieldId) {
2391
        return byId.get(fieldId);
2392
      }
2393
 
2394
      /**
2395
       * Find the _Fields constant that matches fieldId, throwing an exception
2396
       * if it is not found.
2397
       */
2398
      public static _Fields findByThriftIdOrThrow(int fieldId) {
2399
        _Fields fields = findByThriftId(fieldId);
2400
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
2401
        return fields;
2402
      }
2403
 
2404
      /**
2405
       * Find the _Fields constant that matches name, or null if its not found.
2406
       */
2407
      public static _Fields findByName(String name) {
2408
        return byName.get(name);
2409
      }
2410
 
2411
      private final short _thriftId;
2412
      private final String _fieldName;
2413
 
2414
      _Fields(short thriftId, String fieldName) {
2415
        _thriftId = thriftId;
2416
        _fieldName = fieldName;
2417
      }
2418
 
2419
      public short getThriftFieldId() {
2420
        return _thriftId;
2421
      }
2422
 
2423
      public String getFieldName() {
2424
        return _fieldName;
2425
      }
2426
    }
2427
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
2428
    }});
2429
 
2430
    static {
3137 mandeep.dh 2431
      FieldMetaData.addStructMetaDataMap(getUnassignedTickets_args.class, metaDataMap);
3087 mandeep.dh 2432
    }
2433
 
3137 mandeep.dh 2434
    public getUnassignedTickets_args() {
3087 mandeep.dh 2435
    }
2436
 
2437
    /**
2438
     * Performs a deep copy on <i>other</i>.
2439
     */
3137 mandeep.dh 2440
    public getUnassignedTickets_args(getUnassignedTickets_args other) {
3087 mandeep.dh 2441
    }
2442
 
3137 mandeep.dh 2443
    public getUnassignedTickets_args deepCopy() {
2444
      return new getUnassignedTickets_args(this);
3087 mandeep.dh 2445
    }
2446
 
2447
    @Deprecated
3137 mandeep.dh 2448
    public getUnassignedTickets_args clone() {
2449
      return new getUnassignedTickets_args(this);
3087 mandeep.dh 2450
    }
2451
 
2452
    public void setFieldValue(_Fields field, Object value) {
2453
      switch (field) {
2454
      }
2455
    }
2456
 
2457
    public void setFieldValue(int fieldID, Object value) {
2458
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
2459
    }
2460
 
2461
    public Object getFieldValue(_Fields field) {
2462
      switch (field) {
2463
      }
2464
      throw new IllegalStateException();
2465
    }
2466
 
2467
    public Object getFieldValue(int fieldId) {
2468
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
2469
    }
2470
 
2471
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
2472
    public boolean isSet(_Fields field) {
2473
      switch (field) {
2474
      }
2475
      throw new IllegalStateException();
2476
    }
2477
 
2478
    public boolean isSet(int fieldID) {
2479
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
2480
    }
2481
 
2482
    @Override
2483
    public boolean equals(Object that) {
2484
      if (that == null)
2485
        return false;
3137 mandeep.dh 2486
      if (that instanceof getUnassignedTickets_args)
2487
        return this.equals((getUnassignedTickets_args)that);
3087 mandeep.dh 2488
      return false;
2489
    }
2490
 
3137 mandeep.dh 2491
    public boolean equals(getUnassignedTickets_args that) {
3087 mandeep.dh 2492
      if (that == null)
2493
        return false;
2494
 
2495
      return true;
2496
    }
2497
 
2498
    @Override
2499
    public int hashCode() {
2500
      return 0;
2501
    }
2502
 
3137 mandeep.dh 2503
    public int compareTo(getUnassignedTickets_args other) {
3087 mandeep.dh 2504
      if (!getClass().equals(other.getClass())) {
2505
        return getClass().getName().compareTo(other.getClass().getName());
2506
      }
2507
 
2508
      int lastComparison = 0;
3137 mandeep.dh 2509
      getUnassignedTickets_args typedOther = (getUnassignedTickets_args)other;
3087 mandeep.dh 2510
 
2511
      return 0;
2512
    }
2513
 
2514
    public void read(TProtocol iprot) throws TException {
2515
      TField field;
2516
      iprot.readStructBegin();
2517
      while (true)
2518
      {
2519
        field = iprot.readFieldBegin();
2520
        if (field.type == TType.STOP) { 
2521
          break;
2522
        }
2523
        _Fields fieldId = _Fields.findByThriftId(field.id);
2524
        if (fieldId == null) {
2525
          TProtocolUtil.skip(iprot, field.type);
2526
        } else {
2527
          switch (fieldId) {
2528
          }
2529
          iprot.readFieldEnd();
2530
        }
2531
      }
2532
      iprot.readStructEnd();
2533
      validate();
2534
    }
2535
 
2536
    public void write(TProtocol oprot) throws TException {
2537
      validate();
2538
 
2539
      oprot.writeStructBegin(STRUCT_DESC);
2540
      oprot.writeFieldStop();
2541
      oprot.writeStructEnd();
2542
    }
2543
 
2544
    @Override
2545
    public String toString() {
3137 mandeep.dh 2546
      StringBuilder sb = new StringBuilder("getUnassignedTickets_args(");
3087 mandeep.dh 2547
      boolean first = true;
2548
 
2549
      sb.append(")");
2550
      return sb.toString();
2551
    }
2552
 
2553
    public void validate() throws TException {
2554
      // check for required fields
2555
    }
2556
 
2557
  }
2558
 
3137 mandeep.dh 2559
  public static class getUnassignedTickets_result implements TBase<getUnassignedTickets_result._Fields>, java.io.Serializable, Cloneable, Comparable<getUnassignedTickets_result>   {
2560
    private static final TStruct STRUCT_DESC = new TStruct("getUnassignedTickets_result");
3087 mandeep.dh 2561
 
2562
    private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.LIST, (short)0);
2563
 
2564
    private List<Ticket> success;
2565
 
2566
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
2567
    public enum _Fields implements TFieldIdEnum {
2568
      SUCCESS((short)0, "success");
2569
 
2570
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
2571
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
2572
 
2573
      static {
2574
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
2575
          byId.put((int)field._thriftId, field);
2576
          byName.put(field.getFieldName(), field);
2577
        }
2578
      }
2579
 
2580
      /**
2581
       * Find the _Fields constant that matches fieldId, or null if its not found.
2582
       */
2583
      public static _Fields findByThriftId(int fieldId) {
2584
        return byId.get(fieldId);
2585
      }
2586
 
2587
      /**
2588
       * Find the _Fields constant that matches fieldId, throwing an exception
2589
       * if it is not found.
2590
       */
2591
      public static _Fields findByThriftIdOrThrow(int fieldId) {
2592
        _Fields fields = findByThriftId(fieldId);
2593
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
2594
        return fields;
2595
      }
2596
 
2597
      /**
2598
       * Find the _Fields constant that matches name, or null if its not found.
2599
       */
2600
      public static _Fields findByName(String name) {
2601
        return byName.get(name);
2602
      }
2603
 
2604
      private final short _thriftId;
2605
      private final String _fieldName;
2606
 
2607
      _Fields(short thriftId, String fieldName) {
2608
        _thriftId = thriftId;
2609
        _fieldName = fieldName;
2610
      }
2611
 
2612
      public short getThriftFieldId() {
2613
        return _thriftId;
2614
      }
2615
 
2616
      public String getFieldName() {
2617
        return _fieldName;
2618
      }
2619
    }
2620
 
2621
    // isset id assignments
2622
 
2623
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
2624
      put(_Fields.SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, 
2625
          new ListMetaData(TType.LIST, 
2626
              new StructMetaData(TType.STRUCT, Ticket.class))));
2627
    }});
2628
 
2629
    static {
3137 mandeep.dh 2630
      FieldMetaData.addStructMetaDataMap(getUnassignedTickets_result.class, metaDataMap);
3087 mandeep.dh 2631
    }
2632
 
3137 mandeep.dh 2633
    public getUnassignedTickets_result() {
3087 mandeep.dh 2634
    }
2635
 
3137 mandeep.dh 2636
    public getUnassignedTickets_result(
3087 mandeep.dh 2637
      List<Ticket> success)
2638
    {
2639
      this();
2640
      this.success = success;
2641
    }
2642
 
2643
    /**
2644
     * Performs a deep copy on <i>other</i>.
2645
     */
3137 mandeep.dh 2646
    public getUnassignedTickets_result(getUnassignedTickets_result other) {
3087 mandeep.dh 2647
      if (other.isSetSuccess()) {
2648
        List<Ticket> __this__success = new ArrayList<Ticket>();
2649
        for (Ticket other_element : other.success) {
2650
          __this__success.add(new Ticket(other_element));
2651
        }
2652
        this.success = __this__success;
2653
      }
2654
    }
2655
 
3137 mandeep.dh 2656
    public getUnassignedTickets_result deepCopy() {
2657
      return new getUnassignedTickets_result(this);
3087 mandeep.dh 2658
    }
2659
 
2660
    @Deprecated
3137 mandeep.dh 2661
    public getUnassignedTickets_result clone() {
2662
      return new getUnassignedTickets_result(this);
3087 mandeep.dh 2663
    }
2664
 
2665
    public int getSuccessSize() {
2666
      return (this.success == null) ? 0 : this.success.size();
2667
    }
2668
 
2669
    public java.util.Iterator<Ticket> getSuccessIterator() {
2670
      return (this.success == null) ? null : this.success.iterator();
2671
    }
2672
 
2673
    public void addToSuccess(Ticket elem) {
2674
      if (this.success == null) {
2675
        this.success = new ArrayList<Ticket>();
2676
      }
2677
      this.success.add(elem);
2678
    }
2679
 
2680
    public List<Ticket> getSuccess() {
2681
      return this.success;
2682
    }
2683
 
3137 mandeep.dh 2684
    public getUnassignedTickets_result setSuccess(List<Ticket> success) {
3087 mandeep.dh 2685
      this.success = success;
2686
      return this;
2687
    }
2688
 
2689
    public void unsetSuccess() {
2690
      this.success = null;
2691
    }
2692
 
2693
    /** Returns true if field success is set (has been asigned a value) and false otherwise */
2694
    public boolean isSetSuccess() {
2695
      return this.success != null;
2696
    }
2697
 
2698
    public void setSuccessIsSet(boolean value) {
2699
      if (!value) {
2700
        this.success = null;
2701
      }
2702
    }
2703
 
2704
    public void setFieldValue(_Fields field, Object value) {
2705
      switch (field) {
2706
      case SUCCESS:
2707
        if (value == null) {
2708
          unsetSuccess();
2709
        } else {
2710
          setSuccess((List<Ticket>)value);
2711
        }
2712
        break;
2713
 
2714
      }
2715
    }
2716
 
2717
    public void setFieldValue(int fieldID, Object value) {
2718
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
2719
    }
2720
 
2721
    public Object getFieldValue(_Fields field) {
2722
      switch (field) {
2723
      case SUCCESS:
2724
        return getSuccess();
2725
 
2726
      }
2727
      throw new IllegalStateException();
2728
    }
2729
 
2730
    public Object getFieldValue(int fieldId) {
2731
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
2732
    }
2733
 
2734
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
2735
    public boolean isSet(_Fields field) {
2736
      switch (field) {
2737
      case SUCCESS:
2738
        return isSetSuccess();
2739
      }
2740
      throw new IllegalStateException();
2741
    }
2742
 
2743
    public boolean isSet(int fieldID) {
2744
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
2745
    }
2746
 
2747
    @Override
2748
    public boolean equals(Object that) {
2749
      if (that == null)
2750
        return false;
3137 mandeep.dh 2751
      if (that instanceof getUnassignedTickets_result)
2752
        return this.equals((getUnassignedTickets_result)that);
3087 mandeep.dh 2753
      return false;
2754
    }
2755
 
3137 mandeep.dh 2756
    public boolean equals(getUnassignedTickets_result that) {
3087 mandeep.dh 2757
      if (that == null)
2758
        return false;
2759
 
2760
      boolean this_present_success = true && this.isSetSuccess();
2761
      boolean that_present_success = true && that.isSetSuccess();
2762
      if (this_present_success || that_present_success) {
2763
        if (!(this_present_success && that_present_success))
2764
          return false;
2765
        if (!this.success.equals(that.success))
2766
          return false;
2767
      }
2768
 
2769
      return true;
2770
    }
2771
 
2772
    @Override
2773
    public int hashCode() {
2774
      return 0;
2775
    }
2776
 
3137 mandeep.dh 2777
    public int compareTo(getUnassignedTickets_result other) {
3087 mandeep.dh 2778
      if (!getClass().equals(other.getClass())) {
2779
        return getClass().getName().compareTo(other.getClass().getName());
2780
      }
2781
 
2782
      int lastComparison = 0;
3137 mandeep.dh 2783
      getUnassignedTickets_result typedOther = (getUnassignedTickets_result)other;
3087 mandeep.dh 2784
 
2785
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(isSetSuccess());
2786
      if (lastComparison != 0) {
2787
        return lastComparison;
2788
      }
2789
      lastComparison = TBaseHelper.compareTo(success, typedOther.success);
2790
      if (lastComparison != 0) {
2791
        return lastComparison;
2792
      }
2793
      return 0;
2794
    }
2795
 
2796
    public void read(TProtocol iprot) throws TException {
2797
      TField field;
2798
      iprot.readStructBegin();
2799
      while (true)
2800
      {
2801
        field = iprot.readFieldBegin();
2802
        if (field.type == TType.STOP) { 
2803
          break;
2804
        }
2805
        _Fields fieldId = _Fields.findByThriftId(field.id);
2806
        if (fieldId == null) {
2807
          TProtocolUtil.skip(iprot, field.type);
2808
        } else {
2809
          switch (fieldId) {
2810
            case SUCCESS:
2811
              if (field.type == TType.LIST) {
2812
                {
2813
                  TList _list8 = iprot.readListBegin();
2814
                  this.success = new ArrayList<Ticket>(_list8.size);
2815
                  for (int _i9 = 0; _i9 < _list8.size; ++_i9)
2816
                  {
2817
                    Ticket _elem10;
2818
                    _elem10 = new Ticket();
2819
                    _elem10.read(iprot);
2820
                    this.success.add(_elem10);
2821
                  }
2822
                  iprot.readListEnd();
2823
                }
2824
              } else { 
2825
                TProtocolUtil.skip(iprot, field.type);
2826
              }
2827
              break;
2828
          }
2829
          iprot.readFieldEnd();
2830
        }
2831
      }
2832
      iprot.readStructEnd();
2833
      validate();
2834
    }
2835
 
2836
    public void write(TProtocol oprot) throws TException {
2837
      oprot.writeStructBegin(STRUCT_DESC);
2838
 
2839
      if (this.isSetSuccess()) {
2840
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
2841
        {
2842
          oprot.writeListBegin(new TList(TType.STRUCT, this.success.size()));
2843
          for (Ticket _iter11 : this.success)
2844
          {
2845
            _iter11.write(oprot);
2846
          }
2847
          oprot.writeListEnd();
2848
        }
2849
        oprot.writeFieldEnd();
2850
      }
2851
      oprot.writeFieldStop();
2852
      oprot.writeStructEnd();
2853
    }
2854
 
2855
    @Override
2856
    public String toString() {
3137 mandeep.dh 2857
      StringBuilder sb = new StringBuilder("getUnassignedTickets_result(");
3087 mandeep.dh 2858
      boolean first = true;
2859
 
2860
      sb.append("success:");
2861
      if (this.success == null) {
2862
        sb.append("null");
2863
      } else {
2864
        sb.append(this.success);
2865
      }
2866
      first = false;
2867
      sb.append(")");
2868
      return sb.toString();
2869
    }
2870
 
2871
    public void validate() throws TException {
2872
      // check for required fields
2873
    }
2874
 
2875
  }
2876
 
3137 mandeep.dh 2877
  public static class getAllTickets_args implements TBase<getAllTickets_args._Fields>, java.io.Serializable, Cloneable, Comparable<getAllTickets_args>   {
2878
    private static final TStruct STRUCT_DESC = new TStruct("getAllTickets_args");
2879
 
2880
    private static final TField AGENT_ID_FIELD_DESC = new TField("agentId", TType.I64, (short)1);
2881
 
2882
    private long agentId;
2883
 
2884
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
2885
    public enum _Fields implements TFieldIdEnum {
2886
      AGENT_ID((short)1, "agentId");
2887
 
2888
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
2889
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
2890
 
2891
      static {
2892
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
2893
          byId.put((int)field._thriftId, field);
2894
          byName.put(field.getFieldName(), field);
2895
        }
2896
      }
2897
 
2898
      /**
2899
       * Find the _Fields constant that matches fieldId, or null if its not found.
2900
       */
2901
      public static _Fields findByThriftId(int fieldId) {
2902
        return byId.get(fieldId);
2903
      }
2904
 
2905
      /**
2906
       * Find the _Fields constant that matches fieldId, throwing an exception
2907
       * if it is not found.
2908
       */
2909
      public static _Fields findByThriftIdOrThrow(int fieldId) {
2910
        _Fields fields = findByThriftId(fieldId);
2911
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
2912
        return fields;
2913
      }
2914
 
2915
      /**
2916
       * Find the _Fields constant that matches name, or null if its not found.
2917
       */
2918
      public static _Fields findByName(String name) {
2919
        return byName.get(name);
2920
      }
2921
 
2922
      private final short _thriftId;
2923
      private final String _fieldName;
2924
 
2925
      _Fields(short thriftId, String fieldName) {
2926
        _thriftId = thriftId;
2927
        _fieldName = fieldName;
2928
      }
2929
 
2930
      public short getThriftFieldId() {
2931
        return _thriftId;
2932
      }
2933
 
2934
      public String getFieldName() {
2935
        return _fieldName;
2936
      }
2937
    }
2938
 
2939
    // isset id assignments
2940
    private static final int __AGENTID_ISSET_ID = 0;
2941
    private BitSet __isset_bit_vector = new BitSet(1);
2942
 
2943
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
2944
      put(_Fields.AGENT_ID, new FieldMetaData("agentId", TFieldRequirementType.DEFAULT, 
2945
          new FieldValueMetaData(TType.I64)));
2946
    }});
2947
 
2948
    static {
2949
      FieldMetaData.addStructMetaDataMap(getAllTickets_args.class, metaDataMap);
2950
    }
2951
 
2952
    public getAllTickets_args() {
2953
    }
2954
 
2955
    public getAllTickets_args(
2956
      long agentId)
2957
    {
2958
      this();
2959
      this.agentId = agentId;
2960
      setAgentIdIsSet(true);
2961
    }
2962
 
2963
    /**
2964
     * Performs a deep copy on <i>other</i>.
2965
     */
2966
    public getAllTickets_args(getAllTickets_args other) {
2967
      __isset_bit_vector.clear();
2968
      __isset_bit_vector.or(other.__isset_bit_vector);
2969
      this.agentId = other.agentId;
2970
    }
2971
 
2972
    public getAllTickets_args deepCopy() {
2973
      return new getAllTickets_args(this);
2974
    }
2975
 
2976
    @Deprecated
2977
    public getAllTickets_args clone() {
2978
      return new getAllTickets_args(this);
2979
    }
2980
 
2981
    public long getAgentId() {
2982
      return this.agentId;
2983
    }
2984
 
2985
    public getAllTickets_args setAgentId(long agentId) {
2986
      this.agentId = agentId;
2987
      setAgentIdIsSet(true);
2988
      return this;
2989
    }
2990
 
2991
    public void unsetAgentId() {
2992
      __isset_bit_vector.clear(__AGENTID_ISSET_ID);
2993
    }
2994
 
2995
    /** Returns true if field agentId is set (has been asigned a value) and false otherwise */
2996
    public boolean isSetAgentId() {
2997
      return __isset_bit_vector.get(__AGENTID_ISSET_ID);
2998
    }
2999
 
3000
    public void setAgentIdIsSet(boolean value) {
3001
      __isset_bit_vector.set(__AGENTID_ISSET_ID, value);
3002
    }
3003
 
3004
    public void setFieldValue(_Fields field, Object value) {
3005
      switch (field) {
3006
      case AGENT_ID:
3007
        if (value == null) {
3008
          unsetAgentId();
3009
        } else {
3010
          setAgentId((Long)value);
3011
        }
3012
        break;
3013
 
3014
      }
3015
    }
3016
 
3017
    public void setFieldValue(int fieldID, Object value) {
3018
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
3019
    }
3020
 
3021
    public Object getFieldValue(_Fields field) {
3022
      switch (field) {
3023
      case AGENT_ID:
3024
        return new Long(getAgentId());
3025
 
3026
      }
3027
      throw new IllegalStateException();
3028
    }
3029
 
3030
    public Object getFieldValue(int fieldId) {
3031
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
3032
    }
3033
 
3034
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
3035
    public boolean isSet(_Fields field) {
3036
      switch (field) {
3037
      case AGENT_ID:
3038
        return isSetAgentId();
3039
      }
3040
      throw new IllegalStateException();
3041
    }
3042
 
3043
    public boolean isSet(int fieldID) {
3044
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
3045
    }
3046
 
3047
    @Override
3048
    public boolean equals(Object that) {
3049
      if (that == null)
3050
        return false;
3051
      if (that instanceof getAllTickets_args)
3052
        return this.equals((getAllTickets_args)that);
3053
      return false;
3054
    }
3055
 
3056
    public boolean equals(getAllTickets_args that) {
3057
      if (that == null)
3058
        return false;
3059
 
3060
      boolean this_present_agentId = true;
3061
      boolean that_present_agentId = true;
3062
      if (this_present_agentId || that_present_agentId) {
3063
        if (!(this_present_agentId && that_present_agentId))
3064
          return false;
3065
        if (this.agentId != that.agentId)
3066
          return false;
3067
      }
3068
 
3069
      return true;
3070
    }
3071
 
3072
    @Override
3073
    public int hashCode() {
3074
      return 0;
3075
    }
3076
 
3077
    public int compareTo(getAllTickets_args other) {
3078
      if (!getClass().equals(other.getClass())) {
3079
        return getClass().getName().compareTo(other.getClass().getName());
3080
      }
3081
 
3082
      int lastComparison = 0;
3083
      getAllTickets_args typedOther = (getAllTickets_args)other;
3084
 
3085
      lastComparison = Boolean.valueOf(isSetAgentId()).compareTo(isSetAgentId());
3086
      if (lastComparison != 0) {
3087
        return lastComparison;
3088
      }
3089
      lastComparison = TBaseHelper.compareTo(agentId, typedOther.agentId);
3090
      if (lastComparison != 0) {
3091
        return lastComparison;
3092
      }
3093
      return 0;
3094
    }
3095
 
3096
    public void read(TProtocol iprot) throws TException {
3097
      TField field;
3098
      iprot.readStructBegin();
3099
      while (true)
3100
      {
3101
        field = iprot.readFieldBegin();
3102
        if (field.type == TType.STOP) { 
3103
          break;
3104
        }
3105
        _Fields fieldId = _Fields.findByThriftId(field.id);
3106
        if (fieldId == null) {
3107
          TProtocolUtil.skip(iprot, field.type);
3108
        } else {
3109
          switch (fieldId) {
3110
            case AGENT_ID:
3111
              if (field.type == TType.I64) {
3112
                this.agentId = iprot.readI64();
3113
                setAgentIdIsSet(true);
3114
              } else { 
3115
                TProtocolUtil.skip(iprot, field.type);
3116
              }
3117
              break;
3118
          }
3119
          iprot.readFieldEnd();
3120
        }
3121
      }
3122
      iprot.readStructEnd();
3123
      validate();
3124
    }
3125
 
3126
    public void write(TProtocol oprot) throws TException {
3127
      validate();
3128
 
3129
      oprot.writeStructBegin(STRUCT_DESC);
3130
      oprot.writeFieldBegin(AGENT_ID_FIELD_DESC);
3131
      oprot.writeI64(this.agentId);
3132
      oprot.writeFieldEnd();
3133
      oprot.writeFieldStop();
3134
      oprot.writeStructEnd();
3135
    }
3136
 
3137
    @Override
3138
    public String toString() {
3139
      StringBuilder sb = new StringBuilder("getAllTickets_args(");
3140
      boolean first = true;
3141
 
3142
      sb.append("agentId:");
3143
      sb.append(this.agentId);
3144
      first = false;
3145
      sb.append(")");
3146
      return sb.toString();
3147
    }
3148
 
3149
    public void validate() throws TException {
3150
      // check for required fields
3151
    }
3152
 
3153
  }
3154
 
3155
  public static class getAllTickets_result implements TBase<getAllTickets_result._Fields>, java.io.Serializable, Cloneable, Comparable<getAllTickets_result>   {
3156
    private static final TStruct STRUCT_DESC = new TStruct("getAllTickets_result");
3157
 
3158
    private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.LIST, (short)0);
3159
 
3160
    private List<Ticket> success;
3161
 
3162
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3163
    public enum _Fields implements TFieldIdEnum {
3164
      SUCCESS((short)0, "success");
3165
 
3166
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
3167
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3168
 
3169
      static {
3170
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3171
          byId.put((int)field._thriftId, field);
3172
          byName.put(field.getFieldName(), field);
3173
        }
3174
      }
3175
 
3176
      /**
3177
       * Find the _Fields constant that matches fieldId, or null if its not found.
3178
       */
3179
      public static _Fields findByThriftId(int fieldId) {
3180
        return byId.get(fieldId);
3181
      }
3182
 
3183
      /**
3184
       * Find the _Fields constant that matches fieldId, throwing an exception
3185
       * if it is not found.
3186
       */
3187
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3188
        _Fields fields = findByThriftId(fieldId);
3189
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3190
        return fields;
3191
      }
3192
 
3193
      /**
3194
       * Find the _Fields constant that matches name, or null if its not found.
3195
       */
3196
      public static _Fields findByName(String name) {
3197
        return byName.get(name);
3198
      }
3199
 
3200
      private final short _thriftId;
3201
      private final String _fieldName;
3202
 
3203
      _Fields(short thriftId, String fieldName) {
3204
        _thriftId = thriftId;
3205
        _fieldName = fieldName;
3206
      }
3207
 
3208
      public short getThriftFieldId() {
3209
        return _thriftId;
3210
      }
3211
 
3212
      public String getFieldName() {
3213
        return _fieldName;
3214
      }
3215
    }
3216
 
3217
    // isset id assignments
3218
 
3219
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
3220
      put(_Fields.SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, 
3221
          new ListMetaData(TType.LIST, 
3222
              new StructMetaData(TType.STRUCT, Ticket.class))));
3223
    }});
3224
 
3225
    static {
3226
      FieldMetaData.addStructMetaDataMap(getAllTickets_result.class, metaDataMap);
3227
    }
3228
 
3229
    public getAllTickets_result() {
3230
    }
3231
 
3232
    public getAllTickets_result(
3233
      List<Ticket> success)
3234
    {
3235
      this();
3236
      this.success = success;
3237
    }
3238
 
3239
    /**
3240
     * Performs a deep copy on <i>other</i>.
3241
     */
3242
    public getAllTickets_result(getAllTickets_result other) {
3243
      if (other.isSetSuccess()) {
3244
        List<Ticket> __this__success = new ArrayList<Ticket>();
3245
        for (Ticket other_element : other.success) {
3246
          __this__success.add(new Ticket(other_element));
3247
        }
3248
        this.success = __this__success;
3249
      }
3250
    }
3251
 
3252
    public getAllTickets_result deepCopy() {
3253
      return new getAllTickets_result(this);
3254
    }
3255
 
3256
    @Deprecated
3257
    public getAllTickets_result clone() {
3258
      return new getAllTickets_result(this);
3259
    }
3260
 
3261
    public int getSuccessSize() {
3262
      return (this.success == null) ? 0 : this.success.size();
3263
    }
3264
 
3265
    public java.util.Iterator<Ticket> getSuccessIterator() {
3266
      return (this.success == null) ? null : this.success.iterator();
3267
    }
3268
 
3269
    public void addToSuccess(Ticket elem) {
3270
      if (this.success == null) {
3271
        this.success = new ArrayList<Ticket>();
3272
      }
3273
      this.success.add(elem);
3274
    }
3275
 
3276
    public List<Ticket> getSuccess() {
3277
      return this.success;
3278
    }
3279
 
3280
    public getAllTickets_result setSuccess(List<Ticket> success) {
3281
      this.success = success;
3282
      return this;
3283
    }
3284
 
3285
    public void unsetSuccess() {
3286
      this.success = null;
3287
    }
3288
 
3289
    /** Returns true if field success is set (has been asigned a value) and false otherwise */
3290
    public boolean isSetSuccess() {
3291
      return this.success != null;
3292
    }
3293
 
3294
    public void setSuccessIsSet(boolean value) {
3295
      if (!value) {
3296
        this.success = null;
3297
      }
3298
    }
3299
 
3300
    public void setFieldValue(_Fields field, Object value) {
3301
      switch (field) {
3302
      case SUCCESS:
3303
        if (value == null) {
3304
          unsetSuccess();
3305
        } else {
3306
          setSuccess((List<Ticket>)value);
3307
        }
3308
        break;
3309
 
3310
      }
3311
    }
3312
 
3313
    public void setFieldValue(int fieldID, Object value) {
3314
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
3315
    }
3316
 
3317
    public Object getFieldValue(_Fields field) {
3318
      switch (field) {
3319
      case SUCCESS:
3320
        return getSuccess();
3321
 
3322
      }
3323
      throw new IllegalStateException();
3324
    }
3325
 
3326
    public Object getFieldValue(int fieldId) {
3327
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
3328
    }
3329
 
3330
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
3331
    public boolean isSet(_Fields field) {
3332
      switch (field) {
3333
      case SUCCESS:
3334
        return isSetSuccess();
3335
      }
3336
      throw new IllegalStateException();
3337
    }
3338
 
3339
    public boolean isSet(int fieldID) {
3340
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
3341
    }
3342
 
3343
    @Override
3344
    public boolean equals(Object that) {
3345
      if (that == null)
3346
        return false;
3347
      if (that instanceof getAllTickets_result)
3348
        return this.equals((getAllTickets_result)that);
3349
      return false;
3350
    }
3351
 
3352
    public boolean equals(getAllTickets_result that) {
3353
      if (that == null)
3354
        return false;
3355
 
3356
      boolean this_present_success = true && this.isSetSuccess();
3357
      boolean that_present_success = true && that.isSetSuccess();
3358
      if (this_present_success || that_present_success) {
3359
        if (!(this_present_success && that_present_success))
3360
          return false;
3361
        if (!this.success.equals(that.success))
3362
          return false;
3363
      }
3364
 
3365
      return true;
3366
    }
3367
 
3368
    @Override
3369
    public int hashCode() {
3370
      return 0;
3371
    }
3372
 
3373
    public int compareTo(getAllTickets_result other) {
3374
      if (!getClass().equals(other.getClass())) {
3375
        return getClass().getName().compareTo(other.getClass().getName());
3376
      }
3377
 
3378
      int lastComparison = 0;
3379
      getAllTickets_result typedOther = (getAllTickets_result)other;
3380
 
3381
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(isSetSuccess());
3382
      if (lastComparison != 0) {
3383
        return lastComparison;
3384
      }
3385
      lastComparison = TBaseHelper.compareTo(success, typedOther.success);
3386
      if (lastComparison != 0) {
3387
        return lastComparison;
3388
      }
3389
      return 0;
3390
    }
3391
 
3392
    public void read(TProtocol iprot) throws TException {
3393
      TField field;
3394
      iprot.readStructBegin();
3395
      while (true)
3396
      {
3397
        field = iprot.readFieldBegin();
3398
        if (field.type == TType.STOP) { 
3399
          break;
3400
        }
3401
        _Fields fieldId = _Fields.findByThriftId(field.id);
3402
        if (fieldId == null) {
3403
          TProtocolUtil.skip(iprot, field.type);
3404
        } else {
3405
          switch (fieldId) {
3406
            case SUCCESS:
3407
              if (field.type == TType.LIST) {
3408
                {
3409
                  TList _list12 = iprot.readListBegin();
3410
                  this.success = new ArrayList<Ticket>(_list12.size);
3411
                  for (int _i13 = 0; _i13 < _list12.size; ++_i13)
3412
                  {
3413
                    Ticket _elem14;
3414
                    _elem14 = new Ticket();
3415
                    _elem14.read(iprot);
3416
                    this.success.add(_elem14);
3417
                  }
3418
                  iprot.readListEnd();
3419
                }
3420
              } else { 
3421
                TProtocolUtil.skip(iprot, field.type);
3422
              }
3423
              break;
3424
          }
3425
          iprot.readFieldEnd();
3426
        }
3427
      }
3428
      iprot.readStructEnd();
3429
      validate();
3430
    }
3431
 
3432
    public void write(TProtocol oprot) throws TException {
3433
      oprot.writeStructBegin(STRUCT_DESC);
3434
 
3435
      if (this.isSetSuccess()) {
3436
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
3437
        {
3438
          oprot.writeListBegin(new TList(TType.STRUCT, this.success.size()));
3439
          for (Ticket _iter15 : this.success)
3440
          {
3441
            _iter15.write(oprot);
3442
          }
3443
          oprot.writeListEnd();
3444
        }
3445
        oprot.writeFieldEnd();
3446
      }
3447
      oprot.writeFieldStop();
3448
      oprot.writeStructEnd();
3449
    }
3450
 
3451
    @Override
3452
    public String toString() {
3453
      StringBuilder sb = new StringBuilder("getAllTickets_result(");
3454
      boolean first = true;
3455
 
3456
      sb.append("success:");
3457
      if (this.success == null) {
3458
        sb.append("null");
3459
      } else {
3460
        sb.append(this.success);
3461
      }
3462
      first = false;
3463
      sb.append(")");
3464
      return sb.toString();
3465
    }
3466
 
3467
    public void validate() throws TException {
3468
      // check for required fields
3469
    }
3470
 
3471
  }
3472
 
3028 mandeep.dh 3473
  public static class getTicket_args implements TBase<getTicket_args._Fields>, java.io.Serializable, Cloneable, Comparable<getTicket_args>   {
3474
    private static final TStruct STRUCT_DESC = new TStruct("getTicket_args");
3475
 
3476
    private static final TField TICKET_ID_FIELD_DESC = new TField("ticketId", TType.I64, (short)1);
3477
 
3478
    private long ticketId;
3479
 
3480
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3481
    public enum _Fields implements TFieldIdEnum {
3482
      TICKET_ID((short)1, "ticketId");
3483
 
3484
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
3485
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3486
 
3487
      static {
3488
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3489
          byId.put((int)field._thriftId, field);
3490
          byName.put(field.getFieldName(), field);
3491
        }
3492
      }
3493
 
3494
      /**
3495
       * Find the _Fields constant that matches fieldId, or null if its not found.
3496
       */
3497
      public static _Fields findByThriftId(int fieldId) {
3498
        return byId.get(fieldId);
3499
      }
3500
 
3501
      /**
3502
       * Find the _Fields constant that matches fieldId, throwing an exception
3503
       * if it is not found.
3504
       */
3505
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3506
        _Fields fields = findByThriftId(fieldId);
3507
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3508
        return fields;
3509
      }
3510
 
3511
      /**
3512
       * Find the _Fields constant that matches name, or null if its not found.
3513
       */
3514
      public static _Fields findByName(String name) {
3515
        return byName.get(name);
3516
      }
3517
 
3518
      private final short _thriftId;
3519
      private final String _fieldName;
3520
 
3521
      _Fields(short thriftId, String fieldName) {
3522
        _thriftId = thriftId;
3523
        _fieldName = fieldName;
3524
      }
3525
 
3526
      public short getThriftFieldId() {
3527
        return _thriftId;
3528
      }
3529
 
3530
      public String getFieldName() {
3531
        return _fieldName;
3532
      }
3533
    }
3534
 
3535
    // isset id assignments
3536
    private static final int __TICKETID_ISSET_ID = 0;
3537
    private BitSet __isset_bit_vector = new BitSet(1);
3538
 
3539
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
3540
      put(_Fields.TICKET_ID, new FieldMetaData("ticketId", TFieldRequirementType.DEFAULT, 
3541
          new FieldValueMetaData(TType.I64)));
3542
    }});
3543
 
3544
    static {
3545
      FieldMetaData.addStructMetaDataMap(getTicket_args.class, metaDataMap);
3546
    }
3547
 
3548
    public getTicket_args() {
3549
    }
3550
 
3551
    public getTicket_args(
3552
      long ticketId)
3553
    {
3554
      this();
3555
      this.ticketId = ticketId;
3556
      setTicketIdIsSet(true);
3557
    }
3558
 
3559
    /**
3560
     * Performs a deep copy on <i>other</i>.
3561
     */
3562
    public getTicket_args(getTicket_args other) {
3563
      __isset_bit_vector.clear();
3564
      __isset_bit_vector.or(other.__isset_bit_vector);
3565
      this.ticketId = other.ticketId;
3566
    }
3567
 
3568
    public getTicket_args deepCopy() {
3569
      return new getTicket_args(this);
3570
    }
3571
 
3572
    @Deprecated
3573
    public getTicket_args clone() {
3574
      return new getTicket_args(this);
3575
    }
3576
 
3577
    public long getTicketId() {
3578
      return this.ticketId;
3579
    }
3580
 
3581
    public getTicket_args setTicketId(long ticketId) {
3582
      this.ticketId = ticketId;
3583
      setTicketIdIsSet(true);
3584
      return this;
3585
    }
3586
 
3587
    public void unsetTicketId() {
3588
      __isset_bit_vector.clear(__TICKETID_ISSET_ID);
3589
    }
3590
 
3591
    /** Returns true if field ticketId is set (has been asigned a value) and false otherwise */
3592
    public boolean isSetTicketId() {
3593
      return __isset_bit_vector.get(__TICKETID_ISSET_ID);
3594
    }
3595
 
3596
    public void setTicketIdIsSet(boolean value) {
3597
      __isset_bit_vector.set(__TICKETID_ISSET_ID, value);
3598
    }
3599
 
3600
    public void setFieldValue(_Fields field, Object value) {
3601
      switch (field) {
3602
      case TICKET_ID:
3603
        if (value == null) {
3604
          unsetTicketId();
3605
        } else {
3606
          setTicketId((Long)value);
3607
        }
3608
        break;
3609
 
3610
      }
3611
    }
3612
 
3613
    public void setFieldValue(int fieldID, Object value) {
3614
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
3615
    }
3616
 
3617
    public Object getFieldValue(_Fields field) {
3618
      switch (field) {
3619
      case TICKET_ID:
3620
        return new Long(getTicketId());
3621
 
3622
      }
3623
      throw new IllegalStateException();
3624
    }
3625
 
3626
    public Object getFieldValue(int fieldId) {
3627
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
3628
    }
3629
 
3630
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
3631
    public boolean isSet(_Fields field) {
3632
      switch (field) {
3633
      case TICKET_ID:
3634
        return isSetTicketId();
3635
      }
3636
      throw new IllegalStateException();
3637
    }
3638
 
3639
    public boolean isSet(int fieldID) {
3640
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
3641
    }
3642
 
3643
    @Override
3644
    public boolean equals(Object that) {
3645
      if (that == null)
3646
        return false;
3647
      if (that instanceof getTicket_args)
3648
        return this.equals((getTicket_args)that);
3649
      return false;
3650
    }
3651
 
3652
    public boolean equals(getTicket_args that) {
3653
      if (that == null)
3654
        return false;
3655
 
3656
      boolean this_present_ticketId = true;
3657
      boolean that_present_ticketId = true;
3658
      if (this_present_ticketId || that_present_ticketId) {
3659
        if (!(this_present_ticketId && that_present_ticketId))
3660
          return false;
3661
        if (this.ticketId != that.ticketId)
3662
          return false;
3663
      }
3664
 
3665
      return true;
3666
    }
3667
 
3668
    @Override
3669
    public int hashCode() {
3670
      return 0;
3671
    }
3672
 
3673
    public int compareTo(getTicket_args other) {
3674
      if (!getClass().equals(other.getClass())) {
3675
        return getClass().getName().compareTo(other.getClass().getName());
3676
      }
3677
 
3678
      int lastComparison = 0;
3679
      getTicket_args typedOther = (getTicket_args)other;
3680
 
3681
      lastComparison = Boolean.valueOf(isSetTicketId()).compareTo(isSetTicketId());
3682
      if (lastComparison != 0) {
3683
        return lastComparison;
3684
      }
3685
      lastComparison = TBaseHelper.compareTo(ticketId, typedOther.ticketId);
3686
      if (lastComparison != 0) {
3687
        return lastComparison;
3688
      }
3689
      return 0;
3690
    }
3691
 
3692
    public void read(TProtocol iprot) throws TException {
3693
      TField field;
3694
      iprot.readStructBegin();
3695
      while (true)
3696
      {
3697
        field = iprot.readFieldBegin();
3698
        if (field.type == TType.STOP) { 
3699
          break;
3700
        }
3701
        _Fields fieldId = _Fields.findByThriftId(field.id);
3702
        if (fieldId == null) {
3703
          TProtocolUtil.skip(iprot, field.type);
3704
        } else {
3705
          switch (fieldId) {
3706
            case TICKET_ID:
3707
              if (field.type == TType.I64) {
3708
                this.ticketId = iprot.readI64();
3709
                setTicketIdIsSet(true);
3710
              } else { 
3711
                TProtocolUtil.skip(iprot, field.type);
3712
              }
3713
              break;
3714
          }
3715
          iprot.readFieldEnd();
3716
        }
3717
      }
3718
      iprot.readStructEnd();
3719
      validate();
3720
    }
3721
 
3722
    public void write(TProtocol oprot) throws TException {
3723
      validate();
3724
 
3725
      oprot.writeStructBegin(STRUCT_DESC);
3726
      oprot.writeFieldBegin(TICKET_ID_FIELD_DESC);
3727
      oprot.writeI64(this.ticketId);
3728
      oprot.writeFieldEnd();
3729
      oprot.writeFieldStop();
3730
      oprot.writeStructEnd();
3731
    }
3732
 
3733
    @Override
3734
    public String toString() {
3735
      StringBuilder sb = new StringBuilder("getTicket_args(");
3736
      boolean first = true;
3737
 
3738
      sb.append("ticketId:");
3739
      sb.append(this.ticketId);
3740
      first = false;
3741
      sb.append(")");
3742
      return sb.toString();
3743
    }
3744
 
3745
    public void validate() throws TException {
3746
      // check for required fields
3747
    }
3748
 
3749
  }
3750
 
3751
  public static class getTicket_result implements TBase<getTicket_result._Fields>, java.io.Serializable, Cloneable, Comparable<getTicket_result>   {
3752
    private static final TStruct STRUCT_DESC = new TStruct("getTicket_result");
3753
 
3754
    private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0);
3755
 
3756
    private Ticket success;
3757
 
3758
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3759
    public enum _Fields implements TFieldIdEnum {
3760
      SUCCESS((short)0, "success");
3761
 
3762
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
3763
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3764
 
3765
      static {
3766
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3767
          byId.put((int)field._thriftId, field);
3768
          byName.put(field.getFieldName(), field);
3769
        }
3770
      }
3771
 
3772
      /**
3773
       * Find the _Fields constant that matches fieldId, or null if its not found.
3774
       */
3775
      public static _Fields findByThriftId(int fieldId) {
3776
        return byId.get(fieldId);
3777
      }
3778
 
3779
      /**
3780
       * Find the _Fields constant that matches fieldId, throwing an exception
3781
       * if it is not found.
3782
       */
3783
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3784
        _Fields fields = findByThriftId(fieldId);
3785
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3786
        return fields;
3787
      }
3788
 
3789
      /**
3790
       * Find the _Fields constant that matches name, or null if its not found.
3791
       */
3792
      public static _Fields findByName(String name) {
3793
        return byName.get(name);
3794
      }
3795
 
3796
      private final short _thriftId;
3797
      private final String _fieldName;
3798
 
3799
      _Fields(short thriftId, String fieldName) {
3800
        _thriftId = thriftId;
3801
        _fieldName = fieldName;
3802
      }
3803
 
3804
      public short getThriftFieldId() {
3805
        return _thriftId;
3806
      }
3807
 
3808
      public String getFieldName() {
3809
        return _fieldName;
3810
      }
3811
    }
3812
 
3813
    // isset id assignments
3814
 
3815
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
3816
      put(_Fields.SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, 
3817
          new StructMetaData(TType.STRUCT, Ticket.class)));
3818
    }});
3819
 
3820
    static {
3821
      FieldMetaData.addStructMetaDataMap(getTicket_result.class, metaDataMap);
3822
    }
3823
 
3824
    public getTicket_result() {
3825
    }
3826
 
3827
    public getTicket_result(
3828
      Ticket success)
3829
    {
3830
      this();
3831
      this.success = success;
3832
    }
3833
 
3834
    /**
3835
     * Performs a deep copy on <i>other</i>.
3836
     */
3837
    public getTicket_result(getTicket_result other) {
3838
      if (other.isSetSuccess()) {
3839
        this.success = new Ticket(other.success);
3840
      }
3841
    }
3842
 
3843
    public getTicket_result deepCopy() {
3844
      return new getTicket_result(this);
3845
    }
3846
 
3847
    @Deprecated
3848
    public getTicket_result clone() {
3849
      return new getTicket_result(this);
3850
    }
3851
 
3852
    public Ticket getSuccess() {
3853
      return this.success;
3854
    }
3855
 
3856
    public getTicket_result setSuccess(Ticket success) {
3857
      this.success = success;
3858
      return this;
3859
    }
3860
 
3861
    public void unsetSuccess() {
3862
      this.success = null;
3863
    }
3864
 
3865
    /** Returns true if field success is set (has been asigned a value) and false otherwise */
3866
    public boolean isSetSuccess() {
3867
      return this.success != null;
3868
    }
3869
 
3870
    public void setSuccessIsSet(boolean value) {
3871
      if (!value) {
3872
        this.success = null;
3873
      }
3874
    }
3875
 
3876
    public void setFieldValue(_Fields field, Object value) {
3877
      switch (field) {
3878
      case SUCCESS:
3879
        if (value == null) {
3880
          unsetSuccess();
3881
        } else {
3882
          setSuccess((Ticket)value);
3883
        }
3884
        break;
3885
 
3886
      }
3887
    }
3888
 
3889
    public void setFieldValue(int fieldID, Object value) {
3890
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
3891
    }
3892
 
3893
    public Object getFieldValue(_Fields field) {
3894
      switch (field) {
3895
      case SUCCESS:
3896
        return getSuccess();
3897
 
3898
      }
3899
      throw new IllegalStateException();
3900
    }
3901
 
3902
    public Object getFieldValue(int fieldId) {
3903
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
3904
    }
3905
 
3906
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
3907
    public boolean isSet(_Fields field) {
3908
      switch (field) {
3909
      case SUCCESS:
3910
        return isSetSuccess();
3911
      }
3912
      throw new IllegalStateException();
3913
    }
3914
 
3915
    public boolean isSet(int fieldID) {
3916
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
3917
    }
3918
 
3919
    @Override
3920
    public boolean equals(Object that) {
3921
      if (that == null)
3922
        return false;
3923
      if (that instanceof getTicket_result)
3924
        return this.equals((getTicket_result)that);
3925
      return false;
3926
    }
3927
 
3928
    public boolean equals(getTicket_result that) {
3929
      if (that == null)
3930
        return false;
3931
 
3932
      boolean this_present_success = true && this.isSetSuccess();
3933
      boolean that_present_success = true && that.isSetSuccess();
3934
      if (this_present_success || that_present_success) {
3935
        if (!(this_present_success && that_present_success))
3936
          return false;
3937
        if (!this.success.equals(that.success))
3938
          return false;
3939
      }
3940
 
3941
      return true;
3942
    }
3943
 
3944
    @Override
3945
    public int hashCode() {
3946
      return 0;
3947
    }
3948
 
3949
    public int compareTo(getTicket_result other) {
3950
      if (!getClass().equals(other.getClass())) {
3951
        return getClass().getName().compareTo(other.getClass().getName());
3952
      }
3953
 
3954
      int lastComparison = 0;
3955
      getTicket_result typedOther = (getTicket_result)other;
3956
 
3957
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(isSetSuccess());
3958
      if (lastComparison != 0) {
3959
        return lastComparison;
3960
      }
3961
      lastComparison = TBaseHelper.compareTo(success, typedOther.success);
3962
      if (lastComparison != 0) {
3963
        return lastComparison;
3964
      }
3965
      return 0;
3966
    }
3967
 
3968
    public void read(TProtocol iprot) throws TException {
3969
      TField field;
3970
      iprot.readStructBegin();
3971
      while (true)
3972
      {
3973
        field = iprot.readFieldBegin();
3974
        if (field.type == TType.STOP) { 
3975
          break;
3976
        }
3977
        _Fields fieldId = _Fields.findByThriftId(field.id);
3978
        if (fieldId == null) {
3979
          TProtocolUtil.skip(iprot, field.type);
3980
        } else {
3981
          switch (fieldId) {
3982
            case SUCCESS:
3983
              if (field.type == TType.STRUCT) {
3984
                this.success = new Ticket();
3985
                this.success.read(iprot);
3986
              } else { 
3987
                TProtocolUtil.skip(iprot, field.type);
3988
              }
3989
              break;
3990
          }
3991
          iprot.readFieldEnd();
3992
        }
3993
      }
3994
      iprot.readStructEnd();
3995
      validate();
3996
    }
3997
 
3998
    public void write(TProtocol oprot) throws TException {
3999
      oprot.writeStructBegin(STRUCT_DESC);
4000
 
4001
      if (this.isSetSuccess()) {
4002
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
4003
        this.success.write(oprot);
4004
        oprot.writeFieldEnd();
4005
      }
4006
      oprot.writeFieldStop();
4007
      oprot.writeStructEnd();
4008
    }
4009
 
4010
    @Override
4011
    public String toString() {
4012
      StringBuilder sb = new StringBuilder("getTicket_result(");
4013
      boolean first = true;
4014
 
4015
      sb.append("success:");
4016
      if (this.success == null) {
4017
        sb.append("null");
4018
      } else {
4019
        sb.append(this.success);
4020
      }
4021
      first = false;
4022
      sb.append(")");
4023
      return sb.toString();
4024
    }
4025
 
4026
    public void validate() throws TException {
4027
      // check for required fields
4028
    }
4029
 
4030
  }
4031
 
4032
  public static class updateTicket_args implements TBase<updateTicket_args._Fields>, java.io.Serializable, Cloneable, Comparable<updateTicket_args>   {
4033
    private static final TStruct STRUCT_DESC = new TStruct("updateTicket_args");
4034
 
4035
    private static final TField TICKET_FIELD_DESC = new TField("ticket", TType.STRUCT, (short)1);
3206 mandeep.dh 4036
    private static final TField ACTIVITY_FIELD_DESC = new TField("activity", TType.STRUCT, (short)2);
3028 mandeep.dh 4037
 
4038
    private Ticket ticket;
3206 mandeep.dh 4039
    private Activity activity;
3028 mandeep.dh 4040
 
4041
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
4042
    public enum _Fields implements TFieldIdEnum {
3206 mandeep.dh 4043
      TICKET((short)1, "ticket"),
4044
      ACTIVITY((short)2, "activity");
3028 mandeep.dh 4045
 
4046
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
4047
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4048
 
4049
      static {
4050
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4051
          byId.put((int)field._thriftId, field);
4052
          byName.put(field.getFieldName(), field);
4053
        }
4054
      }
4055
 
4056
      /**
4057
       * Find the _Fields constant that matches fieldId, or null if its not found.
4058
       */
4059
      public static _Fields findByThriftId(int fieldId) {
4060
        return byId.get(fieldId);
4061
      }
4062
 
4063
      /**
4064
       * Find the _Fields constant that matches fieldId, throwing an exception
4065
       * if it is not found.
4066
       */
4067
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4068
        _Fields fields = findByThriftId(fieldId);
4069
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4070
        return fields;
4071
      }
4072
 
4073
      /**
4074
       * Find the _Fields constant that matches name, or null if its not found.
4075
       */
4076
      public static _Fields findByName(String name) {
4077
        return byName.get(name);
4078
      }
4079
 
4080
      private final short _thriftId;
4081
      private final String _fieldName;
4082
 
4083
      _Fields(short thriftId, String fieldName) {
4084
        _thriftId = thriftId;
4085
        _fieldName = fieldName;
4086
      }
4087
 
4088
      public short getThriftFieldId() {
4089
        return _thriftId;
4090
      }
4091
 
4092
      public String getFieldName() {
4093
        return _fieldName;
4094
      }
4095
    }
4096
 
4097
    // isset id assignments
4098
 
4099
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
4100
      put(_Fields.TICKET, new FieldMetaData("ticket", TFieldRequirementType.DEFAULT, 
4101
          new StructMetaData(TType.STRUCT, Ticket.class)));
3206 mandeep.dh 4102
      put(_Fields.ACTIVITY, new FieldMetaData("activity", TFieldRequirementType.DEFAULT, 
4103
          new StructMetaData(TType.STRUCT, Activity.class)));
3028 mandeep.dh 4104
    }});
4105
 
4106
    static {
4107
      FieldMetaData.addStructMetaDataMap(updateTicket_args.class, metaDataMap);
4108
    }
4109
 
4110
    public updateTicket_args() {
4111
    }
4112
 
4113
    public updateTicket_args(
3206 mandeep.dh 4114
      Ticket ticket,
4115
      Activity activity)
3028 mandeep.dh 4116
    {
4117
      this();
4118
      this.ticket = ticket;
3206 mandeep.dh 4119
      this.activity = activity;
3028 mandeep.dh 4120
    }
4121
 
4122
    /**
4123
     * Performs a deep copy on <i>other</i>.
4124
     */
4125
    public updateTicket_args(updateTicket_args other) {
4126
      if (other.isSetTicket()) {
4127
        this.ticket = new Ticket(other.ticket);
4128
      }
3206 mandeep.dh 4129
      if (other.isSetActivity()) {
4130
        this.activity = new Activity(other.activity);
4131
      }
3028 mandeep.dh 4132
    }
4133
 
4134
    public updateTicket_args deepCopy() {
4135
      return new updateTicket_args(this);
4136
    }
4137
 
4138
    @Deprecated
4139
    public updateTicket_args clone() {
4140
      return new updateTicket_args(this);
4141
    }
4142
 
4143
    public Ticket getTicket() {
4144
      return this.ticket;
4145
    }
4146
 
4147
    public updateTicket_args setTicket(Ticket ticket) {
4148
      this.ticket = ticket;
4149
      return this;
4150
    }
4151
 
4152
    public void unsetTicket() {
4153
      this.ticket = null;
4154
    }
4155
 
4156
    /** Returns true if field ticket is set (has been asigned a value) and false otherwise */
4157
    public boolean isSetTicket() {
4158
      return this.ticket != null;
4159
    }
4160
 
4161
    public void setTicketIsSet(boolean value) {
4162
      if (!value) {
4163
        this.ticket = null;
4164
      }
4165
    }
4166
 
3206 mandeep.dh 4167
    public Activity getActivity() {
4168
      return this.activity;
4169
    }
4170
 
4171
    public updateTicket_args setActivity(Activity activity) {
4172
      this.activity = activity;
4173
      return this;
4174
    }
4175
 
4176
    public void unsetActivity() {
4177
      this.activity = null;
4178
    }
4179
 
4180
    /** Returns true if field activity is set (has been asigned a value) and false otherwise */
4181
    public boolean isSetActivity() {
4182
      return this.activity != null;
4183
    }
4184
 
4185
    public void setActivityIsSet(boolean value) {
4186
      if (!value) {
4187
        this.activity = null;
4188
      }
4189
    }
4190
 
3028 mandeep.dh 4191
    public void setFieldValue(_Fields field, Object value) {
4192
      switch (field) {
4193
      case TICKET:
4194
        if (value == null) {
4195
          unsetTicket();
4196
        } else {
4197
          setTicket((Ticket)value);
4198
        }
4199
        break;
4200
 
3206 mandeep.dh 4201
      case ACTIVITY:
4202
        if (value == null) {
4203
          unsetActivity();
4204
        } else {
4205
          setActivity((Activity)value);
4206
        }
4207
        break;
4208
 
3028 mandeep.dh 4209
      }
4210
    }
4211
 
4212
    public void setFieldValue(int fieldID, Object value) {
4213
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
4214
    }
4215
 
4216
    public Object getFieldValue(_Fields field) {
4217
      switch (field) {
4218
      case TICKET:
4219
        return getTicket();
4220
 
3206 mandeep.dh 4221
      case ACTIVITY:
4222
        return getActivity();
4223
 
3028 mandeep.dh 4224
      }
4225
      throw new IllegalStateException();
4226
    }
4227
 
4228
    public Object getFieldValue(int fieldId) {
4229
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
4230
    }
4231
 
4232
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
4233
    public boolean isSet(_Fields field) {
4234
      switch (field) {
4235
      case TICKET:
4236
        return isSetTicket();
3206 mandeep.dh 4237
      case ACTIVITY:
4238
        return isSetActivity();
3028 mandeep.dh 4239
      }
4240
      throw new IllegalStateException();
4241
    }
4242
 
4243
    public boolean isSet(int fieldID) {
4244
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
4245
    }
4246
 
4247
    @Override
4248
    public boolean equals(Object that) {
4249
      if (that == null)
4250
        return false;
4251
      if (that instanceof updateTicket_args)
4252
        return this.equals((updateTicket_args)that);
4253
      return false;
4254
    }
4255
 
4256
    public boolean equals(updateTicket_args that) {
4257
      if (that == null)
4258
        return false;
4259
 
4260
      boolean this_present_ticket = true && this.isSetTicket();
4261
      boolean that_present_ticket = true && that.isSetTicket();
4262
      if (this_present_ticket || that_present_ticket) {
4263
        if (!(this_present_ticket && that_present_ticket))
4264
          return false;
4265
        if (!this.ticket.equals(that.ticket))
4266
          return false;
4267
      }
4268
 
3206 mandeep.dh 4269
      boolean this_present_activity = true && this.isSetActivity();
4270
      boolean that_present_activity = true && that.isSetActivity();
4271
      if (this_present_activity || that_present_activity) {
4272
        if (!(this_present_activity && that_present_activity))
4273
          return false;
4274
        if (!this.activity.equals(that.activity))
4275
          return false;
4276
      }
4277
 
3028 mandeep.dh 4278
      return true;
4279
    }
4280
 
4281
    @Override
4282
    public int hashCode() {
4283
      return 0;
4284
    }
4285
 
4286
    public int compareTo(updateTicket_args other) {
4287
      if (!getClass().equals(other.getClass())) {
4288
        return getClass().getName().compareTo(other.getClass().getName());
4289
      }
4290
 
4291
      int lastComparison = 0;
4292
      updateTicket_args typedOther = (updateTicket_args)other;
4293
 
4294
      lastComparison = Boolean.valueOf(isSetTicket()).compareTo(isSetTicket());
4295
      if (lastComparison != 0) {
4296
        return lastComparison;
4297
      }
4298
      lastComparison = TBaseHelper.compareTo(ticket, typedOther.ticket);
4299
      if (lastComparison != 0) {
4300
        return lastComparison;
4301
      }
3206 mandeep.dh 4302
      lastComparison = Boolean.valueOf(isSetActivity()).compareTo(isSetActivity());
4303
      if (lastComparison != 0) {
4304
        return lastComparison;
4305
      }
4306
      lastComparison = TBaseHelper.compareTo(activity, typedOther.activity);
4307
      if (lastComparison != 0) {
4308
        return lastComparison;
4309
      }
3028 mandeep.dh 4310
      return 0;
4311
    }
4312
 
4313
    public void read(TProtocol iprot) throws TException {
4314
      TField field;
4315
      iprot.readStructBegin();
4316
      while (true)
4317
      {
4318
        field = iprot.readFieldBegin();
4319
        if (field.type == TType.STOP) { 
4320
          break;
4321
        }
4322
        _Fields fieldId = _Fields.findByThriftId(field.id);
4323
        if (fieldId == null) {
4324
          TProtocolUtil.skip(iprot, field.type);
4325
        } else {
4326
          switch (fieldId) {
4327
            case TICKET:
4328
              if (field.type == TType.STRUCT) {
4329
                this.ticket = new Ticket();
4330
                this.ticket.read(iprot);
4331
              } else { 
4332
                TProtocolUtil.skip(iprot, field.type);
4333
              }
4334
              break;
3206 mandeep.dh 4335
            case ACTIVITY:
4336
              if (field.type == TType.STRUCT) {
4337
                this.activity = new Activity();
4338
                this.activity.read(iprot);
4339
              } else { 
4340
                TProtocolUtil.skip(iprot, field.type);
4341
              }
4342
              break;
3028 mandeep.dh 4343
          }
4344
          iprot.readFieldEnd();
4345
        }
4346
      }
4347
      iprot.readStructEnd();
4348
      validate();
4349
    }
4350
 
4351
    public void write(TProtocol oprot) throws TException {
4352
      validate();
4353
 
4354
      oprot.writeStructBegin(STRUCT_DESC);
4355
      if (this.ticket != null) {
4356
        oprot.writeFieldBegin(TICKET_FIELD_DESC);
4357
        this.ticket.write(oprot);
4358
        oprot.writeFieldEnd();
4359
      }
3206 mandeep.dh 4360
      if (this.activity != null) {
4361
        oprot.writeFieldBegin(ACTIVITY_FIELD_DESC);
4362
        this.activity.write(oprot);
4363
        oprot.writeFieldEnd();
4364
      }
3028 mandeep.dh 4365
      oprot.writeFieldStop();
4366
      oprot.writeStructEnd();
4367
    }
4368
 
4369
    @Override
4370
    public String toString() {
4371
      StringBuilder sb = new StringBuilder("updateTicket_args(");
4372
      boolean first = true;
4373
 
4374
      sb.append("ticket:");
4375
      if (this.ticket == null) {
4376
        sb.append("null");
4377
      } else {
4378
        sb.append(this.ticket);
4379
      }
4380
      first = false;
3206 mandeep.dh 4381
      if (!first) sb.append(", ");
4382
      sb.append("activity:");
4383
      if (this.activity == null) {
4384
        sb.append("null");
4385
      } else {
4386
        sb.append(this.activity);
4387
      }
4388
      first = false;
3028 mandeep.dh 4389
      sb.append(")");
4390
      return sb.toString();
4391
    }
4392
 
4393
    public void validate() throws TException {
4394
      // check for required fields
4395
    }
4396
 
4397
  }
4398
 
4399
  public static class updateTicket_result implements TBase<updateTicket_result._Fields>, java.io.Serializable, Cloneable, Comparable<updateTicket_result>   {
4400
    private static final TStruct STRUCT_DESC = new TStruct("updateTicket_result");
4401
 
4402
 
4403
 
4404
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
4405
    public enum _Fields implements TFieldIdEnum {
4406
;
4407
 
4408
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
4409
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4410
 
4411
      static {
4412
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4413
          byId.put((int)field._thriftId, field);
4414
          byName.put(field.getFieldName(), field);
4415
        }
4416
      }
4417
 
4418
      /**
4419
       * Find the _Fields constant that matches fieldId, or null if its not found.
4420
       */
4421
      public static _Fields findByThriftId(int fieldId) {
4422
        return byId.get(fieldId);
4423
      }
4424
 
4425
      /**
4426
       * Find the _Fields constant that matches fieldId, throwing an exception
4427
       * if it is not found.
4428
       */
4429
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4430
        _Fields fields = findByThriftId(fieldId);
4431
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4432
        return fields;
4433
      }
4434
 
4435
      /**
4436
       * Find the _Fields constant that matches name, or null if its not found.
4437
       */
4438
      public static _Fields findByName(String name) {
4439
        return byName.get(name);
4440
      }
4441
 
4442
      private final short _thriftId;
4443
      private final String _fieldName;
4444
 
4445
      _Fields(short thriftId, String fieldName) {
4446
        _thriftId = thriftId;
4447
        _fieldName = fieldName;
4448
      }
4449
 
4450
      public short getThriftFieldId() {
4451
        return _thriftId;
4452
      }
4453
 
4454
      public String getFieldName() {
4455
        return _fieldName;
4456
      }
4457
    }
4458
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
4459
    }});
4460
 
4461
    static {
4462
      FieldMetaData.addStructMetaDataMap(updateTicket_result.class, metaDataMap);
4463
    }
4464
 
4465
    public updateTicket_result() {
4466
    }
4467
 
4468
    /**
4469
     * Performs a deep copy on <i>other</i>.
4470
     */
4471
    public updateTicket_result(updateTicket_result other) {
4472
    }
4473
 
4474
    public updateTicket_result deepCopy() {
4475
      return new updateTicket_result(this);
4476
    }
4477
 
4478
    @Deprecated
4479
    public updateTicket_result clone() {
4480
      return new updateTicket_result(this);
4481
    }
4482
 
4483
    public void setFieldValue(_Fields field, Object value) {
4484
      switch (field) {
4485
      }
4486
    }
4487
 
4488
    public void setFieldValue(int fieldID, Object value) {
4489
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
4490
    }
4491
 
4492
    public Object getFieldValue(_Fields field) {
4493
      switch (field) {
4494
      }
4495
      throw new IllegalStateException();
4496
    }
4497
 
4498
    public Object getFieldValue(int fieldId) {
4499
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
4500
    }
4501
 
4502
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
4503
    public boolean isSet(_Fields field) {
4504
      switch (field) {
4505
      }
4506
      throw new IllegalStateException();
4507
    }
4508
 
4509
    public boolean isSet(int fieldID) {
4510
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
4511
    }
4512
 
4513
    @Override
4514
    public boolean equals(Object that) {
4515
      if (that == null)
4516
        return false;
4517
      if (that instanceof updateTicket_result)
4518
        return this.equals((updateTicket_result)that);
4519
      return false;
4520
    }
4521
 
4522
    public boolean equals(updateTicket_result that) {
4523
      if (that == null)
4524
        return false;
4525
 
4526
      return true;
4527
    }
4528
 
4529
    @Override
4530
    public int hashCode() {
4531
      return 0;
4532
    }
4533
 
4534
    public int compareTo(updateTicket_result other) {
4535
      if (!getClass().equals(other.getClass())) {
4536
        return getClass().getName().compareTo(other.getClass().getName());
4537
      }
4538
 
4539
      int lastComparison = 0;
4540
      updateTicket_result typedOther = (updateTicket_result)other;
4541
 
4542
      return 0;
4543
    }
4544
 
4545
    public void read(TProtocol iprot) throws TException {
4546
      TField field;
4547
      iprot.readStructBegin();
4548
      while (true)
4549
      {
4550
        field = iprot.readFieldBegin();
4551
        if (field.type == TType.STOP) { 
4552
          break;
4553
        }
4554
        _Fields fieldId = _Fields.findByThriftId(field.id);
4555
        if (fieldId == null) {
4556
          TProtocolUtil.skip(iprot, field.type);
4557
        } else {
4558
          switch (fieldId) {
4559
          }
4560
          iprot.readFieldEnd();
4561
        }
4562
      }
4563
      iprot.readStructEnd();
4564
      validate();
4565
    }
4566
 
4567
    public void write(TProtocol oprot) throws TException {
4568
      oprot.writeStructBegin(STRUCT_DESC);
4569
 
4570
      oprot.writeFieldStop();
4571
      oprot.writeStructEnd();
4572
    }
4573
 
4574
    @Override
4575
    public String toString() {
4576
      StringBuilder sb = new StringBuilder("updateTicket_result(");
4577
      boolean first = true;
4578
 
4579
      sb.append(")");
4580
      return sb.toString();
4581
    }
4582
 
4583
    public void validate() throws TException {
4584
      // check for required fields
4585
    }
4586
 
4587
  }
4588
 
4589
  public static class insertTicket_args implements TBase<insertTicket_args._Fields>, java.io.Serializable, Cloneable, Comparable<insertTicket_args>   {
4590
    private static final TStruct STRUCT_DESC = new TStruct("insertTicket_args");
4591
 
4592
    private static final TField TICKET_FIELD_DESC = new TField("ticket", TType.STRUCT, (short)1);
3206 mandeep.dh 4593
    private static final TField ACTIVITY_FIELD_DESC = new TField("activity", TType.STRUCT, (short)2);
3028 mandeep.dh 4594
 
4595
    private Ticket ticket;
3206 mandeep.dh 4596
    private Activity activity;
3028 mandeep.dh 4597
 
4598
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
4599
    public enum _Fields implements TFieldIdEnum {
3206 mandeep.dh 4600
      TICKET((short)1, "ticket"),
4601
      ACTIVITY((short)2, "activity");
3028 mandeep.dh 4602
 
4603
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
4604
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4605
 
4606
      static {
4607
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4608
          byId.put((int)field._thriftId, field);
4609
          byName.put(field.getFieldName(), field);
4610
        }
4611
      }
4612
 
4613
      /**
4614
       * Find the _Fields constant that matches fieldId, or null if its not found.
4615
       */
4616
      public static _Fields findByThriftId(int fieldId) {
4617
        return byId.get(fieldId);
4618
      }
4619
 
4620
      /**
4621
       * Find the _Fields constant that matches fieldId, throwing an exception
4622
       * if it is not found.
4623
       */
4624
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4625
        _Fields fields = findByThriftId(fieldId);
4626
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4627
        return fields;
4628
      }
4629
 
4630
      /**
4631
       * Find the _Fields constant that matches name, or null if its not found.
4632
       */
4633
      public static _Fields findByName(String name) {
4634
        return byName.get(name);
4635
      }
4636
 
4637
      private final short _thriftId;
4638
      private final String _fieldName;
4639
 
4640
      _Fields(short thriftId, String fieldName) {
4641
        _thriftId = thriftId;
4642
        _fieldName = fieldName;
4643
      }
4644
 
4645
      public short getThriftFieldId() {
4646
        return _thriftId;
4647
      }
4648
 
4649
      public String getFieldName() {
4650
        return _fieldName;
4651
      }
4652
    }
4653
 
4654
    // isset id assignments
4655
 
4656
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
4657
      put(_Fields.TICKET, new FieldMetaData("ticket", TFieldRequirementType.DEFAULT, 
4658
          new StructMetaData(TType.STRUCT, Ticket.class)));
3206 mandeep.dh 4659
      put(_Fields.ACTIVITY, new FieldMetaData("activity", TFieldRequirementType.DEFAULT, 
4660
          new StructMetaData(TType.STRUCT, Activity.class)));
3028 mandeep.dh 4661
    }});
4662
 
4663
    static {
4664
      FieldMetaData.addStructMetaDataMap(insertTicket_args.class, metaDataMap);
4665
    }
4666
 
4667
    public insertTicket_args() {
4668
    }
4669
 
4670
    public insertTicket_args(
3206 mandeep.dh 4671
      Ticket ticket,
4672
      Activity activity)
3028 mandeep.dh 4673
    {
4674
      this();
4675
      this.ticket = ticket;
3206 mandeep.dh 4676
      this.activity = activity;
3028 mandeep.dh 4677
    }
4678
 
4679
    /**
4680
     * Performs a deep copy on <i>other</i>.
4681
     */
4682
    public insertTicket_args(insertTicket_args other) {
4683
      if (other.isSetTicket()) {
4684
        this.ticket = new Ticket(other.ticket);
4685
      }
3206 mandeep.dh 4686
      if (other.isSetActivity()) {
4687
        this.activity = new Activity(other.activity);
4688
      }
3028 mandeep.dh 4689
    }
4690
 
4691
    public insertTicket_args deepCopy() {
4692
      return new insertTicket_args(this);
4693
    }
4694
 
4695
    @Deprecated
4696
    public insertTicket_args clone() {
4697
      return new insertTicket_args(this);
4698
    }
4699
 
4700
    public Ticket getTicket() {
4701
      return this.ticket;
4702
    }
4703
 
4704
    public insertTicket_args setTicket(Ticket ticket) {
4705
      this.ticket = ticket;
4706
      return this;
4707
    }
4708
 
4709
    public void unsetTicket() {
4710
      this.ticket = null;
4711
    }
4712
 
4713
    /** Returns true if field ticket is set (has been asigned a value) and false otherwise */
4714
    public boolean isSetTicket() {
4715
      return this.ticket != null;
4716
    }
4717
 
4718
    public void setTicketIsSet(boolean value) {
4719
      if (!value) {
4720
        this.ticket = null;
4721
      }
4722
    }
4723
 
3206 mandeep.dh 4724
    public Activity getActivity() {
4725
      return this.activity;
4726
    }
4727
 
4728
    public insertTicket_args setActivity(Activity activity) {
4729
      this.activity = activity;
4730
      return this;
4731
    }
4732
 
4733
    public void unsetActivity() {
4734
      this.activity = null;
4735
    }
4736
 
4737
    /** Returns true if field activity is set (has been asigned a value) and false otherwise */
4738
    public boolean isSetActivity() {
4739
      return this.activity != null;
4740
    }
4741
 
4742
    public void setActivityIsSet(boolean value) {
4743
      if (!value) {
4744
        this.activity = null;
4745
      }
4746
    }
4747
 
3028 mandeep.dh 4748
    public void setFieldValue(_Fields field, Object value) {
4749
      switch (field) {
4750
      case TICKET:
4751
        if (value == null) {
4752
          unsetTicket();
4753
        } else {
4754
          setTicket((Ticket)value);
4755
        }
4756
        break;
4757
 
3206 mandeep.dh 4758
      case ACTIVITY:
4759
        if (value == null) {
4760
          unsetActivity();
4761
        } else {
4762
          setActivity((Activity)value);
4763
        }
4764
        break;
4765
 
3028 mandeep.dh 4766
      }
4767
    }
4768
 
4769
    public void setFieldValue(int fieldID, Object value) {
4770
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
4771
    }
4772
 
4773
    public Object getFieldValue(_Fields field) {
4774
      switch (field) {
4775
      case TICKET:
4776
        return getTicket();
4777
 
3206 mandeep.dh 4778
      case ACTIVITY:
4779
        return getActivity();
4780
 
3028 mandeep.dh 4781
      }
4782
      throw new IllegalStateException();
4783
    }
4784
 
4785
    public Object getFieldValue(int fieldId) {
4786
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
4787
    }
4788
 
4789
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
4790
    public boolean isSet(_Fields field) {
4791
      switch (field) {
4792
      case TICKET:
4793
        return isSetTicket();
3206 mandeep.dh 4794
      case ACTIVITY:
4795
        return isSetActivity();
3028 mandeep.dh 4796
      }
4797
      throw new IllegalStateException();
4798
    }
4799
 
4800
    public boolean isSet(int fieldID) {
4801
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
4802
    }
4803
 
4804
    @Override
4805
    public boolean equals(Object that) {
4806
      if (that == null)
4807
        return false;
4808
      if (that instanceof insertTicket_args)
4809
        return this.equals((insertTicket_args)that);
4810
      return false;
4811
    }
4812
 
4813
    public boolean equals(insertTicket_args that) {
4814
      if (that == null)
4815
        return false;
4816
 
4817
      boolean this_present_ticket = true && this.isSetTicket();
4818
      boolean that_present_ticket = true && that.isSetTicket();
4819
      if (this_present_ticket || that_present_ticket) {
4820
        if (!(this_present_ticket && that_present_ticket))
4821
          return false;
4822
        if (!this.ticket.equals(that.ticket))
4823
          return false;
4824
      }
4825
 
3206 mandeep.dh 4826
      boolean this_present_activity = true && this.isSetActivity();
4827
      boolean that_present_activity = true && that.isSetActivity();
4828
      if (this_present_activity || that_present_activity) {
4829
        if (!(this_present_activity && that_present_activity))
4830
          return false;
4831
        if (!this.activity.equals(that.activity))
4832
          return false;
4833
      }
4834
 
3028 mandeep.dh 4835
      return true;
4836
    }
4837
 
4838
    @Override
4839
    public int hashCode() {
4840
      return 0;
4841
    }
4842
 
4843
    public int compareTo(insertTicket_args other) {
4844
      if (!getClass().equals(other.getClass())) {
4845
        return getClass().getName().compareTo(other.getClass().getName());
4846
      }
4847
 
4848
      int lastComparison = 0;
4849
      insertTicket_args typedOther = (insertTicket_args)other;
4850
 
4851
      lastComparison = Boolean.valueOf(isSetTicket()).compareTo(isSetTicket());
4852
      if (lastComparison != 0) {
4853
        return lastComparison;
4854
      }
4855
      lastComparison = TBaseHelper.compareTo(ticket, typedOther.ticket);
4856
      if (lastComparison != 0) {
4857
        return lastComparison;
4858
      }
3206 mandeep.dh 4859
      lastComparison = Boolean.valueOf(isSetActivity()).compareTo(isSetActivity());
4860
      if (lastComparison != 0) {
4861
        return lastComparison;
4862
      }
4863
      lastComparison = TBaseHelper.compareTo(activity, typedOther.activity);
4864
      if (lastComparison != 0) {
4865
        return lastComparison;
4866
      }
3028 mandeep.dh 4867
      return 0;
4868
    }
4869
 
4870
    public void read(TProtocol iprot) throws TException {
4871
      TField field;
4872
      iprot.readStructBegin();
4873
      while (true)
4874
      {
4875
        field = iprot.readFieldBegin();
4876
        if (field.type == TType.STOP) { 
4877
          break;
4878
        }
4879
        _Fields fieldId = _Fields.findByThriftId(field.id);
4880
        if (fieldId == null) {
4881
          TProtocolUtil.skip(iprot, field.type);
4882
        } else {
4883
          switch (fieldId) {
4884
            case TICKET:
4885
              if (field.type == TType.STRUCT) {
4886
                this.ticket = new Ticket();
4887
                this.ticket.read(iprot);
4888
              } else { 
4889
                TProtocolUtil.skip(iprot, field.type);
4890
              }
4891
              break;
3206 mandeep.dh 4892
            case ACTIVITY:
4893
              if (field.type == TType.STRUCT) {
4894
                this.activity = new Activity();
4895
                this.activity.read(iprot);
4896
              } else { 
4897
                TProtocolUtil.skip(iprot, field.type);
4898
              }
4899
              break;
3028 mandeep.dh 4900
          }
4901
          iprot.readFieldEnd();
4902
        }
4903
      }
4904
      iprot.readStructEnd();
4905
      validate();
4906
    }
4907
 
4908
    public void write(TProtocol oprot) throws TException {
4909
      validate();
4910
 
4911
      oprot.writeStructBegin(STRUCT_DESC);
4912
      if (this.ticket != null) {
4913
        oprot.writeFieldBegin(TICKET_FIELD_DESC);
4914
        this.ticket.write(oprot);
4915
        oprot.writeFieldEnd();
4916
      }
3206 mandeep.dh 4917
      if (this.activity != null) {
4918
        oprot.writeFieldBegin(ACTIVITY_FIELD_DESC);
4919
        this.activity.write(oprot);
4920
        oprot.writeFieldEnd();
4921
      }
3028 mandeep.dh 4922
      oprot.writeFieldStop();
4923
      oprot.writeStructEnd();
4924
    }
4925
 
4926
    @Override
4927
    public String toString() {
4928
      StringBuilder sb = new StringBuilder("insertTicket_args(");
4929
      boolean first = true;
4930
 
4931
      sb.append("ticket:");
4932
      if (this.ticket == null) {
4933
        sb.append("null");
4934
      } else {
4935
        sb.append(this.ticket);
4936
      }
4937
      first = false;
3206 mandeep.dh 4938
      if (!first) sb.append(", ");
4939
      sb.append("activity:");
4940
      if (this.activity == null) {
4941
        sb.append("null");
4942
      } else {
4943
        sb.append(this.activity);
4944
      }
4945
      first = false;
3028 mandeep.dh 4946
      sb.append(")");
4947
      return sb.toString();
4948
    }
4949
 
4950
    public void validate() throws TException {
4951
      // check for required fields
4952
    }
4953
 
4954
  }
4955
 
4956
  public static class insertTicket_result implements TBase<insertTicket_result._Fields>, java.io.Serializable, Cloneable, Comparable<insertTicket_result>   {
4957
    private static final TStruct STRUCT_DESC = new TStruct("insertTicket_result");
4958
 
4959
    private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.I64, (short)0);
4960
 
4961
    private long success;
4962
 
4963
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
4964
    public enum _Fields implements TFieldIdEnum {
4965
      SUCCESS((short)0, "success");
4966
 
4967
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
4968
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4969
 
4970
      static {
4971
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4972
          byId.put((int)field._thriftId, field);
4973
          byName.put(field.getFieldName(), field);
4974
        }
4975
      }
4976
 
4977
      /**
4978
       * Find the _Fields constant that matches fieldId, or null if its not found.
4979
       */
4980
      public static _Fields findByThriftId(int fieldId) {
4981
        return byId.get(fieldId);
4982
      }
4983
 
4984
      /**
4985
       * Find the _Fields constant that matches fieldId, throwing an exception
4986
       * if it is not found.
4987
       */
4988
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4989
        _Fields fields = findByThriftId(fieldId);
4990
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4991
        return fields;
4992
      }
4993
 
4994
      /**
4995
       * Find the _Fields constant that matches name, or null if its not found.
4996
       */
4997
      public static _Fields findByName(String name) {
4998
        return byName.get(name);
4999
      }
5000
 
5001
      private final short _thriftId;
5002
      private final String _fieldName;
5003
 
5004
      _Fields(short thriftId, String fieldName) {
5005
        _thriftId = thriftId;
5006
        _fieldName = fieldName;
5007
      }
5008
 
5009
      public short getThriftFieldId() {
5010
        return _thriftId;
5011
      }
5012
 
5013
      public String getFieldName() {
5014
        return _fieldName;
5015
      }
5016
    }
5017
 
5018
    // isset id assignments
5019
    private static final int __SUCCESS_ISSET_ID = 0;
5020
    private BitSet __isset_bit_vector = new BitSet(1);
5021
 
5022
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
5023
      put(_Fields.SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, 
5024
          new FieldValueMetaData(TType.I64)));
5025
    }});
5026
 
5027
    static {
5028
      FieldMetaData.addStructMetaDataMap(insertTicket_result.class, metaDataMap);
5029
    }
5030
 
5031
    public insertTicket_result() {
5032
    }
5033
 
5034
    public insertTicket_result(
5035
      long success)
5036
    {
5037
      this();
5038
      this.success = success;
5039
      setSuccessIsSet(true);
5040
    }
5041
 
5042
    /**
5043
     * Performs a deep copy on <i>other</i>.
5044
     */
5045
    public insertTicket_result(insertTicket_result other) {
5046
      __isset_bit_vector.clear();
5047
      __isset_bit_vector.or(other.__isset_bit_vector);
5048
      this.success = other.success;
5049
    }
5050
 
5051
    public insertTicket_result deepCopy() {
5052
      return new insertTicket_result(this);
5053
    }
5054
 
5055
    @Deprecated
5056
    public insertTicket_result clone() {
5057
      return new insertTicket_result(this);
5058
    }
5059
 
5060
    public long getSuccess() {
5061
      return this.success;
5062
    }
5063
 
5064
    public insertTicket_result setSuccess(long success) {
5065
      this.success = success;
5066
      setSuccessIsSet(true);
5067
      return this;
5068
    }
5069
 
5070
    public void unsetSuccess() {
5071
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
5072
    }
5073
 
5074
    /** Returns true if field success is set (has been asigned a value) and false otherwise */
5075
    public boolean isSetSuccess() {
5076
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
5077
    }
5078
 
5079
    public void setSuccessIsSet(boolean value) {
5080
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
5081
    }
5082
 
5083
    public void setFieldValue(_Fields field, Object value) {
5084
      switch (field) {
5085
      case SUCCESS:
5086
        if (value == null) {
5087
          unsetSuccess();
5088
        } else {
5089
          setSuccess((Long)value);
5090
        }
5091
        break;
5092
 
5093
      }
5094
    }
5095
 
5096
    public void setFieldValue(int fieldID, Object value) {
5097
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
5098
    }
5099
 
5100
    public Object getFieldValue(_Fields field) {
5101
      switch (field) {
5102
      case SUCCESS:
5103
        return new Long(getSuccess());
5104
 
5105
      }
5106
      throw new IllegalStateException();
5107
    }
5108
 
5109
    public Object getFieldValue(int fieldId) {
5110
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
5111
    }
5112
 
5113
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
5114
    public boolean isSet(_Fields field) {
5115
      switch (field) {
5116
      case SUCCESS:
5117
        return isSetSuccess();
5118
      }
5119
      throw new IllegalStateException();
5120
    }
5121
 
5122
    public boolean isSet(int fieldID) {
5123
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
5124
    }
5125
 
5126
    @Override
5127
    public boolean equals(Object that) {
5128
      if (that == null)
5129
        return false;
5130
      if (that instanceof insertTicket_result)
5131
        return this.equals((insertTicket_result)that);
5132
      return false;
5133
    }
5134
 
5135
    public boolean equals(insertTicket_result that) {
5136
      if (that == null)
5137
        return false;
5138
 
5139
      boolean this_present_success = true;
5140
      boolean that_present_success = true;
5141
      if (this_present_success || that_present_success) {
5142
        if (!(this_present_success && that_present_success))
5143
          return false;
5144
        if (this.success != that.success)
5145
          return false;
5146
      }
5147
 
5148
      return true;
5149
    }
5150
 
5151
    @Override
5152
    public int hashCode() {
5153
      return 0;
5154
    }
5155
 
5156
    public int compareTo(insertTicket_result other) {
5157
      if (!getClass().equals(other.getClass())) {
5158
        return getClass().getName().compareTo(other.getClass().getName());
5159
      }
5160
 
5161
      int lastComparison = 0;
5162
      insertTicket_result typedOther = (insertTicket_result)other;
5163
 
5164
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(isSetSuccess());
5165
      if (lastComparison != 0) {
5166
        return lastComparison;
5167
      }
5168
      lastComparison = TBaseHelper.compareTo(success, typedOther.success);
5169
      if (lastComparison != 0) {
5170
        return lastComparison;
5171
      }
5172
      return 0;
5173
    }
5174
 
5175
    public void read(TProtocol iprot) throws TException {
5176
      TField field;
5177
      iprot.readStructBegin();
5178
      while (true)
5179
      {
5180
        field = iprot.readFieldBegin();
5181
        if (field.type == TType.STOP) { 
5182
          break;
5183
        }
5184
        _Fields fieldId = _Fields.findByThriftId(field.id);
5185
        if (fieldId == null) {
5186
          TProtocolUtil.skip(iprot, field.type);
5187
        } else {
5188
          switch (fieldId) {
5189
            case SUCCESS:
5190
              if (field.type == TType.I64) {
5191
                this.success = iprot.readI64();
5192
                setSuccessIsSet(true);
5193
              } else { 
5194
                TProtocolUtil.skip(iprot, field.type);
5195
              }
5196
              break;
5197
          }
5198
          iprot.readFieldEnd();
5199
        }
5200
      }
5201
      iprot.readStructEnd();
5202
      validate();
5203
    }
5204
 
5205
    public void write(TProtocol oprot) throws TException {
5206
      oprot.writeStructBegin(STRUCT_DESC);
5207
 
5208
      if (this.isSetSuccess()) {
5209
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
5210
        oprot.writeI64(this.success);
5211
        oprot.writeFieldEnd();
5212
      }
5213
      oprot.writeFieldStop();
5214
      oprot.writeStructEnd();
5215
    }
5216
 
5217
    @Override
5218
    public String toString() {
5219
      StringBuilder sb = new StringBuilder("insertTicket_result(");
5220
      boolean first = true;
5221
 
5222
      sb.append("success:");
5223
      sb.append(this.success);
5224
      first = false;
5225
      sb.append(")");
5226
      return sb.toString();
5227
    }
5228
 
5229
    public void validate() throws TException {
5230
      // check for required fields
5231
    }
5232
 
5233
  }
5234
 
5235
  public static class getActivities_args implements TBase<getActivities_args._Fields>, java.io.Serializable, Cloneable, Comparable<getActivities_args>   {
5236
    private static final TStruct STRUCT_DESC = new TStruct("getActivities_args");
5237
 
5238
    private static final TField CUSTOMER_ID_FIELD_DESC = new TField("customerId", TType.I64, (short)1);
5239
 
5240
    private long customerId;
5241
 
5242
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
5243
    public enum _Fields implements TFieldIdEnum {
5244
      CUSTOMER_ID((short)1, "customerId");
5245
 
5246
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
5247
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5248
 
5249
      static {
5250
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5251
          byId.put((int)field._thriftId, field);
5252
          byName.put(field.getFieldName(), field);
5253
        }
5254
      }
5255
 
5256
      /**
5257
       * Find the _Fields constant that matches fieldId, or null if its not found.
5258
       */
5259
      public static _Fields findByThriftId(int fieldId) {
5260
        return byId.get(fieldId);
5261
      }
5262
 
5263
      /**
5264
       * Find the _Fields constant that matches fieldId, throwing an exception
5265
       * if it is not found.
5266
       */
5267
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5268
        _Fields fields = findByThriftId(fieldId);
5269
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5270
        return fields;
5271
      }
5272
 
5273
      /**
5274
       * Find the _Fields constant that matches name, or null if its not found.
5275
       */
5276
      public static _Fields findByName(String name) {
5277
        return byName.get(name);
5278
      }
5279
 
5280
      private final short _thriftId;
5281
      private final String _fieldName;
5282
 
5283
      _Fields(short thriftId, String fieldName) {
5284
        _thriftId = thriftId;
5285
        _fieldName = fieldName;
5286
      }
5287
 
5288
      public short getThriftFieldId() {
5289
        return _thriftId;
5290
      }
5291
 
5292
      public String getFieldName() {
5293
        return _fieldName;
5294
      }
5295
    }
5296
 
5297
    // isset id assignments
5298
    private static final int __CUSTOMERID_ISSET_ID = 0;
5299
    private BitSet __isset_bit_vector = new BitSet(1);
5300
 
5301
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
5302
      put(_Fields.CUSTOMER_ID, new FieldMetaData("customerId", TFieldRequirementType.DEFAULT, 
5303
          new FieldValueMetaData(TType.I64)));
5304
    }});
5305
 
5306
    static {
5307
      FieldMetaData.addStructMetaDataMap(getActivities_args.class, metaDataMap);
5308
    }
5309
 
5310
    public getActivities_args() {
5311
    }
5312
 
5313
    public getActivities_args(
5314
      long customerId)
5315
    {
5316
      this();
5317
      this.customerId = customerId;
5318
      setCustomerIdIsSet(true);
5319
    }
5320
 
5321
    /**
5322
     * Performs a deep copy on <i>other</i>.
5323
     */
5324
    public getActivities_args(getActivities_args other) {
5325
      __isset_bit_vector.clear();
5326
      __isset_bit_vector.or(other.__isset_bit_vector);
5327
      this.customerId = other.customerId;
5328
    }
5329
 
5330
    public getActivities_args deepCopy() {
5331
      return new getActivities_args(this);
5332
    }
5333
 
5334
    @Deprecated
5335
    public getActivities_args clone() {
5336
      return new getActivities_args(this);
5337
    }
5338
 
5339
    public long getCustomerId() {
5340
      return this.customerId;
5341
    }
5342
 
5343
    public getActivities_args setCustomerId(long customerId) {
5344
      this.customerId = customerId;
5345
      setCustomerIdIsSet(true);
5346
      return this;
5347
    }
5348
 
5349
    public void unsetCustomerId() {
5350
      __isset_bit_vector.clear(__CUSTOMERID_ISSET_ID);
5351
    }
5352
 
5353
    /** Returns true if field customerId is set (has been asigned a value) and false otherwise */
5354
    public boolean isSetCustomerId() {
5355
      return __isset_bit_vector.get(__CUSTOMERID_ISSET_ID);
5356
    }
5357
 
5358
    public void setCustomerIdIsSet(boolean value) {
5359
      __isset_bit_vector.set(__CUSTOMERID_ISSET_ID, value);
5360
    }
5361
 
5362
    public void setFieldValue(_Fields field, Object value) {
5363
      switch (field) {
5364
      case CUSTOMER_ID:
5365
        if (value == null) {
5366
          unsetCustomerId();
5367
        } else {
5368
          setCustomerId((Long)value);
5369
        }
5370
        break;
5371
 
5372
      }
5373
    }
5374
 
5375
    public void setFieldValue(int fieldID, Object value) {
5376
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
5377
    }
5378
 
5379
    public Object getFieldValue(_Fields field) {
5380
      switch (field) {
5381
      case CUSTOMER_ID:
5382
        return new Long(getCustomerId());
5383
 
5384
      }
5385
      throw new IllegalStateException();
5386
    }
5387
 
5388
    public Object getFieldValue(int fieldId) {
5389
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
5390
    }
5391
 
5392
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
5393
    public boolean isSet(_Fields field) {
5394
      switch (field) {
5395
      case CUSTOMER_ID:
5396
        return isSetCustomerId();
5397
      }
5398
      throw new IllegalStateException();
5399
    }
5400
 
5401
    public boolean isSet(int fieldID) {
5402
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
5403
    }
5404
 
5405
    @Override
5406
    public boolean equals(Object that) {
5407
      if (that == null)
5408
        return false;
5409
      if (that instanceof getActivities_args)
5410
        return this.equals((getActivities_args)that);
5411
      return false;
5412
    }
5413
 
5414
    public boolean equals(getActivities_args that) {
5415
      if (that == null)
5416
        return false;
5417
 
5418
      boolean this_present_customerId = true;
5419
      boolean that_present_customerId = true;
5420
      if (this_present_customerId || that_present_customerId) {
5421
        if (!(this_present_customerId && that_present_customerId))
5422
          return false;
5423
        if (this.customerId != that.customerId)
5424
          return false;
5425
      }
5426
 
5427
      return true;
5428
    }
5429
 
5430
    @Override
5431
    public int hashCode() {
5432
      return 0;
5433
    }
5434
 
5435
    public int compareTo(getActivities_args other) {
5436
      if (!getClass().equals(other.getClass())) {
5437
        return getClass().getName().compareTo(other.getClass().getName());
5438
      }
5439
 
5440
      int lastComparison = 0;
5441
      getActivities_args typedOther = (getActivities_args)other;
5442
 
5443
      lastComparison = Boolean.valueOf(isSetCustomerId()).compareTo(isSetCustomerId());
5444
      if (lastComparison != 0) {
5445
        return lastComparison;
5446
      }
5447
      lastComparison = TBaseHelper.compareTo(customerId, typedOther.customerId);
5448
      if (lastComparison != 0) {
5449
        return lastComparison;
5450
      }
5451
      return 0;
5452
    }
5453
 
5454
    public void read(TProtocol iprot) throws TException {
5455
      TField field;
5456
      iprot.readStructBegin();
5457
      while (true)
5458
      {
5459
        field = iprot.readFieldBegin();
5460
        if (field.type == TType.STOP) { 
5461
          break;
5462
        }
5463
        _Fields fieldId = _Fields.findByThriftId(field.id);
5464
        if (fieldId == null) {
5465
          TProtocolUtil.skip(iprot, field.type);
5466
        } else {
5467
          switch (fieldId) {
5468
            case CUSTOMER_ID:
5469
              if (field.type == TType.I64) {
5470
                this.customerId = iprot.readI64();
5471
                setCustomerIdIsSet(true);
5472
              } else { 
5473
                TProtocolUtil.skip(iprot, field.type);
5474
              }
5475
              break;
5476
          }
5477
          iprot.readFieldEnd();
5478
        }
5479
      }
5480
      iprot.readStructEnd();
5481
      validate();
5482
    }
5483
 
5484
    public void write(TProtocol oprot) throws TException {
5485
      validate();
5486
 
5487
      oprot.writeStructBegin(STRUCT_DESC);
5488
      oprot.writeFieldBegin(CUSTOMER_ID_FIELD_DESC);
5489
      oprot.writeI64(this.customerId);
5490
      oprot.writeFieldEnd();
5491
      oprot.writeFieldStop();
5492
      oprot.writeStructEnd();
5493
    }
5494
 
5495
    @Override
5496
    public String toString() {
5497
      StringBuilder sb = new StringBuilder("getActivities_args(");
5498
      boolean first = true;
5499
 
5500
      sb.append("customerId:");
5501
      sb.append(this.customerId);
5502
      first = false;
5503
      sb.append(")");
5504
      return sb.toString();
5505
    }
5506
 
5507
    public void validate() throws TException {
5508
      // check for required fields
5509
    }
5510
 
5511
  }
5512
 
5513
  public static class getActivities_result implements TBase<getActivities_result._Fields>, java.io.Serializable, Cloneable, Comparable<getActivities_result>   {
5514
    private static final TStruct STRUCT_DESC = new TStruct("getActivities_result");
5515
 
5516
    private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.LIST, (short)0);
5517
 
5518
    private List<Activity> success;
5519
 
5520
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
5521
    public enum _Fields implements TFieldIdEnum {
5522
      SUCCESS((short)0, "success");
5523
 
5524
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
5525
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5526
 
5527
      static {
5528
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5529
          byId.put((int)field._thriftId, field);
5530
          byName.put(field.getFieldName(), field);
5531
        }
5532
      }
5533
 
5534
      /**
5535
       * Find the _Fields constant that matches fieldId, or null if its not found.
5536
       */
5537
      public static _Fields findByThriftId(int fieldId) {
5538
        return byId.get(fieldId);
5539
      }
5540
 
5541
      /**
5542
       * Find the _Fields constant that matches fieldId, throwing an exception
5543
       * if it is not found.
5544
       */
5545
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5546
        _Fields fields = findByThriftId(fieldId);
5547
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5548
        return fields;
5549
      }
5550
 
5551
      /**
5552
       * Find the _Fields constant that matches name, or null if its not found.
5553
       */
5554
      public static _Fields findByName(String name) {
5555
        return byName.get(name);
5556
      }
5557
 
5558
      private final short _thriftId;
5559
      private final String _fieldName;
5560
 
5561
      _Fields(short thriftId, String fieldName) {
5562
        _thriftId = thriftId;
5563
        _fieldName = fieldName;
5564
      }
5565
 
5566
      public short getThriftFieldId() {
5567
        return _thriftId;
5568
      }
5569
 
5570
      public String getFieldName() {
5571
        return _fieldName;
5572
      }
5573
    }
5574
 
5575
    // isset id assignments
5576
 
5577
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
5578
      put(_Fields.SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, 
5579
          new ListMetaData(TType.LIST, 
5580
              new StructMetaData(TType.STRUCT, Activity.class))));
5581
    }});
5582
 
5583
    static {
5584
      FieldMetaData.addStructMetaDataMap(getActivities_result.class, metaDataMap);
5585
    }
5586
 
5587
    public getActivities_result() {
5588
    }
5589
 
5590
    public getActivities_result(
5591
      List<Activity> success)
5592
    {
5593
      this();
5594
      this.success = success;
5595
    }
5596
 
5597
    /**
5598
     * Performs a deep copy on <i>other</i>.
5599
     */
5600
    public getActivities_result(getActivities_result other) {
5601
      if (other.isSetSuccess()) {
5602
        List<Activity> __this__success = new ArrayList<Activity>();
5603
        for (Activity other_element : other.success) {
5604
          __this__success.add(new Activity(other_element));
5605
        }
5606
        this.success = __this__success;
5607
      }
5608
    }
5609
 
5610
    public getActivities_result deepCopy() {
5611
      return new getActivities_result(this);
5612
    }
5613
 
5614
    @Deprecated
5615
    public getActivities_result clone() {
5616
      return new getActivities_result(this);
5617
    }
5618
 
5619
    public int getSuccessSize() {
5620
      return (this.success == null) ? 0 : this.success.size();
5621
    }
5622
 
5623
    public java.util.Iterator<Activity> getSuccessIterator() {
5624
      return (this.success == null) ? null : this.success.iterator();
5625
    }
5626
 
5627
    public void addToSuccess(Activity elem) {
5628
      if (this.success == null) {
5629
        this.success = new ArrayList<Activity>();
5630
      }
5631
      this.success.add(elem);
5632
    }
5633
 
5634
    public List<Activity> getSuccess() {
5635
      return this.success;
5636
    }
5637
 
5638
    public getActivities_result setSuccess(List<Activity> success) {
5639
      this.success = success;
5640
      return this;
5641
    }
5642
 
5643
    public void unsetSuccess() {
5644
      this.success = null;
5645
    }
5646
 
5647
    /** Returns true if field success is set (has been asigned a value) and false otherwise */
5648
    public boolean isSetSuccess() {
5649
      return this.success != null;
5650
    }
5651
 
5652
    public void setSuccessIsSet(boolean value) {
5653
      if (!value) {
5654
        this.success = null;
5655
      }
5656
    }
5657
 
5658
    public void setFieldValue(_Fields field, Object value) {
5659
      switch (field) {
5660
      case SUCCESS:
5661
        if (value == null) {
5662
          unsetSuccess();
5663
        } else {
5664
          setSuccess((List<Activity>)value);
5665
        }
5666
        break;
5667
 
5668
      }
5669
    }
5670
 
5671
    public void setFieldValue(int fieldID, Object value) {
5672
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
5673
    }
5674
 
5675
    public Object getFieldValue(_Fields field) {
5676
      switch (field) {
5677
      case SUCCESS:
5678
        return getSuccess();
5679
 
5680
      }
5681
      throw new IllegalStateException();
5682
    }
5683
 
5684
    public Object getFieldValue(int fieldId) {
5685
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
5686
    }
5687
 
5688
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
5689
    public boolean isSet(_Fields field) {
5690
      switch (field) {
5691
      case SUCCESS:
5692
        return isSetSuccess();
5693
      }
5694
      throw new IllegalStateException();
5695
    }
5696
 
5697
    public boolean isSet(int fieldID) {
5698
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
5699
    }
5700
 
5701
    @Override
5702
    public boolean equals(Object that) {
5703
      if (that == null)
5704
        return false;
5705
      if (that instanceof getActivities_result)
5706
        return this.equals((getActivities_result)that);
5707
      return false;
5708
    }
5709
 
5710
    public boolean equals(getActivities_result that) {
5711
      if (that == null)
5712
        return false;
5713
 
5714
      boolean this_present_success = true && this.isSetSuccess();
5715
      boolean that_present_success = true && that.isSetSuccess();
5716
      if (this_present_success || that_present_success) {
5717
        if (!(this_present_success && that_present_success))
5718
          return false;
5719
        if (!this.success.equals(that.success))
5720
          return false;
5721
      }
5722
 
5723
      return true;
5724
    }
5725
 
5726
    @Override
5727
    public int hashCode() {
5728
      return 0;
5729
    }
5730
 
5731
    public int compareTo(getActivities_result other) {
5732
      if (!getClass().equals(other.getClass())) {
5733
        return getClass().getName().compareTo(other.getClass().getName());
5734
      }
5735
 
5736
      int lastComparison = 0;
5737
      getActivities_result typedOther = (getActivities_result)other;
5738
 
5739
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(isSetSuccess());
5740
      if (lastComparison != 0) {
5741
        return lastComparison;
5742
      }
5743
      lastComparison = TBaseHelper.compareTo(success, typedOther.success);
5744
      if (lastComparison != 0) {
5745
        return lastComparison;
5746
      }
5747
      return 0;
5748
    }
5749
 
5750
    public void read(TProtocol iprot) throws TException {
5751
      TField field;
5752
      iprot.readStructBegin();
5753
      while (true)
5754
      {
5755
        field = iprot.readFieldBegin();
5756
        if (field.type == TType.STOP) { 
5757
          break;
5758
        }
5759
        _Fields fieldId = _Fields.findByThriftId(field.id);
5760
        if (fieldId == null) {
5761
          TProtocolUtil.skip(iprot, field.type);
5762
        } else {
5763
          switch (fieldId) {
5764
            case SUCCESS:
5765
              if (field.type == TType.LIST) {
5766
                {
3137 mandeep.dh 5767
                  TList _list16 = iprot.readListBegin();
5768
                  this.success = new ArrayList<Activity>(_list16.size);
5769
                  for (int _i17 = 0; _i17 < _list16.size; ++_i17)
3028 mandeep.dh 5770
                  {
3137 mandeep.dh 5771
                    Activity _elem18;
5772
                    _elem18 = new Activity();
5773
                    _elem18.read(iprot);
5774
                    this.success.add(_elem18);
3028 mandeep.dh 5775
                  }
5776
                  iprot.readListEnd();
5777
                }
5778
              } else { 
5779
                TProtocolUtil.skip(iprot, field.type);
5780
              }
5781
              break;
5782
          }
5783
          iprot.readFieldEnd();
5784
        }
5785
      }
5786
      iprot.readStructEnd();
5787
      validate();
5788
    }
5789
 
5790
    public void write(TProtocol oprot) throws TException {
5791
      oprot.writeStructBegin(STRUCT_DESC);
5792
 
5793
      if (this.isSetSuccess()) {
5794
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
5795
        {
5796
          oprot.writeListBegin(new TList(TType.STRUCT, this.success.size()));
3137 mandeep.dh 5797
          for (Activity _iter19 : this.success)
3028 mandeep.dh 5798
          {
3137 mandeep.dh 5799
            _iter19.write(oprot);
3028 mandeep.dh 5800
          }
5801
          oprot.writeListEnd();
5802
        }
5803
        oprot.writeFieldEnd();
5804
      }
5805
      oprot.writeFieldStop();
5806
      oprot.writeStructEnd();
5807
    }
5808
 
5809
    @Override
5810
    public String toString() {
5811
      StringBuilder sb = new StringBuilder("getActivities_result(");
5812
      boolean first = true;
5813
 
5814
      sb.append("success:");
5815
      if (this.success == null) {
5816
        sb.append("null");
5817
      } else {
5818
        sb.append(this.success);
5819
      }
5820
      first = false;
5821
      sb.append(")");
5822
      return sb.toString();
5823
    }
5824
 
5825
    public void validate() throws TException {
5826
      // check for required fields
5827
    }
5828
 
5829
  }
5830
 
3339 mandeep.dh 5831
  public static class getActivitiesByCreator_args implements TBase<getActivitiesByCreator_args._Fields>, java.io.Serializable, Cloneable, Comparable<getActivitiesByCreator_args>   {
5832
    private static final TStruct STRUCT_DESC = new TStruct("getActivitiesByCreator_args");
5833
 
5834
    private static final TField CREATOR_ID_FIELD_DESC = new TField("creatorId", TType.I64, (short)1);
5835
 
5836
    private long creatorId;
5837
 
5838
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
5839
    public enum _Fields implements TFieldIdEnum {
5840
      CREATOR_ID((short)1, "creatorId");
5841
 
5842
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
5843
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5844
 
5845
      static {
5846
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5847
          byId.put((int)field._thriftId, field);
5848
          byName.put(field.getFieldName(), field);
5849
        }
5850
      }
5851
 
5852
      /**
5853
       * Find the _Fields constant that matches fieldId, or null if its not found.
5854
       */
5855
      public static _Fields findByThriftId(int fieldId) {
5856
        return byId.get(fieldId);
5857
      }
5858
 
5859
      /**
5860
       * Find the _Fields constant that matches fieldId, throwing an exception
5861
       * if it is not found.
5862
       */
5863
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5864
        _Fields fields = findByThriftId(fieldId);
5865
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5866
        return fields;
5867
      }
5868
 
5869
      /**
5870
       * Find the _Fields constant that matches name, or null if its not found.
5871
       */
5872
      public static _Fields findByName(String name) {
5873
        return byName.get(name);
5874
      }
5875
 
5876
      private final short _thriftId;
5877
      private final String _fieldName;
5878
 
5879
      _Fields(short thriftId, String fieldName) {
5880
        _thriftId = thriftId;
5881
        _fieldName = fieldName;
5882
      }
5883
 
5884
      public short getThriftFieldId() {
5885
        return _thriftId;
5886
      }
5887
 
5888
      public String getFieldName() {
5889
        return _fieldName;
5890
      }
5891
    }
5892
 
5893
    // isset id assignments
5894
    private static final int __CREATORID_ISSET_ID = 0;
5895
    private BitSet __isset_bit_vector = new BitSet(1);
5896
 
5897
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
5898
      put(_Fields.CREATOR_ID, new FieldMetaData("creatorId", TFieldRequirementType.DEFAULT, 
5899
          new FieldValueMetaData(TType.I64)));
5900
    }});
5901
 
5902
    static {
5903
      FieldMetaData.addStructMetaDataMap(getActivitiesByCreator_args.class, metaDataMap);
5904
    }
5905
 
5906
    public getActivitiesByCreator_args() {
5907
    }
5908
 
5909
    public getActivitiesByCreator_args(
5910
      long creatorId)
5911
    {
5912
      this();
5913
      this.creatorId = creatorId;
5914
      setCreatorIdIsSet(true);
5915
    }
5916
 
5917
    /**
5918
     * Performs a deep copy on <i>other</i>.
5919
     */
5920
    public getActivitiesByCreator_args(getActivitiesByCreator_args other) {
5921
      __isset_bit_vector.clear();
5922
      __isset_bit_vector.or(other.__isset_bit_vector);
5923
      this.creatorId = other.creatorId;
5924
    }
5925
 
5926
    public getActivitiesByCreator_args deepCopy() {
5927
      return new getActivitiesByCreator_args(this);
5928
    }
5929
 
5930
    @Deprecated
5931
    public getActivitiesByCreator_args clone() {
5932
      return new getActivitiesByCreator_args(this);
5933
    }
5934
 
5935
    public long getCreatorId() {
5936
      return this.creatorId;
5937
    }
5938
 
5939
    public getActivitiesByCreator_args setCreatorId(long creatorId) {
5940
      this.creatorId = creatorId;
5941
      setCreatorIdIsSet(true);
5942
      return this;
5943
    }
5944
 
5945
    public void unsetCreatorId() {
5946
      __isset_bit_vector.clear(__CREATORID_ISSET_ID);
5947
    }
5948
 
5949
    /** Returns true if field creatorId is set (has been asigned a value) and false otherwise */
5950
    public boolean isSetCreatorId() {
5951
      return __isset_bit_vector.get(__CREATORID_ISSET_ID);
5952
    }
5953
 
5954
    public void setCreatorIdIsSet(boolean value) {
5955
      __isset_bit_vector.set(__CREATORID_ISSET_ID, value);
5956
    }
5957
 
5958
    public void setFieldValue(_Fields field, Object value) {
5959
      switch (field) {
5960
      case CREATOR_ID:
5961
        if (value == null) {
5962
          unsetCreatorId();
5963
        } else {
5964
          setCreatorId((Long)value);
5965
        }
5966
        break;
5967
 
5968
      }
5969
    }
5970
 
5971
    public void setFieldValue(int fieldID, Object value) {
5972
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
5973
    }
5974
 
5975
    public Object getFieldValue(_Fields field) {
5976
      switch (field) {
5977
      case CREATOR_ID:
5978
        return new Long(getCreatorId());
5979
 
5980
      }
5981
      throw new IllegalStateException();
5982
    }
5983
 
5984
    public Object getFieldValue(int fieldId) {
5985
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
5986
    }
5987
 
5988
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
5989
    public boolean isSet(_Fields field) {
5990
      switch (field) {
5991
      case CREATOR_ID:
5992
        return isSetCreatorId();
5993
      }
5994
      throw new IllegalStateException();
5995
    }
5996
 
5997
    public boolean isSet(int fieldID) {
5998
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
5999
    }
6000
 
6001
    @Override
6002
    public boolean equals(Object that) {
6003
      if (that == null)
6004
        return false;
6005
      if (that instanceof getActivitiesByCreator_args)
6006
        return this.equals((getActivitiesByCreator_args)that);
6007
      return false;
6008
    }
6009
 
6010
    public boolean equals(getActivitiesByCreator_args that) {
6011
      if (that == null)
6012
        return false;
6013
 
6014
      boolean this_present_creatorId = true;
6015
      boolean that_present_creatorId = true;
6016
      if (this_present_creatorId || that_present_creatorId) {
6017
        if (!(this_present_creatorId && that_present_creatorId))
6018
          return false;
6019
        if (this.creatorId != that.creatorId)
6020
          return false;
6021
      }
6022
 
6023
      return true;
6024
    }
6025
 
6026
    @Override
6027
    public int hashCode() {
6028
      return 0;
6029
    }
6030
 
6031
    public int compareTo(getActivitiesByCreator_args other) {
6032
      if (!getClass().equals(other.getClass())) {
6033
        return getClass().getName().compareTo(other.getClass().getName());
6034
      }
6035
 
6036
      int lastComparison = 0;
6037
      getActivitiesByCreator_args typedOther = (getActivitiesByCreator_args)other;
6038
 
6039
      lastComparison = Boolean.valueOf(isSetCreatorId()).compareTo(isSetCreatorId());
6040
      if (lastComparison != 0) {
6041
        return lastComparison;
6042
      }
6043
      lastComparison = TBaseHelper.compareTo(creatorId, typedOther.creatorId);
6044
      if (lastComparison != 0) {
6045
        return lastComparison;
6046
      }
6047
      return 0;
6048
    }
6049
 
6050
    public void read(TProtocol iprot) throws TException {
6051
      TField field;
6052
      iprot.readStructBegin();
6053
      while (true)
6054
      {
6055
        field = iprot.readFieldBegin();
6056
        if (field.type == TType.STOP) { 
6057
          break;
6058
        }
6059
        _Fields fieldId = _Fields.findByThriftId(field.id);
6060
        if (fieldId == null) {
6061
          TProtocolUtil.skip(iprot, field.type);
6062
        } else {
6063
          switch (fieldId) {
6064
            case CREATOR_ID:
6065
              if (field.type == TType.I64) {
6066
                this.creatorId = iprot.readI64();
6067
                setCreatorIdIsSet(true);
6068
              } else { 
6069
                TProtocolUtil.skip(iprot, field.type);
6070
              }
6071
              break;
6072
          }
6073
          iprot.readFieldEnd();
6074
        }
6075
      }
6076
      iprot.readStructEnd();
6077
      validate();
6078
    }
6079
 
6080
    public void write(TProtocol oprot) throws TException {
6081
      validate();
6082
 
6083
      oprot.writeStructBegin(STRUCT_DESC);
6084
      oprot.writeFieldBegin(CREATOR_ID_FIELD_DESC);
6085
      oprot.writeI64(this.creatorId);
6086
      oprot.writeFieldEnd();
6087
      oprot.writeFieldStop();
6088
      oprot.writeStructEnd();
6089
    }
6090
 
6091
    @Override
6092
    public String toString() {
6093
      StringBuilder sb = new StringBuilder("getActivitiesByCreator_args(");
6094
      boolean first = true;
6095
 
6096
      sb.append("creatorId:");
6097
      sb.append(this.creatorId);
6098
      first = false;
6099
      sb.append(")");
6100
      return sb.toString();
6101
    }
6102
 
6103
    public void validate() throws TException {
6104
      // check for required fields
6105
    }
6106
 
6107
  }
6108
 
6109
  public static class getActivitiesByCreator_result implements TBase<getActivitiesByCreator_result._Fields>, java.io.Serializable, Cloneable, Comparable<getActivitiesByCreator_result>   {
6110
    private static final TStruct STRUCT_DESC = new TStruct("getActivitiesByCreator_result");
6111
 
6112
    private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.LIST, (short)0);
6113
 
6114
    private List<Activity> success;
6115
 
6116
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
6117
    public enum _Fields implements TFieldIdEnum {
6118
      SUCCESS((short)0, "success");
6119
 
6120
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
6121
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6122
 
6123
      static {
6124
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6125
          byId.put((int)field._thriftId, field);
6126
          byName.put(field.getFieldName(), field);
6127
        }
6128
      }
6129
 
6130
      /**
6131
       * Find the _Fields constant that matches fieldId, or null if its not found.
6132
       */
6133
      public static _Fields findByThriftId(int fieldId) {
6134
        return byId.get(fieldId);
6135
      }
6136
 
6137
      /**
6138
       * Find the _Fields constant that matches fieldId, throwing an exception
6139
       * if it is not found.
6140
       */
6141
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6142
        _Fields fields = findByThriftId(fieldId);
6143
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6144
        return fields;
6145
      }
6146
 
6147
      /**
6148
       * Find the _Fields constant that matches name, or null if its not found.
6149
       */
6150
      public static _Fields findByName(String name) {
6151
        return byName.get(name);
6152
      }
6153
 
6154
      private final short _thriftId;
6155
      private final String _fieldName;
6156
 
6157
      _Fields(short thriftId, String fieldName) {
6158
        _thriftId = thriftId;
6159
        _fieldName = fieldName;
6160
      }
6161
 
6162
      public short getThriftFieldId() {
6163
        return _thriftId;
6164
      }
6165
 
6166
      public String getFieldName() {
6167
        return _fieldName;
6168
      }
6169
    }
6170
 
6171
    // isset id assignments
6172
 
6173
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
6174
      put(_Fields.SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, 
6175
          new ListMetaData(TType.LIST, 
6176
              new StructMetaData(TType.STRUCT, Activity.class))));
6177
    }});
6178
 
6179
    static {
6180
      FieldMetaData.addStructMetaDataMap(getActivitiesByCreator_result.class, metaDataMap);
6181
    }
6182
 
6183
    public getActivitiesByCreator_result() {
6184
    }
6185
 
6186
    public getActivitiesByCreator_result(
6187
      List<Activity> success)
6188
    {
6189
      this();
6190
      this.success = success;
6191
    }
6192
 
6193
    /**
6194
     * Performs a deep copy on <i>other</i>.
6195
     */
6196
    public getActivitiesByCreator_result(getActivitiesByCreator_result other) {
6197
      if (other.isSetSuccess()) {
6198
        List<Activity> __this__success = new ArrayList<Activity>();
6199
        for (Activity other_element : other.success) {
6200
          __this__success.add(new Activity(other_element));
6201
        }
6202
        this.success = __this__success;
6203
      }
6204
    }
6205
 
6206
    public getActivitiesByCreator_result deepCopy() {
6207
      return new getActivitiesByCreator_result(this);
6208
    }
6209
 
6210
    @Deprecated
6211
    public getActivitiesByCreator_result clone() {
6212
      return new getActivitiesByCreator_result(this);
6213
    }
6214
 
6215
    public int getSuccessSize() {
6216
      return (this.success == null) ? 0 : this.success.size();
6217
    }
6218
 
6219
    public java.util.Iterator<Activity> getSuccessIterator() {
6220
      return (this.success == null) ? null : this.success.iterator();
6221
    }
6222
 
6223
    public void addToSuccess(Activity elem) {
6224
      if (this.success == null) {
6225
        this.success = new ArrayList<Activity>();
6226
      }
6227
      this.success.add(elem);
6228
    }
6229
 
6230
    public List<Activity> getSuccess() {
6231
      return this.success;
6232
    }
6233
 
6234
    public getActivitiesByCreator_result setSuccess(List<Activity> success) {
6235
      this.success = success;
6236
      return this;
6237
    }
6238
 
6239
    public void unsetSuccess() {
6240
      this.success = null;
6241
    }
6242
 
6243
    /** Returns true if field success is set (has been asigned a value) and false otherwise */
6244
    public boolean isSetSuccess() {
6245
      return this.success != null;
6246
    }
6247
 
6248
    public void setSuccessIsSet(boolean value) {
6249
      if (!value) {
6250
        this.success = null;
6251
      }
6252
    }
6253
 
6254
    public void setFieldValue(_Fields field, Object value) {
6255
      switch (field) {
6256
      case SUCCESS:
6257
        if (value == null) {
6258
          unsetSuccess();
6259
        } else {
6260
          setSuccess((List<Activity>)value);
6261
        }
6262
        break;
6263
 
6264
      }
6265
    }
6266
 
6267
    public void setFieldValue(int fieldID, Object value) {
6268
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
6269
    }
6270
 
6271
    public Object getFieldValue(_Fields field) {
6272
      switch (field) {
6273
      case SUCCESS:
6274
        return getSuccess();
6275
 
6276
      }
6277
      throw new IllegalStateException();
6278
    }
6279
 
6280
    public Object getFieldValue(int fieldId) {
6281
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
6282
    }
6283
 
6284
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
6285
    public boolean isSet(_Fields field) {
6286
      switch (field) {
6287
      case SUCCESS:
6288
        return isSetSuccess();
6289
      }
6290
      throw new IllegalStateException();
6291
    }
6292
 
6293
    public boolean isSet(int fieldID) {
6294
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
6295
    }
6296
 
6297
    @Override
6298
    public boolean equals(Object that) {
6299
      if (that == null)
6300
        return false;
6301
      if (that instanceof getActivitiesByCreator_result)
6302
        return this.equals((getActivitiesByCreator_result)that);
6303
      return false;
6304
    }
6305
 
6306
    public boolean equals(getActivitiesByCreator_result that) {
6307
      if (that == null)
6308
        return false;
6309
 
6310
      boolean this_present_success = true && this.isSetSuccess();
6311
      boolean that_present_success = true && that.isSetSuccess();
6312
      if (this_present_success || that_present_success) {
6313
        if (!(this_present_success && that_present_success))
6314
          return false;
6315
        if (!this.success.equals(that.success))
6316
          return false;
6317
      }
6318
 
6319
      return true;
6320
    }
6321
 
6322
    @Override
6323
    public int hashCode() {
6324
      return 0;
6325
    }
6326
 
6327
    public int compareTo(getActivitiesByCreator_result other) {
6328
      if (!getClass().equals(other.getClass())) {
6329
        return getClass().getName().compareTo(other.getClass().getName());
6330
      }
6331
 
6332
      int lastComparison = 0;
6333
      getActivitiesByCreator_result typedOther = (getActivitiesByCreator_result)other;
6334
 
6335
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(isSetSuccess());
6336
      if (lastComparison != 0) {
6337
        return lastComparison;
6338
      }
6339
      lastComparison = TBaseHelper.compareTo(success, typedOther.success);
6340
      if (lastComparison != 0) {
6341
        return lastComparison;
6342
      }
6343
      return 0;
6344
    }
6345
 
6346
    public void read(TProtocol iprot) throws TException {
6347
      TField field;
6348
      iprot.readStructBegin();
6349
      while (true)
6350
      {
6351
        field = iprot.readFieldBegin();
6352
        if (field.type == TType.STOP) { 
6353
          break;
6354
        }
6355
        _Fields fieldId = _Fields.findByThriftId(field.id);
6356
        if (fieldId == null) {
6357
          TProtocolUtil.skip(iprot, field.type);
6358
        } else {
6359
          switch (fieldId) {
6360
            case SUCCESS:
6361
              if (field.type == TType.LIST) {
6362
                {
6363
                  TList _list20 = iprot.readListBegin();
6364
                  this.success = new ArrayList<Activity>(_list20.size);
6365
                  for (int _i21 = 0; _i21 < _list20.size; ++_i21)
6366
                  {
6367
                    Activity _elem22;
6368
                    _elem22 = new Activity();
6369
                    _elem22.read(iprot);
6370
                    this.success.add(_elem22);
6371
                  }
6372
                  iprot.readListEnd();
6373
                }
6374
              } else { 
6375
                TProtocolUtil.skip(iprot, field.type);
6376
              }
6377
              break;
6378
          }
6379
          iprot.readFieldEnd();
6380
        }
6381
      }
6382
      iprot.readStructEnd();
6383
      validate();
6384
    }
6385
 
6386
    public void write(TProtocol oprot) throws TException {
6387
      oprot.writeStructBegin(STRUCT_DESC);
6388
 
6389
      if (this.isSetSuccess()) {
6390
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
6391
        {
6392
          oprot.writeListBegin(new TList(TType.STRUCT, this.success.size()));
6393
          for (Activity _iter23 : this.success)
6394
          {
6395
            _iter23.write(oprot);
6396
          }
6397
          oprot.writeListEnd();
6398
        }
6399
        oprot.writeFieldEnd();
6400
      }
6401
      oprot.writeFieldStop();
6402
      oprot.writeStructEnd();
6403
    }
6404
 
6405
    @Override
6406
    public String toString() {
6407
      StringBuilder sb = new StringBuilder("getActivitiesByCreator_result(");
6408
      boolean first = true;
6409
 
6410
      sb.append("success:");
6411
      if (this.success == null) {
6412
        sb.append("null");
6413
      } else {
6414
        sb.append(this.success);
6415
      }
6416
      first = false;
6417
      sb.append(")");
6418
      return sb.toString();
6419
    }
6420
 
6421
    public void validate() throws TException {
6422
      // check for required fields
6423
    }
6424
 
6425
  }
6426
 
3028 mandeep.dh 6427
  public static class getActivitiesForTicket_args implements TBase<getActivitiesForTicket_args._Fields>, java.io.Serializable, Cloneable, Comparable<getActivitiesForTicket_args>   {
6428
    private static final TStruct STRUCT_DESC = new TStruct("getActivitiesForTicket_args");
6429
 
6430
    private static final TField TICKET_ID_FIELD_DESC = new TField("ticketId", TType.I64, (short)1);
6431
 
6432
    private long ticketId;
6433
 
6434
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
6435
    public enum _Fields implements TFieldIdEnum {
6436
      TICKET_ID((short)1, "ticketId");
6437
 
6438
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
6439
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6440
 
6441
      static {
6442
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6443
          byId.put((int)field._thriftId, field);
6444
          byName.put(field.getFieldName(), field);
6445
        }
6446
      }
6447
 
6448
      /**
6449
       * Find the _Fields constant that matches fieldId, or null if its not found.
6450
       */
6451
      public static _Fields findByThriftId(int fieldId) {
6452
        return byId.get(fieldId);
6453
      }
6454
 
6455
      /**
6456
       * Find the _Fields constant that matches fieldId, throwing an exception
6457
       * if it is not found.
6458
       */
6459
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6460
        _Fields fields = findByThriftId(fieldId);
6461
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6462
        return fields;
6463
      }
6464
 
6465
      /**
6466
       * Find the _Fields constant that matches name, or null if its not found.
6467
       */
6468
      public static _Fields findByName(String name) {
6469
        return byName.get(name);
6470
      }
6471
 
6472
      private final short _thriftId;
6473
      private final String _fieldName;
6474
 
6475
      _Fields(short thriftId, String fieldName) {
6476
        _thriftId = thriftId;
6477
        _fieldName = fieldName;
6478
      }
6479
 
6480
      public short getThriftFieldId() {
6481
        return _thriftId;
6482
      }
6483
 
6484
      public String getFieldName() {
6485
        return _fieldName;
6486
      }
6487
    }
6488
 
6489
    // isset id assignments
6490
    private static final int __TICKETID_ISSET_ID = 0;
6491
    private BitSet __isset_bit_vector = new BitSet(1);
6492
 
6493
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
6494
      put(_Fields.TICKET_ID, new FieldMetaData("ticketId", TFieldRequirementType.DEFAULT, 
6495
          new FieldValueMetaData(TType.I64)));
6496
    }});
6497
 
6498
    static {
6499
      FieldMetaData.addStructMetaDataMap(getActivitiesForTicket_args.class, metaDataMap);
6500
    }
6501
 
6502
    public getActivitiesForTicket_args() {
6503
    }
6504
 
6505
    public getActivitiesForTicket_args(
6506
      long ticketId)
6507
    {
6508
      this();
6509
      this.ticketId = ticketId;
6510
      setTicketIdIsSet(true);
6511
    }
6512
 
6513
    /**
6514
     * Performs a deep copy on <i>other</i>.
6515
     */
6516
    public getActivitiesForTicket_args(getActivitiesForTicket_args other) {
6517
      __isset_bit_vector.clear();
6518
      __isset_bit_vector.or(other.__isset_bit_vector);
6519
      this.ticketId = other.ticketId;
6520
    }
6521
 
6522
    public getActivitiesForTicket_args deepCopy() {
6523
      return new getActivitiesForTicket_args(this);
6524
    }
6525
 
6526
    @Deprecated
6527
    public getActivitiesForTicket_args clone() {
6528
      return new getActivitiesForTicket_args(this);
6529
    }
6530
 
6531
    public long getTicketId() {
6532
      return this.ticketId;
6533
    }
6534
 
6535
    public getActivitiesForTicket_args setTicketId(long ticketId) {
6536
      this.ticketId = ticketId;
6537
      setTicketIdIsSet(true);
6538
      return this;
6539
    }
6540
 
6541
    public void unsetTicketId() {
6542
      __isset_bit_vector.clear(__TICKETID_ISSET_ID);
6543
    }
6544
 
6545
    /** Returns true if field ticketId is set (has been asigned a value) and false otherwise */
6546
    public boolean isSetTicketId() {
6547
      return __isset_bit_vector.get(__TICKETID_ISSET_ID);
6548
    }
6549
 
6550
    public void setTicketIdIsSet(boolean value) {
6551
      __isset_bit_vector.set(__TICKETID_ISSET_ID, value);
6552
    }
6553
 
6554
    public void setFieldValue(_Fields field, Object value) {
6555
      switch (field) {
6556
      case TICKET_ID:
6557
        if (value == null) {
6558
          unsetTicketId();
6559
        } else {
6560
          setTicketId((Long)value);
6561
        }
6562
        break;
6563
 
6564
      }
6565
    }
6566
 
6567
    public void setFieldValue(int fieldID, Object value) {
6568
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
6569
    }
6570
 
6571
    public Object getFieldValue(_Fields field) {
6572
      switch (field) {
6573
      case TICKET_ID:
6574
        return new Long(getTicketId());
6575
 
6576
      }
6577
      throw new IllegalStateException();
6578
    }
6579
 
6580
    public Object getFieldValue(int fieldId) {
6581
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
6582
    }
6583
 
6584
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
6585
    public boolean isSet(_Fields field) {
6586
      switch (field) {
6587
      case TICKET_ID:
6588
        return isSetTicketId();
6589
      }
6590
      throw new IllegalStateException();
6591
    }
6592
 
6593
    public boolean isSet(int fieldID) {
6594
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
6595
    }
6596
 
6597
    @Override
6598
    public boolean equals(Object that) {
6599
      if (that == null)
6600
        return false;
6601
      if (that instanceof getActivitiesForTicket_args)
6602
        return this.equals((getActivitiesForTicket_args)that);
6603
      return false;
6604
    }
6605
 
6606
    public boolean equals(getActivitiesForTicket_args that) {
6607
      if (that == null)
6608
        return false;
6609
 
6610
      boolean this_present_ticketId = true;
6611
      boolean that_present_ticketId = true;
6612
      if (this_present_ticketId || that_present_ticketId) {
6613
        if (!(this_present_ticketId && that_present_ticketId))
6614
          return false;
6615
        if (this.ticketId != that.ticketId)
6616
          return false;
6617
      }
6618
 
6619
      return true;
6620
    }
6621
 
6622
    @Override
6623
    public int hashCode() {
6624
      return 0;
6625
    }
6626
 
6627
    public int compareTo(getActivitiesForTicket_args other) {
6628
      if (!getClass().equals(other.getClass())) {
6629
        return getClass().getName().compareTo(other.getClass().getName());
6630
      }
6631
 
6632
      int lastComparison = 0;
6633
      getActivitiesForTicket_args typedOther = (getActivitiesForTicket_args)other;
6634
 
6635
      lastComparison = Boolean.valueOf(isSetTicketId()).compareTo(isSetTicketId());
6636
      if (lastComparison != 0) {
6637
        return lastComparison;
6638
      }
6639
      lastComparison = TBaseHelper.compareTo(ticketId, typedOther.ticketId);
6640
      if (lastComparison != 0) {
6641
        return lastComparison;
6642
      }
6643
      return 0;
6644
    }
6645
 
6646
    public void read(TProtocol iprot) throws TException {
6647
      TField field;
6648
      iprot.readStructBegin();
6649
      while (true)
6650
      {
6651
        field = iprot.readFieldBegin();
6652
        if (field.type == TType.STOP) { 
6653
          break;
6654
        }
6655
        _Fields fieldId = _Fields.findByThriftId(field.id);
6656
        if (fieldId == null) {
6657
          TProtocolUtil.skip(iprot, field.type);
6658
        } else {
6659
          switch (fieldId) {
6660
            case TICKET_ID:
6661
              if (field.type == TType.I64) {
6662
                this.ticketId = iprot.readI64();
6663
                setTicketIdIsSet(true);
6664
              } else { 
6665
                TProtocolUtil.skip(iprot, field.type);
6666
              }
6667
              break;
6668
          }
6669
          iprot.readFieldEnd();
6670
        }
6671
      }
6672
      iprot.readStructEnd();
6673
      validate();
6674
    }
6675
 
6676
    public void write(TProtocol oprot) throws TException {
6677
      validate();
6678
 
6679
      oprot.writeStructBegin(STRUCT_DESC);
6680
      oprot.writeFieldBegin(TICKET_ID_FIELD_DESC);
6681
      oprot.writeI64(this.ticketId);
6682
      oprot.writeFieldEnd();
6683
      oprot.writeFieldStop();
6684
      oprot.writeStructEnd();
6685
    }
6686
 
6687
    @Override
6688
    public String toString() {
6689
      StringBuilder sb = new StringBuilder("getActivitiesForTicket_args(");
6690
      boolean first = true;
6691
 
6692
      sb.append("ticketId:");
6693
      sb.append(this.ticketId);
6694
      first = false;
6695
      sb.append(")");
6696
      return sb.toString();
6697
    }
6698
 
6699
    public void validate() throws TException {
6700
      // check for required fields
6701
    }
6702
 
6703
  }
6704
 
6705
  public static class getActivitiesForTicket_result implements TBase<getActivitiesForTicket_result._Fields>, java.io.Serializable, Cloneable, Comparable<getActivitiesForTicket_result>   {
6706
    private static final TStruct STRUCT_DESC = new TStruct("getActivitiesForTicket_result");
6707
 
6708
    private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.LIST, (short)0);
6709
 
6710
    private List<Activity> success;
6711
 
6712
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
6713
    public enum _Fields implements TFieldIdEnum {
6714
      SUCCESS((short)0, "success");
6715
 
6716
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
6717
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6718
 
6719
      static {
6720
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6721
          byId.put((int)field._thriftId, field);
6722
          byName.put(field.getFieldName(), field);
6723
        }
6724
      }
6725
 
6726
      /**
6727
       * Find the _Fields constant that matches fieldId, or null if its not found.
6728
       */
6729
      public static _Fields findByThriftId(int fieldId) {
6730
        return byId.get(fieldId);
6731
      }
6732
 
6733
      /**
6734
       * Find the _Fields constant that matches fieldId, throwing an exception
6735
       * if it is not found.
6736
       */
6737
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6738
        _Fields fields = findByThriftId(fieldId);
6739
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6740
        return fields;
6741
      }
6742
 
6743
      /**
6744
       * Find the _Fields constant that matches name, or null if its not found.
6745
       */
6746
      public static _Fields findByName(String name) {
6747
        return byName.get(name);
6748
      }
6749
 
6750
      private final short _thriftId;
6751
      private final String _fieldName;
6752
 
6753
      _Fields(short thriftId, String fieldName) {
6754
        _thriftId = thriftId;
6755
        _fieldName = fieldName;
6756
      }
6757
 
6758
      public short getThriftFieldId() {
6759
        return _thriftId;
6760
      }
6761
 
6762
      public String getFieldName() {
6763
        return _fieldName;
6764
      }
6765
    }
6766
 
6767
    // isset id assignments
6768
 
6769
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
6770
      put(_Fields.SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, 
6771
          new ListMetaData(TType.LIST, 
6772
              new StructMetaData(TType.STRUCT, Activity.class))));
6773
    }});
6774
 
6775
    static {
6776
      FieldMetaData.addStructMetaDataMap(getActivitiesForTicket_result.class, metaDataMap);
6777
    }
6778
 
6779
    public getActivitiesForTicket_result() {
6780
    }
6781
 
6782
    public getActivitiesForTicket_result(
6783
      List<Activity> success)
6784
    {
6785
      this();
6786
      this.success = success;
6787
    }
6788
 
6789
    /**
6790
     * Performs a deep copy on <i>other</i>.
6791
     */
6792
    public getActivitiesForTicket_result(getActivitiesForTicket_result other) {
6793
      if (other.isSetSuccess()) {
6794
        List<Activity> __this__success = new ArrayList<Activity>();
6795
        for (Activity other_element : other.success) {
6796
          __this__success.add(new Activity(other_element));
6797
        }
6798
        this.success = __this__success;
6799
      }
6800
    }
6801
 
6802
    public getActivitiesForTicket_result deepCopy() {
6803
      return new getActivitiesForTicket_result(this);
6804
    }
6805
 
6806
    @Deprecated
6807
    public getActivitiesForTicket_result clone() {
6808
      return new getActivitiesForTicket_result(this);
6809
    }
6810
 
6811
    public int getSuccessSize() {
6812
      return (this.success == null) ? 0 : this.success.size();
6813
    }
6814
 
6815
    public java.util.Iterator<Activity> getSuccessIterator() {
6816
      return (this.success == null) ? null : this.success.iterator();
6817
    }
6818
 
6819
    public void addToSuccess(Activity elem) {
6820
      if (this.success == null) {
6821
        this.success = new ArrayList<Activity>();
6822
      }
6823
      this.success.add(elem);
6824
    }
6825
 
6826
    public List<Activity> getSuccess() {
6827
      return this.success;
6828
    }
6829
 
6830
    public getActivitiesForTicket_result setSuccess(List<Activity> success) {
6831
      this.success = success;
6832
      return this;
6833
    }
6834
 
6835
    public void unsetSuccess() {
6836
      this.success = null;
6837
    }
6838
 
6839
    /** Returns true if field success is set (has been asigned a value) and false otherwise */
6840
    public boolean isSetSuccess() {
6841
      return this.success != null;
6842
    }
6843
 
6844
    public void setSuccessIsSet(boolean value) {
6845
      if (!value) {
6846
        this.success = null;
6847
      }
6848
    }
6849
 
6850
    public void setFieldValue(_Fields field, Object value) {
6851
      switch (field) {
6852
      case SUCCESS:
6853
        if (value == null) {
6854
          unsetSuccess();
6855
        } else {
6856
          setSuccess((List<Activity>)value);
6857
        }
6858
        break;
6859
 
6860
      }
6861
    }
6862
 
6863
    public void setFieldValue(int fieldID, Object value) {
6864
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
6865
    }
6866
 
6867
    public Object getFieldValue(_Fields field) {
6868
      switch (field) {
6869
      case SUCCESS:
6870
        return getSuccess();
6871
 
6872
      }
6873
      throw new IllegalStateException();
6874
    }
6875
 
6876
    public Object getFieldValue(int fieldId) {
6877
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
6878
    }
6879
 
6880
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
6881
    public boolean isSet(_Fields field) {
6882
      switch (field) {
6883
      case SUCCESS:
6884
        return isSetSuccess();
6885
      }
6886
      throw new IllegalStateException();
6887
    }
6888
 
6889
    public boolean isSet(int fieldID) {
6890
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
6891
    }
6892
 
6893
    @Override
6894
    public boolean equals(Object that) {
6895
      if (that == null)
6896
        return false;
6897
      if (that instanceof getActivitiesForTicket_result)
6898
        return this.equals((getActivitiesForTicket_result)that);
6899
      return false;
6900
    }
6901
 
6902
    public boolean equals(getActivitiesForTicket_result that) {
6903
      if (that == null)
6904
        return false;
6905
 
6906
      boolean this_present_success = true && this.isSetSuccess();
6907
      boolean that_present_success = true && that.isSetSuccess();
6908
      if (this_present_success || that_present_success) {
6909
        if (!(this_present_success && that_present_success))
6910
          return false;
6911
        if (!this.success.equals(that.success))
6912
          return false;
6913
      }
6914
 
6915
      return true;
6916
    }
6917
 
6918
    @Override
6919
    public int hashCode() {
6920
      return 0;
6921
    }
6922
 
6923
    public int compareTo(getActivitiesForTicket_result other) {
6924
      if (!getClass().equals(other.getClass())) {
6925
        return getClass().getName().compareTo(other.getClass().getName());
6926
      }
6927
 
6928
      int lastComparison = 0;
6929
      getActivitiesForTicket_result typedOther = (getActivitiesForTicket_result)other;
6930
 
6931
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(isSetSuccess());
6932
      if (lastComparison != 0) {
6933
        return lastComparison;
6934
      }
6935
      lastComparison = TBaseHelper.compareTo(success, typedOther.success);
6936
      if (lastComparison != 0) {
6937
        return lastComparison;
6938
      }
6939
      return 0;
6940
    }
6941
 
6942
    public void read(TProtocol iprot) throws TException {
6943
      TField field;
6944
      iprot.readStructBegin();
6945
      while (true)
6946
      {
6947
        field = iprot.readFieldBegin();
6948
        if (field.type == TType.STOP) { 
6949
          break;
6950
        }
6951
        _Fields fieldId = _Fields.findByThriftId(field.id);
6952
        if (fieldId == null) {
6953
          TProtocolUtil.skip(iprot, field.type);
6954
        } else {
6955
          switch (fieldId) {
6956
            case SUCCESS:
6957
              if (field.type == TType.LIST) {
6958
                {
3339 mandeep.dh 6959
                  TList _list24 = iprot.readListBegin();
6960
                  this.success = new ArrayList<Activity>(_list24.size);
6961
                  for (int _i25 = 0; _i25 < _list24.size; ++_i25)
3028 mandeep.dh 6962
                  {
3339 mandeep.dh 6963
                    Activity _elem26;
6964
                    _elem26 = new Activity();
6965
                    _elem26.read(iprot);
6966
                    this.success.add(_elem26);
3028 mandeep.dh 6967
                  }
6968
                  iprot.readListEnd();
6969
                }
6970
              } else { 
6971
                TProtocolUtil.skip(iprot, field.type);
6972
              }
6973
              break;
6974
          }
6975
          iprot.readFieldEnd();
6976
        }
6977
      }
6978
      iprot.readStructEnd();
6979
      validate();
6980
    }
6981
 
6982
    public void write(TProtocol oprot) throws TException {
6983
      oprot.writeStructBegin(STRUCT_DESC);
6984
 
6985
      if (this.isSetSuccess()) {
6986
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
6987
        {
6988
          oprot.writeListBegin(new TList(TType.STRUCT, this.success.size()));
3339 mandeep.dh 6989
          for (Activity _iter27 : this.success)
3028 mandeep.dh 6990
          {
3339 mandeep.dh 6991
            _iter27.write(oprot);
3028 mandeep.dh 6992
          }
6993
          oprot.writeListEnd();
6994
        }
6995
        oprot.writeFieldEnd();
6996
      }
6997
      oprot.writeFieldStop();
6998
      oprot.writeStructEnd();
6999
    }
7000
 
7001
    @Override
7002
    public String toString() {
7003
      StringBuilder sb = new StringBuilder("getActivitiesForTicket_result(");
7004
      boolean first = true;
7005
 
7006
      sb.append("success:");
7007
      if (this.success == null) {
7008
        sb.append("null");
7009
      } else {
7010
        sb.append(this.success);
7011
      }
7012
      first = false;
7013
      sb.append(")");
7014
      return sb.toString();
7015
    }
7016
 
7017
    public void validate() throws TException {
7018
      // check for required fields
7019
    }
7020
 
7021
  }
7022
 
7023
  public static class getActivity_args implements TBase<getActivity_args._Fields>, java.io.Serializable, Cloneable, Comparable<getActivity_args>   {
7024
    private static final TStruct STRUCT_DESC = new TStruct("getActivity_args");
7025
 
7026
    private static final TField ACTIVITY_ID_FIELD_DESC = new TField("activityId", TType.I64, (short)1);
7027
 
7028
    private long activityId;
7029
 
7030
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
7031
    public enum _Fields implements TFieldIdEnum {
7032
      ACTIVITY_ID((short)1, "activityId");
7033
 
7034
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
7035
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7036
 
7037
      static {
7038
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7039
          byId.put((int)field._thriftId, field);
7040
          byName.put(field.getFieldName(), field);
7041
        }
7042
      }
7043
 
7044
      /**
7045
       * Find the _Fields constant that matches fieldId, or null if its not found.
7046
       */
7047
      public static _Fields findByThriftId(int fieldId) {
7048
        return byId.get(fieldId);
7049
      }
7050
 
7051
      /**
7052
       * Find the _Fields constant that matches fieldId, throwing an exception
7053
       * if it is not found.
7054
       */
7055
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7056
        _Fields fields = findByThriftId(fieldId);
7057
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7058
        return fields;
7059
      }
7060
 
7061
      /**
7062
       * Find the _Fields constant that matches name, or null if its not found.
7063
       */
7064
      public static _Fields findByName(String name) {
7065
        return byName.get(name);
7066
      }
7067
 
7068
      private final short _thriftId;
7069
      private final String _fieldName;
7070
 
7071
      _Fields(short thriftId, String fieldName) {
7072
        _thriftId = thriftId;
7073
        _fieldName = fieldName;
7074
      }
7075
 
7076
      public short getThriftFieldId() {
7077
        return _thriftId;
7078
      }
7079
 
7080
      public String getFieldName() {
7081
        return _fieldName;
7082
      }
7083
    }
7084
 
7085
    // isset id assignments
7086
    private static final int __ACTIVITYID_ISSET_ID = 0;
7087
    private BitSet __isset_bit_vector = new BitSet(1);
7088
 
7089
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
7090
      put(_Fields.ACTIVITY_ID, new FieldMetaData("activityId", TFieldRequirementType.DEFAULT, 
7091
          new FieldValueMetaData(TType.I64)));
7092
    }});
7093
 
7094
    static {
7095
      FieldMetaData.addStructMetaDataMap(getActivity_args.class, metaDataMap);
7096
    }
7097
 
7098
    public getActivity_args() {
7099
    }
7100
 
7101
    public getActivity_args(
7102
      long activityId)
7103
    {
7104
      this();
7105
      this.activityId = activityId;
7106
      setActivityIdIsSet(true);
7107
    }
7108
 
7109
    /**
7110
     * Performs a deep copy on <i>other</i>.
7111
     */
7112
    public getActivity_args(getActivity_args other) {
7113
      __isset_bit_vector.clear();
7114
      __isset_bit_vector.or(other.__isset_bit_vector);
7115
      this.activityId = other.activityId;
7116
    }
7117
 
7118
    public getActivity_args deepCopy() {
7119
      return new getActivity_args(this);
7120
    }
7121
 
7122
    @Deprecated
7123
    public getActivity_args clone() {
7124
      return new getActivity_args(this);
7125
    }
7126
 
7127
    public long getActivityId() {
7128
      return this.activityId;
7129
    }
7130
 
7131
    public getActivity_args setActivityId(long activityId) {
7132
      this.activityId = activityId;
7133
      setActivityIdIsSet(true);
7134
      return this;
7135
    }
7136
 
7137
    public void unsetActivityId() {
7138
      __isset_bit_vector.clear(__ACTIVITYID_ISSET_ID);
7139
    }
7140
 
7141
    /** Returns true if field activityId is set (has been asigned a value) and false otherwise */
7142
    public boolean isSetActivityId() {
7143
      return __isset_bit_vector.get(__ACTIVITYID_ISSET_ID);
7144
    }
7145
 
7146
    public void setActivityIdIsSet(boolean value) {
7147
      __isset_bit_vector.set(__ACTIVITYID_ISSET_ID, value);
7148
    }
7149
 
7150
    public void setFieldValue(_Fields field, Object value) {
7151
      switch (field) {
7152
      case ACTIVITY_ID:
7153
        if (value == null) {
7154
          unsetActivityId();
7155
        } else {
7156
          setActivityId((Long)value);
7157
        }
7158
        break;
7159
 
7160
      }
7161
    }
7162
 
7163
    public void setFieldValue(int fieldID, Object value) {
7164
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
7165
    }
7166
 
7167
    public Object getFieldValue(_Fields field) {
7168
      switch (field) {
7169
      case ACTIVITY_ID:
7170
        return new Long(getActivityId());
7171
 
7172
      }
7173
      throw new IllegalStateException();
7174
    }
7175
 
7176
    public Object getFieldValue(int fieldId) {
7177
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
7178
    }
7179
 
7180
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
7181
    public boolean isSet(_Fields field) {
7182
      switch (field) {
7183
      case ACTIVITY_ID:
7184
        return isSetActivityId();
7185
      }
7186
      throw new IllegalStateException();
7187
    }
7188
 
7189
    public boolean isSet(int fieldID) {
7190
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
7191
    }
7192
 
7193
    @Override
7194
    public boolean equals(Object that) {
7195
      if (that == null)
7196
        return false;
7197
      if (that instanceof getActivity_args)
7198
        return this.equals((getActivity_args)that);
7199
      return false;
7200
    }
7201
 
7202
    public boolean equals(getActivity_args that) {
7203
      if (that == null)
7204
        return false;
7205
 
7206
      boolean this_present_activityId = true;
7207
      boolean that_present_activityId = true;
7208
      if (this_present_activityId || that_present_activityId) {
7209
        if (!(this_present_activityId && that_present_activityId))
7210
          return false;
7211
        if (this.activityId != that.activityId)
7212
          return false;
7213
      }
7214
 
7215
      return true;
7216
    }
7217
 
7218
    @Override
7219
    public int hashCode() {
7220
      return 0;
7221
    }
7222
 
7223
    public int compareTo(getActivity_args other) {
7224
      if (!getClass().equals(other.getClass())) {
7225
        return getClass().getName().compareTo(other.getClass().getName());
7226
      }
7227
 
7228
      int lastComparison = 0;
7229
      getActivity_args typedOther = (getActivity_args)other;
7230
 
7231
      lastComparison = Boolean.valueOf(isSetActivityId()).compareTo(isSetActivityId());
7232
      if (lastComparison != 0) {
7233
        return lastComparison;
7234
      }
7235
      lastComparison = TBaseHelper.compareTo(activityId, typedOther.activityId);
7236
      if (lastComparison != 0) {
7237
        return lastComparison;
7238
      }
7239
      return 0;
7240
    }
7241
 
7242
    public void read(TProtocol iprot) throws TException {
7243
      TField field;
7244
      iprot.readStructBegin();
7245
      while (true)
7246
      {
7247
        field = iprot.readFieldBegin();
7248
        if (field.type == TType.STOP) { 
7249
          break;
7250
        }
7251
        _Fields fieldId = _Fields.findByThriftId(field.id);
7252
        if (fieldId == null) {
7253
          TProtocolUtil.skip(iprot, field.type);
7254
        } else {
7255
          switch (fieldId) {
7256
            case ACTIVITY_ID:
7257
              if (field.type == TType.I64) {
7258
                this.activityId = iprot.readI64();
7259
                setActivityIdIsSet(true);
7260
              } else { 
7261
                TProtocolUtil.skip(iprot, field.type);
7262
              }
7263
              break;
7264
          }
7265
          iprot.readFieldEnd();
7266
        }
7267
      }
7268
      iprot.readStructEnd();
7269
      validate();
7270
    }
7271
 
7272
    public void write(TProtocol oprot) throws TException {
7273
      validate();
7274
 
7275
      oprot.writeStructBegin(STRUCT_DESC);
7276
      oprot.writeFieldBegin(ACTIVITY_ID_FIELD_DESC);
7277
      oprot.writeI64(this.activityId);
7278
      oprot.writeFieldEnd();
7279
      oprot.writeFieldStop();
7280
      oprot.writeStructEnd();
7281
    }
7282
 
7283
    @Override
7284
    public String toString() {
7285
      StringBuilder sb = new StringBuilder("getActivity_args(");
7286
      boolean first = true;
7287
 
7288
      sb.append("activityId:");
7289
      sb.append(this.activityId);
7290
      first = false;
7291
      sb.append(")");
7292
      return sb.toString();
7293
    }
7294
 
7295
    public void validate() throws TException {
7296
      // check for required fields
7297
    }
7298
 
7299
  }
7300
 
7301
  public static class getActivity_result implements TBase<getActivity_result._Fields>, java.io.Serializable, Cloneable, Comparable<getActivity_result>   {
7302
    private static final TStruct STRUCT_DESC = new TStruct("getActivity_result");
7303
 
7304
    private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0);
7305
 
7306
    private Activity success;
7307
 
7308
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
7309
    public enum _Fields implements TFieldIdEnum {
7310
      SUCCESS((short)0, "success");
7311
 
7312
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
7313
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7314
 
7315
      static {
7316
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7317
          byId.put((int)field._thriftId, field);
7318
          byName.put(field.getFieldName(), field);
7319
        }
7320
      }
7321
 
7322
      /**
7323
       * Find the _Fields constant that matches fieldId, or null if its not found.
7324
       */
7325
      public static _Fields findByThriftId(int fieldId) {
7326
        return byId.get(fieldId);
7327
      }
7328
 
7329
      /**
7330
       * Find the _Fields constant that matches fieldId, throwing an exception
7331
       * if it is not found.
7332
       */
7333
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7334
        _Fields fields = findByThriftId(fieldId);
7335
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7336
        return fields;
7337
      }
7338
 
7339
      /**
7340
       * Find the _Fields constant that matches name, or null if its not found.
7341
       */
7342
      public static _Fields findByName(String name) {
7343
        return byName.get(name);
7344
      }
7345
 
7346
      private final short _thriftId;
7347
      private final String _fieldName;
7348
 
7349
      _Fields(short thriftId, String fieldName) {
7350
        _thriftId = thriftId;
7351
        _fieldName = fieldName;
7352
      }
7353
 
7354
      public short getThriftFieldId() {
7355
        return _thriftId;
7356
      }
7357
 
7358
      public String getFieldName() {
7359
        return _fieldName;
7360
      }
7361
    }
7362
 
7363
    // isset id assignments
7364
 
7365
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
7366
      put(_Fields.SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, 
7367
          new StructMetaData(TType.STRUCT, Activity.class)));
7368
    }});
7369
 
7370
    static {
7371
      FieldMetaData.addStructMetaDataMap(getActivity_result.class, metaDataMap);
7372
    }
7373
 
7374
    public getActivity_result() {
7375
    }
7376
 
7377
    public getActivity_result(
7378
      Activity success)
7379
    {
7380
      this();
7381
      this.success = success;
7382
    }
7383
 
7384
    /**
7385
     * Performs a deep copy on <i>other</i>.
7386
     */
7387
    public getActivity_result(getActivity_result other) {
7388
      if (other.isSetSuccess()) {
7389
        this.success = new Activity(other.success);
7390
      }
7391
    }
7392
 
7393
    public getActivity_result deepCopy() {
7394
      return new getActivity_result(this);
7395
    }
7396
 
7397
    @Deprecated
7398
    public getActivity_result clone() {
7399
      return new getActivity_result(this);
7400
    }
7401
 
7402
    public Activity getSuccess() {
7403
      return this.success;
7404
    }
7405
 
7406
    public getActivity_result setSuccess(Activity success) {
7407
      this.success = success;
7408
      return this;
7409
    }
7410
 
7411
    public void unsetSuccess() {
7412
      this.success = null;
7413
    }
7414
 
7415
    /** Returns true if field success is set (has been asigned a value) and false otherwise */
7416
    public boolean isSetSuccess() {
7417
      return this.success != null;
7418
    }
7419
 
7420
    public void setSuccessIsSet(boolean value) {
7421
      if (!value) {
7422
        this.success = null;
7423
      }
7424
    }
7425
 
7426
    public void setFieldValue(_Fields field, Object value) {
7427
      switch (field) {
7428
      case SUCCESS:
7429
        if (value == null) {
7430
          unsetSuccess();
7431
        } else {
7432
          setSuccess((Activity)value);
7433
        }
7434
        break;
7435
 
7436
      }
7437
    }
7438
 
7439
    public void setFieldValue(int fieldID, Object value) {
7440
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
7441
    }
7442
 
7443
    public Object getFieldValue(_Fields field) {
7444
      switch (field) {
7445
      case SUCCESS:
7446
        return getSuccess();
7447
 
7448
      }
7449
      throw new IllegalStateException();
7450
    }
7451
 
7452
    public Object getFieldValue(int fieldId) {
7453
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
7454
    }
7455
 
7456
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
7457
    public boolean isSet(_Fields field) {
7458
      switch (field) {
7459
      case SUCCESS:
7460
        return isSetSuccess();
7461
      }
7462
      throw new IllegalStateException();
7463
    }
7464
 
7465
    public boolean isSet(int fieldID) {
7466
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
7467
    }
7468
 
7469
    @Override
7470
    public boolean equals(Object that) {
7471
      if (that == null)
7472
        return false;
7473
      if (that instanceof getActivity_result)
7474
        return this.equals((getActivity_result)that);
7475
      return false;
7476
    }
7477
 
7478
    public boolean equals(getActivity_result that) {
7479
      if (that == null)
7480
        return false;
7481
 
7482
      boolean this_present_success = true && this.isSetSuccess();
7483
      boolean that_present_success = true && that.isSetSuccess();
7484
      if (this_present_success || that_present_success) {
7485
        if (!(this_present_success && that_present_success))
7486
          return false;
7487
        if (!this.success.equals(that.success))
7488
          return false;
7489
      }
7490
 
7491
      return true;
7492
    }
7493
 
7494
    @Override
7495
    public int hashCode() {
7496
      return 0;
7497
    }
7498
 
7499
    public int compareTo(getActivity_result other) {
7500
      if (!getClass().equals(other.getClass())) {
7501
        return getClass().getName().compareTo(other.getClass().getName());
7502
      }
7503
 
7504
      int lastComparison = 0;
7505
      getActivity_result typedOther = (getActivity_result)other;
7506
 
7507
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(isSetSuccess());
7508
      if (lastComparison != 0) {
7509
        return lastComparison;
7510
      }
7511
      lastComparison = TBaseHelper.compareTo(success, typedOther.success);
7512
      if (lastComparison != 0) {
7513
        return lastComparison;
7514
      }
7515
      return 0;
7516
    }
7517
 
7518
    public void read(TProtocol iprot) throws TException {
7519
      TField field;
7520
      iprot.readStructBegin();
7521
      while (true)
7522
      {
7523
        field = iprot.readFieldBegin();
7524
        if (field.type == TType.STOP) { 
7525
          break;
7526
        }
7527
        _Fields fieldId = _Fields.findByThriftId(field.id);
7528
        if (fieldId == null) {
7529
          TProtocolUtil.skip(iprot, field.type);
7530
        } else {
7531
          switch (fieldId) {
7532
            case SUCCESS:
7533
              if (field.type == TType.STRUCT) {
7534
                this.success = new Activity();
7535
                this.success.read(iprot);
7536
              } else { 
7537
                TProtocolUtil.skip(iprot, field.type);
7538
              }
7539
              break;
7540
          }
7541
          iprot.readFieldEnd();
7542
        }
7543
      }
7544
      iprot.readStructEnd();
7545
      validate();
7546
    }
7547
 
7548
    public void write(TProtocol oprot) throws TException {
7549
      oprot.writeStructBegin(STRUCT_DESC);
7550
 
7551
      if (this.isSetSuccess()) {
7552
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
7553
        this.success.write(oprot);
7554
        oprot.writeFieldEnd();
7555
      }
7556
      oprot.writeFieldStop();
7557
      oprot.writeStructEnd();
7558
    }
7559
 
7560
    @Override
7561
    public String toString() {
7562
      StringBuilder sb = new StringBuilder("getActivity_result(");
7563
      boolean first = true;
7564
 
7565
      sb.append("success:");
7566
      if (this.success == null) {
7567
        sb.append("null");
7568
      } else {
7569
        sb.append(this.success);
7570
      }
7571
      first = false;
7572
      sb.append(")");
7573
      return sb.toString();
7574
    }
7575
 
7576
    public void validate() throws TException {
7577
      // check for required fields
7578
    }
7579
 
7580
  }
7581
 
7582
  public static class getLastActivity_args implements TBase<getLastActivity_args._Fields>, java.io.Serializable, Cloneable, Comparable<getLastActivity_args>   {
7583
    private static final TStruct STRUCT_DESC = new TStruct("getLastActivity_args");
7584
 
7585
    private static final TField TICKET_ID_FIELD_DESC = new TField("ticketId", TType.I64, (short)1);
7586
 
7587
    private long ticketId;
7588
 
7589
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
7590
    public enum _Fields implements TFieldIdEnum {
7591
      TICKET_ID((short)1, "ticketId");
7592
 
7593
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
7594
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7595
 
7596
      static {
7597
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7598
          byId.put((int)field._thriftId, field);
7599
          byName.put(field.getFieldName(), field);
7600
        }
7601
      }
7602
 
7603
      /**
7604
       * Find the _Fields constant that matches fieldId, or null if its not found.
7605
       */
7606
      public static _Fields findByThriftId(int fieldId) {
7607
        return byId.get(fieldId);
7608
      }
7609
 
7610
      /**
7611
       * Find the _Fields constant that matches fieldId, throwing an exception
7612
       * if it is not found.
7613
       */
7614
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7615
        _Fields fields = findByThriftId(fieldId);
7616
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7617
        return fields;
7618
      }
7619
 
7620
      /**
7621
       * Find the _Fields constant that matches name, or null if its not found.
7622
       */
7623
      public static _Fields findByName(String name) {
7624
        return byName.get(name);
7625
      }
7626
 
7627
      private final short _thriftId;
7628
      private final String _fieldName;
7629
 
7630
      _Fields(short thriftId, String fieldName) {
7631
        _thriftId = thriftId;
7632
        _fieldName = fieldName;
7633
      }
7634
 
7635
      public short getThriftFieldId() {
7636
        return _thriftId;
7637
      }
7638
 
7639
      public String getFieldName() {
7640
        return _fieldName;
7641
      }
7642
    }
7643
 
7644
    // isset id assignments
7645
    private static final int __TICKETID_ISSET_ID = 0;
7646
    private BitSet __isset_bit_vector = new BitSet(1);
7647
 
7648
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
7649
      put(_Fields.TICKET_ID, new FieldMetaData("ticketId", TFieldRequirementType.DEFAULT, 
7650
          new FieldValueMetaData(TType.I64)));
7651
    }});
7652
 
7653
    static {
7654
      FieldMetaData.addStructMetaDataMap(getLastActivity_args.class, metaDataMap);
7655
    }
7656
 
7657
    public getLastActivity_args() {
7658
    }
7659
 
7660
    public getLastActivity_args(
7661
      long ticketId)
7662
    {
7663
      this();
7664
      this.ticketId = ticketId;
7665
      setTicketIdIsSet(true);
7666
    }
7667
 
7668
    /**
7669
     * Performs a deep copy on <i>other</i>.
7670
     */
7671
    public getLastActivity_args(getLastActivity_args other) {
7672
      __isset_bit_vector.clear();
7673
      __isset_bit_vector.or(other.__isset_bit_vector);
7674
      this.ticketId = other.ticketId;
7675
    }
7676
 
7677
    public getLastActivity_args deepCopy() {
7678
      return new getLastActivity_args(this);
7679
    }
7680
 
7681
    @Deprecated
7682
    public getLastActivity_args clone() {
7683
      return new getLastActivity_args(this);
7684
    }
7685
 
7686
    public long getTicketId() {
7687
      return this.ticketId;
7688
    }
7689
 
7690
    public getLastActivity_args setTicketId(long ticketId) {
7691
      this.ticketId = ticketId;
7692
      setTicketIdIsSet(true);
7693
      return this;
7694
    }
7695
 
7696
    public void unsetTicketId() {
7697
      __isset_bit_vector.clear(__TICKETID_ISSET_ID);
7698
    }
7699
 
7700
    /** Returns true if field ticketId is set (has been asigned a value) and false otherwise */
7701
    public boolean isSetTicketId() {
7702
      return __isset_bit_vector.get(__TICKETID_ISSET_ID);
7703
    }
7704
 
7705
    public void setTicketIdIsSet(boolean value) {
7706
      __isset_bit_vector.set(__TICKETID_ISSET_ID, value);
7707
    }
7708
 
7709
    public void setFieldValue(_Fields field, Object value) {
7710
      switch (field) {
7711
      case TICKET_ID:
7712
        if (value == null) {
7713
          unsetTicketId();
7714
        } else {
7715
          setTicketId((Long)value);
7716
        }
7717
        break;
7718
 
7719
      }
7720
    }
7721
 
7722
    public void setFieldValue(int fieldID, Object value) {
7723
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
7724
    }
7725
 
7726
    public Object getFieldValue(_Fields field) {
7727
      switch (field) {
7728
      case TICKET_ID:
7729
        return new Long(getTicketId());
7730
 
7731
      }
7732
      throw new IllegalStateException();
7733
    }
7734
 
7735
    public Object getFieldValue(int fieldId) {
7736
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
7737
    }
7738
 
7739
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
7740
    public boolean isSet(_Fields field) {
7741
      switch (field) {
7742
      case TICKET_ID:
7743
        return isSetTicketId();
7744
      }
7745
      throw new IllegalStateException();
7746
    }
7747
 
7748
    public boolean isSet(int fieldID) {
7749
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
7750
    }
7751
 
7752
    @Override
7753
    public boolean equals(Object that) {
7754
      if (that == null)
7755
        return false;
7756
      if (that instanceof getLastActivity_args)
7757
        return this.equals((getLastActivity_args)that);
7758
      return false;
7759
    }
7760
 
7761
    public boolean equals(getLastActivity_args that) {
7762
      if (that == null)
7763
        return false;
7764
 
7765
      boolean this_present_ticketId = true;
7766
      boolean that_present_ticketId = true;
7767
      if (this_present_ticketId || that_present_ticketId) {
7768
        if (!(this_present_ticketId && that_present_ticketId))
7769
          return false;
7770
        if (this.ticketId != that.ticketId)
7771
          return false;
7772
      }
7773
 
7774
      return true;
7775
    }
7776
 
7777
    @Override
7778
    public int hashCode() {
7779
      return 0;
7780
    }
7781
 
7782
    public int compareTo(getLastActivity_args other) {
7783
      if (!getClass().equals(other.getClass())) {
7784
        return getClass().getName().compareTo(other.getClass().getName());
7785
      }
7786
 
7787
      int lastComparison = 0;
7788
      getLastActivity_args typedOther = (getLastActivity_args)other;
7789
 
7790
      lastComparison = Boolean.valueOf(isSetTicketId()).compareTo(isSetTicketId());
7791
      if (lastComparison != 0) {
7792
        return lastComparison;
7793
      }
7794
      lastComparison = TBaseHelper.compareTo(ticketId, typedOther.ticketId);
7795
      if (lastComparison != 0) {
7796
        return lastComparison;
7797
      }
7798
      return 0;
7799
    }
7800
 
7801
    public void read(TProtocol iprot) throws TException {
7802
      TField field;
7803
      iprot.readStructBegin();
7804
      while (true)
7805
      {
7806
        field = iprot.readFieldBegin();
7807
        if (field.type == TType.STOP) { 
7808
          break;
7809
        }
7810
        _Fields fieldId = _Fields.findByThriftId(field.id);
7811
        if (fieldId == null) {
7812
          TProtocolUtil.skip(iprot, field.type);
7813
        } else {
7814
          switch (fieldId) {
7815
            case TICKET_ID:
7816
              if (field.type == TType.I64) {
7817
                this.ticketId = iprot.readI64();
7818
                setTicketIdIsSet(true);
7819
              } else { 
7820
                TProtocolUtil.skip(iprot, field.type);
7821
              }
7822
              break;
7823
          }
7824
          iprot.readFieldEnd();
7825
        }
7826
      }
7827
      iprot.readStructEnd();
7828
      validate();
7829
    }
7830
 
7831
    public void write(TProtocol oprot) throws TException {
7832
      validate();
7833
 
7834
      oprot.writeStructBegin(STRUCT_DESC);
7835
      oprot.writeFieldBegin(TICKET_ID_FIELD_DESC);
7836
      oprot.writeI64(this.ticketId);
7837
      oprot.writeFieldEnd();
7838
      oprot.writeFieldStop();
7839
      oprot.writeStructEnd();
7840
    }
7841
 
7842
    @Override
7843
    public String toString() {
7844
      StringBuilder sb = new StringBuilder("getLastActivity_args(");
7845
      boolean first = true;
7846
 
7847
      sb.append("ticketId:");
7848
      sb.append(this.ticketId);
7849
      first = false;
7850
      sb.append(")");
7851
      return sb.toString();
7852
    }
7853
 
7854
    public void validate() throws TException {
7855
      // check for required fields
7856
    }
7857
 
7858
  }
7859
 
7860
  public static class getLastActivity_result implements TBase<getLastActivity_result._Fields>, java.io.Serializable, Cloneable, Comparable<getLastActivity_result>   {
7861
    private static final TStruct STRUCT_DESC = new TStruct("getLastActivity_result");
7862
 
7863
    private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0);
7864
 
7865
    private Activity success;
7866
 
7867
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
7868
    public enum _Fields implements TFieldIdEnum {
7869
      SUCCESS((short)0, "success");
7870
 
7871
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
7872
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7873
 
7874
      static {
7875
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7876
          byId.put((int)field._thriftId, field);
7877
          byName.put(field.getFieldName(), field);
7878
        }
7879
      }
7880
 
7881
      /**
7882
       * Find the _Fields constant that matches fieldId, or null if its not found.
7883
       */
7884
      public static _Fields findByThriftId(int fieldId) {
7885
        return byId.get(fieldId);
7886
      }
7887
 
7888
      /**
7889
       * Find the _Fields constant that matches fieldId, throwing an exception
7890
       * if it is not found.
7891
       */
7892
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7893
        _Fields fields = findByThriftId(fieldId);
7894
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7895
        return fields;
7896
      }
7897
 
7898
      /**
7899
       * Find the _Fields constant that matches name, or null if its not found.
7900
       */
7901
      public static _Fields findByName(String name) {
7902
        return byName.get(name);
7903
      }
7904
 
7905
      private final short _thriftId;
7906
      private final String _fieldName;
7907
 
7908
      _Fields(short thriftId, String fieldName) {
7909
        _thriftId = thriftId;
7910
        _fieldName = fieldName;
7911
      }
7912
 
7913
      public short getThriftFieldId() {
7914
        return _thriftId;
7915
      }
7916
 
7917
      public String getFieldName() {
7918
        return _fieldName;
7919
      }
7920
    }
7921
 
7922
    // isset id assignments
7923
 
7924
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
7925
      put(_Fields.SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, 
7926
          new StructMetaData(TType.STRUCT, Activity.class)));
7927
    }});
7928
 
7929
    static {
7930
      FieldMetaData.addStructMetaDataMap(getLastActivity_result.class, metaDataMap);
7931
    }
7932
 
7933
    public getLastActivity_result() {
7934
    }
7935
 
7936
    public getLastActivity_result(
7937
      Activity success)
7938
    {
7939
      this();
7940
      this.success = success;
7941
    }
7942
 
7943
    /**
7944
     * Performs a deep copy on <i>other</i>.
7945
     */
7946
    public getLastActivity_result(getLastActivity_result other) {
7947
      if (other.isSetSuccess()) {
7948
        this.success = new Activity(other.success);
7949
      }
7950
    }
7951
 
7952
    public getLastActivity_result deepCopy() {
7953
      return new getLastActivity_result(this);
7954
    }
7955
 
7956
    @Deprecated
7957
    public getLastActivity_result clone() {
7958
      return new getLastActivity_result(this);
7959
    }
7960
 
7961
    public Activity getSuccess() {
7962
      return this.success;
7963
    }
7964
 
7965
    public getLastActivity_result setSuccess(Activity success) {
7966
      this.success = success;
7967
      return this;
7968
    }
7969
 
7970
    public void unsetSuccess() {
7971
      this.success = null;
7972
    }
7973
 
7974
    /** Returns true if field success is set (has been asigned a value) and false otherwise */
7975
    public boolean isSetSuccess() {
7976
      return this.success != null;
7977
    }
7978
 
7979
    public void setSuccessIsSet(boolean value) {
7980
      if (!value) {
7981
        this.success = null;
7982
      }
7983
    }
7984
 
7985
    public void setFieldValue(_Fields field, Object value) {
7986
      switch (field) {
7987
      case SUCCESS:
7988
        if (value == null) {
7989
          unsetSuccess();
7990
        } else {
7991
          setSuccess((Activity)value);
7992
        }
7993
        break;
7994
 
7995
      }
7996
    }
7997
 
7998
    public void setFieldValue(int fieldID, Object value) {
7999
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
8000
    }
8001
 
8002
    public Object getFieldValue(_Fields field) {
8003
      switch (field) {
8004
      case SUCCESS:
8005
        return getSuccess();
8006
 
8007
      }
8008
      throw new IllegalStateException();
8009
    }
8010
 
8011
    public Object getFieldValue(int fieldId) {
8012
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
8013
    }
8014
 
8015
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
8016
    public boolean isSet(_Fields field) {
8017
      switch (field) {
8018
      case SUCCESS:
8019
        return isSetSuccess();
8020
      }
8021
      throw new IllegalStateException();
8022
    }
8023
 
8024
    public boolean isSet(int fieldID) {
8025
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
8026
    }
8027
 
8028
    @Override
8029
    public boolean equals(Object that) {
8030
      if (that == null)
8031
        return false;
8032
      if (that instanceof getLastActivity_result)
8033
        return this.equals((getLastActivity_result)that);
8034
      return false;
8035
    }
8036
 
8037
    public boolean equals(getLastActivity_result that) {
8038
      if (that == null)
8039
        return false;
8040
 
8041
      boolean this_present_success = true && this.isSetSuccess();
8042
      boolean that_present_success = true && that.isSetSuccess();
8043
      if (this_present_success || that_present_success) {
8044
        if (!(this_present_success && that_present_success))
8045
          return false;
8046
        if (!this.success.equals(that.success))
8047
          return false;
8048
      }
8049
 
8050
      return true;
8051
    }
8052
 
8053
    @Override
8054
    public int hashCode() {
8055
      return 0;
8056
    }
8057
 
8058
    public int compareTo(getLastActivity_result other) {
8059
      if (!getClass().equals(other.getClass())) {
8060
        return getClass().getName().compareTo(other.getClass().getName());
8061
      }
8062
 
8063
      int lastComparison = 0;
8064
      getLastActivity_result typedOther = (getLastActivity_result)other;
8065
 
8066
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(isSetSuccess());
8067
      if (lastComparison != 0) {
8068
        return lastComparison;
8069
      }
8070
      lastComparison = TBaseHelper.compareTo(success, typedOther.success);
8071
      if (lastComparison != 0) {
8072
        return lastComparison;
8073
      }
8074
      return 0;
8075
    }
8076
 
8077
    public void read(TProtocol iprot) throws TException {
8078
      TField field;
8079
      iprot.readStructBegin();
8080
      while (true)
8081
      {
8082
        field = iprot.readFieldBegin();
8083
        if (field.type == TType.STOP) { 
8084
          break;
8085
        }
8086
        _Fields fieldId = _Fields.findByThriftId(field.id);
8087
        if (fieldId == null) {
8088
          TProtocolUtil.skip(iprot, field.type);
8089
        } else {
8090
          switch (fieldId) {
8091
            case SUCCESS:
8092
              if (field.type == TType.STRUCT) {
8093
                this.success = new Activity();
8094
                this.success.read(iprot);
8095
              } else { 
8096
                TProtocolUtil.skip(iprot, field.type);
8097
              }
8098
              break;
8099
          }
8100
          iprot.readFieldEnd();
8101
        }
8102
      }
8103
      iprot.readStructEnd();
8104
      validate();
8105
    }
8106
 
8107
    public void write(TProtocol oprot) throws TException {
8108
      oprot.writeStructBegin(STRUCT_DESC);
8109
 
8110
      if (this.isSetSuccess()) {
8111
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
8112
        this.success.write(oprot);
8113
        oprot.writeFieldEnd();
8114
      }
8115
      oprot.writeFieldStop();
8116
      oprot.writeStructEnd();
8117
    }
8118
 
8119
    @Override
8120
    public String toString() {
8121
      StringBuilder sb = new StringBuilder("getLastActivity_result(");
8122
      boolean first = true;
8123
 
8124
      sb.append("success:");
8125
      if (this.success == null) {
8126
        sb.append("null");
8127
      } else {
8128
        sb.append(this.success);
8129
      }
8130
      first = false;
8131
      sb.append(")");
8132
      return sb.toString();
8133
    }
8134
 
8135
    public void validate() throws TException {
8136
      // check for required fields
8137
    }
8138
 
8139
  }
8140
 
8141
  public static class insertActivity_args implements TBase<insertActivity_args._Fields>, java.io.Serializable, Cloneable, Comparable<insertActivity_args>   {
8142
    private static final TStruct STRUCT_DESC = new TStruct("insertActivity_args");
8143
 
8144
    private static final TField ACTIVITY_FIELD_DESC = new TField("activity", TType.STRUCT, (short)1);
8145
 
8146
    private Activity activity;
8147
 
8148
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8149
    public enum _Fields implements TFieldIdEnum {
8150
      ACTIVITY((short)1, "activity");
8151
 
8152
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
8153
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8154
 
8155
      static {
8156
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8157
          byId.put((int)field._thriftId, field);
8158
          byName.put(field.getFieldName(), field);
8159
        }
8160
      }
8161
 
8162
      /**
8163
       * Find the _Fields constant that matches fieldId, or null if its not found.
8164
       */
8165
      public static _Fields findByThriftId(int fieldId) {
8166
        return byId.get(fieldId);
8167
      }
8168
 
8169
      /**
8170
       * Find the _Fields constant that matches fieldId, throwing an exception
8171
       * if it is not found.
8172
       */
8173
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8174
        _Fields fields = findByThriftId(fieldId);
8175
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8176
        return fields;
8177
      }
8178
 
8179
      /**
8180
       * Find the _Fields constant that matches name, or null if its not found.
8181
       */
8182
      public static _Fields findByName(String name) {
8183
        return byName.get(name);
8184
      }
8185
 
8186
      private final short _thriftId;
8187
      private final String _fieldName;
8188
 
8189
      _Fields(short thriftId, String fieldName) {
8190
        _thriftId = thriftId;
8191
        _fieldName = fieldName;
8192
      }
8193
 
8194
      public short getThriftFieldId() {
8195
        return _thriftId;
8196
      }
8197
 
8198
      public String getFieldName() {
8199
        return _fieldName;
8200
      }
8201
    }
8202
 
8203
    // isset id assignments
8204
 
8205
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
8206
      put(_Fields.ACTIVITY, new FieldMetaData("activity", TFieldRequirementType.DEFAULT, 
8207
          new StructMetaData(TType.STRUCT, Activity.class)));
8208
    }});
8209
 
8210
    static {
8211
      FieldMetaData.addStructMetaDataMap(insertActivity_args.class, metaDataMap);
8212
    }
8213
 
8214
    public insertActivity_args() {
8215
    }
8216
 
8217
    public insertActivity_args(
8218
      Activity activity)
8219
    {
8220
      this();
8221
      this.activity = activity;
8222
    }
8223
 
8224
    /**
8225
     * Performs a deep copy on <i>other</i>.
8226
     */
8227
    public insertActivity_args(insertActivity_args other) {
8228
      if (other.isSetActivity()) {
8229
        this.activity = new Activity(other.activity);
8230
      }
8231
    }
8232
 
8233
    public insertActivity_args deepCopy() {
8234
      return new insertActivity_args(this);
8235
    }
8236
 
8237
    @Deprecated
8238
    public insertActivity_args clone() {
8239
      return new insertActivity_args(this);
8240
    }
8241
 
8242
    public Activity getActivity() {
8243
      return this.activity;
8244
    }
8245
 
8246
    public insertActivity_args setActivity(Activity activity) {
8247
      this.activity = activity;
8248
      return this;
8249
    }
8250
 
8251
    public void unsetActivity() {
8252
      this.activity = null;
8253
    }
8254
 
8255
    /** Returns true if field activity is set (has been asigned a value) and false otherwise */
8256
    public boolean isSetActivity() {
8257
      return this.activity != null;
8258
    }
8259
 
8260
    public void setActivityIsSet(boolean value) {
8261
      if (!value) {
8262
        this.activity = null;
8263
      }
8264
    }
8265
 
8266
    public void setFieldValue(_Fields field, Object value) {
8267
      switch (field) {
8268
      case ACTIVITY:
8269
        if (value == null) {
8270
          unsetActivity();
8271
        } else {
8272
          setActivity((Activity)value);
8273
        }
8274
        break;
8275
 
8276
      }
8277
    }
8278
 
8279
    public void setFieldValue(int fieldID, Object value) {
8280
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
8281
    }
8282
 
8283
    public Object getFieldValue(_Fields field) {
8284
      switch (field) {
8285
      case ACTIVITY:
8286
        return getActivity();
8287
 
8288
      }
8289
      throw new IllegalStateException();
8290
    }
8291
 
8292
    public Object getFieldValue(int fieldId) {
8293
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
8294
    }
8295
 
8296
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
8297
    public boolean isSet(_Fields field) {
8298
      switch (field) {
8299
      case ACTIVITY:
8300
        return isSetActivity();
8301
      }
8302
      throw new IllegalStateException();
8303
    }
8304
 
8305
    public boolean isSet(int fieldID) {
8306
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
8307
    }
8308
 
8309
    @Override
8310
    public boolean equals(Object that) {
8311
      if (that == null)
8312
        return false;
8313
      if (that instanceof insertActivity_args)
8314
        return this.equals((insertActivity_args)that);
8315
      return false;
8316
    }
8317
 
8318
    public boolean equals(insertActivity_args that) {
8319
      if (that == null)
8320
        return false;
8321
 
8322
      boolean this_present_activity = true && this.isSetActivity();
8323
      boolean that_present_activity = true && that.isSetActivity();
8324
      if (this_present_activity || that_present_activity) {
8325
        if (!(this_present_activity && that_present_activity))
8326
          return false;
8327
        if (!this.activity.equals(that.activity))
8328
          return false;
8329
      }
8330
 
8331
      return true;
8332
    }
8333
 
8334
    @Override
8335
    public int hashCode() {
8336
      return 0;
8337
    }
8338
 
8339
    public int compareTo(insertActivity_args other) {
8340
      if (!getClass().equals(other.getClass())) {
8341
        return getClass().getName().compareTo(other.getClass().getName());
8342
      }
8343
 
8344
      int lastComparison = 0;
8345
      insertActivity_args typedOther = (insertActivity_args)other;
8346
 
8347
      lastComparison = Boolean.valueOf(isSetActivity()).compareTo(isSetActivity());
8348
      if (lastComparison != 0) {
8349
        return lastComparison;
8350
      }
8351
      lastComparison = TBaseHelper.compareTo(activity, typedOther.activity);
8352
      if (lastComparison != 0) {
8353
        return lastComparison;
8354
      }
8355
      return 0;
8356
    }
8357
 
8358
    public void read(TProtocol iprot) throws TException {
8359
      TField field;
8360
      iprot.readStructBegin();
8361
      while (true)
8362
      {
8363
        field = iprot.readFieldBegin();
8364
        if (field.type == TType.STOP) { 
8365
          break;
8366
        }
8367
        _Fields fieldId = _Fields.findByThriftId(field.id);
8368
        if (fieldId == null) {
8369
          TProtocolUtil.skip(iprot, field.type);
8370
        } else {
8371
          switch (fieldId) {
8372
            case ACTIVITY:
8373
              if (field.type == TType.STRUCT) {
8374
                this.activity = new Activity();
8375
                this.activity.read(iprot);
8376
              } else { 
8377
                TProtocolUtil.skip(iprot, field.type);
8378
              }
8379
              break;
8380
          }
8381
          iprot.readFieldEnd();
8382
        }
8383
      }
8384
      iprot.readStructEnd();
8385
      validate();
8386
    }
8387
 
8388
    public void write(TProtocol oprot) throws TException {
8389
      validate();
8390
 
8391
      oprot.writeStructBegin(STRUCT_DESC);
8392
      if (this.activity != null) {
8393
        oprot.writeFieldBegin(ACTIVITY_FIELD_DESC);
8394
        this.activity.write(oprot);
8395
        oprot.writeFieldEnd();
8396
      }
8397
      oprot.writeFieldStop();
8398
      oprot.writeStructEnd();
8399
    }
8400
 
8401
    @Override
8402
    public String toString() {
8403
      StringBuilder sb = new StringBuilder("insertActivity_args(");
8404
      boolean first = true;
8405
 
8406
      sb.append("activity:");
8407
      if (this.activity == null) {
8408
        sb.append("null");
8409
      } else {
8410
        sb.append(this.activity);
8411
      }
8412
      first = false;
8413
      sb.append(")");
8414
      return sb.toString();
8415
    }
8416
 
8417
    public void validate() throws TException {
8418
      // check for required fields
8419
    }
8420
 
8421
  }
8422
 
8423
  public static class insertActivity_result implements TBase<insertActivity_result._Fields>, java.io.Serializable, Cloneable, Comparable<insertActivity_result>   {
8424
    private static final TStruct STRUCT_DESC = new TStruct("insertActivity_result");
8425
 
8426
 
8427
 
8428
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8429
    public enum _Fields implements TFieldIdEnum {
8430
;
8431
 
8432
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
8433
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8434
 
8435
      static {
8436
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8437
          byId.put((int)field._thriftId, field);
8438
          byName.put(field.getFieldName(), field);
8439
        }
8440
      }
8441
 
8442
      /**
8443
       * Find the _Fields constant that matches fieldId, or null if its not found.
8444
       */
8445
      public static _Fields findByThriftId(int fieldId) {
8446
        return byId.get(fieldId);
8447
      }
8448
 
8449
      /**
8450
       * Find the _Fields constant that matches fieldId, throwing an exception
8451
       * if it is not found.
8452
       */
8453
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8454
        _Fields fields = findByThriftId(fieldId);
8455
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8456
        return fields;
8457
      }
8458
 
8459
      /**
8460
       * Find the _Fields constant that matches name, or null if its not found.
8461
       */
8462
      public static _Fields findByName(String name) {
8463
        return byName.get(name);
8464
      }
8465
 
8466
      private final short _thriftId;
8467
      private final String _fieldName;
8468
 
8469
      _Fields(short thriftId, String fieldName) {
8470
        _thriftId = thriftId;
8471
        _fieldName = fieldName;
8472
      }
8473
 
8474
      public short getThriftFieldId() {
8475
        return _thriftId;
8476
      }
8477
 
8478
      public String getFieldName() {
8479
        return _fieldName;
8480
      }
8481
    }
8482
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
8483
    }});
8484
 
8485
    static {
8486
      FieldMetaData.addStructMetaDataMap(insertActivity_result.class, metaDataMap);
8487
    }
8488
 
8489
    public insertActivity_result() {
8490
    }
8491
 
8492
    /**
8493
     * Performs a deep copy on <i>other</i>.
8494
     */
8495
    public insertActivity_result(insertActivity_result other) {
8496
    }
8497
 
8498
    public insertActivity_result deepCopy() {
8499
      return new insertActivity_result(this);
8500
    }
8501
 
8502
    @Deprecated
8503
    public insertActivity_result clone() {
8504
      return new insertActivity_result(this);
8505
    }
8506
 
8507
    public void setFieldValue(_Fields field, Object value) {
8508
      switch (field) {
8509
      }
8510
    }
8511
 
8512
    public void setFieldValue(int fieldID, Object value) {
8513
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
8514
    }
8515
 
8516
    public Object getFieldValue(_Fields field) {
8517
      switch (field) {
8518
      }
8519
      throw new IllegalStateException();
8520
    }
8521
 
8522
    public Object getFieldValue(int fieldId) {
8523
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
8524
    }
8525
 
8526
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
8527
    public boolean isSet(_Fields field) {
8528
      switch (field) {
8529
      }
8530
      throw new IllegalStateException();
8531
    }
8532
 
8533
    public boolean isSet(int fieldID) {
8534
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
8535
    }
8536
 
8537
    @Override
8538
    public boolean equals(Object that) {
8539
      if (that == null)
8540
        return false;
8541
      if (that instanceof insertActivity_result)
8542
        return this.equals((insertActivity_result)that);
8543
      return false;
8544
    }
8545
 
8546
    public boolean equals(insertActivity_result that) {
8547
      if (that == null)
8548
        return false;
8549
 
8550
      return true;
8551
    }
8552
 
8553
    @Override
8554
    public int hashCode() {
8555
      return 0;
8556
    }
8557
 
8558
    public int compareTo(insertActivity_result other) {
8559
      if (!getClass().equals(other.getClass())) {
8560
        return getClass().getName().compareTo(other.getClass().getName());
8561
      }
8562
 
8563
      int lastComparison = 0;
8564
      insertActivity_result typedOther = (insertActivity_result)other;
8565
 
8566
      return 0;
8567
    }
8568
 
8569
    public void read(TProtocol iprot) throws TException {
8570
      TField field;
8571
      iprot.readStructBegin();
8572
      while (true)
8573
      {
8574
        field = iprot.readFieldBegin();
8575
        if (field.type == TType.STOP) { 
8576
          break;
8577
        }
8578
        _Fields fieldId = _Fields.findByThriftId(field.id);
8579
        if (fieldId == null) {
8580
          TProtocolUtil.skip(iprot, field.type);
8581
        } else {
8582
          switch (fieldId) {
8583
          }
8584
          iprot.readFieldEnd();
8585
        }
8586
      }
8587
      iprot.readStructEnd();
8588
      validate();
8589
    }
8590
 
8591
    public void write(TProtocol oprot) throws TException {
8592
      oprot.writeStructBegin(STRUCT_DESC);
8593
 
8594
      oprot.writeFieldStop();
8595
      oprot.writeStructEnd();
8596
    }
8597
 
8598
    @Override
8599
    public String toString() {
8600
      StringBuilder sb = new StringBuilder("insertActivity_result(");
8601
      boolean first = true;
8602
 
8603
      sb.append(")");
8604
      return sb.toString();
8605
    }
8606
 
8607
    public void validate() throws TException {
8608
      // check for required fields
8609
    }
8610
 
8611
  }
8612
 
3087 mandeep.dh 8613
  public static class getAllAgents_args implements TBase<getAllAgents_args._Fields>, java.io.Serializable, Cloneable, Comparable<getAllAgents_args>   {
8614
    private static final TStruct STRUCT_DESC = new TStruct("getAllAgents_args");
8615
 
8616
 
8617
 
8618
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8619
    public enum _Fields implements TFieldIdEnum {
8620
;
8621
 
8622
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
8623
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8624
 
8625
      static {
8626
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8627
          byId.put((int)field._thriftId, field);
8628
          byName.put(field.getFieldName(), field);
8629
        }
8630
      }
8631
 
8632
      /**
8633
       * Find the _Fields constant that matches fieldId, or null if its not found.
8634
       */
8635
      public static _Fields findByThriftId(int fieldId) {
8636
        return byId.get(fieldId);
8637
      }
8638
 
8639
      /**
8640
       * Find the _Fields constant that matches fieldId, throwing an exception
8641
       * if it is not found.
8642
       */
8643
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8644
        _Fields fields = findByThriftId(fieldId);
8645
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8646
        return fields;
8647
      }
8648
 
8649
      /**
8650
       * Find the _Fields constant that matches name, or null if its not found.
8651
       */
8652
      public static _Fields findByName(String name) {
8653
        return byName.get(name);
8654
      }
8655
 
8656
      private final short _thriftId;
8657
      private final String _fieldName;
8658
 
8659
      _Fields(short thriftId, String fieldName) {
8660
        _thriftId = thriftId;
8661
        _fieldName = fieldName;
8662
      }
8663
 
8664
      public short getThriftFieldId() {
8665
        return _thriftId;
8666
      }
8667
 
8668
      public String getFieldName() {
8669
        return _fieldName;
8670
      }
8671
    }
8672
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
8673
    }});
8674
 
8675
    static {
8676
      FieldMetaData.addStructMetaDataMap(getAllAgents_args.class, metaDataMap);
8677
    }
8678
 
8679
    public getAllAgents_args() {
8680
    }
8681
 
8682
    /**
8683
     * Performs a deep copy on <i>other</i>.
8684
     */
8685
    public getAllAgents_args(getAllAgents_args other) {
8686
    }
8687
 
8688
    public getAllAgents_args deepCopy() {
8689
      return new getAllAgents_args(this);
8690
    }
8691
 
8692
    @Deprecated
8693
    public getAllAgents_args clone() {
8694
      return new getAllAgents_args(this);
8695
    }
8696
 
8697
    public void setFieldValue(_Fields field, Object value) {
8698
      switch (field) {
8699
      }
8700
    }
8701
 
8702
    public void setFieldValue(int fieldID, Object value) {
8703
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
8704
    }
8705
 
8706
    public Object getFieldValue(_Fields field) {
8707
      switch (field) {
8708
      }
8709
      throw new IllegalStateException();
8710
    }
8711
 
8712
    public Object getFieldValue(int fieldId) {
8713
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
8714
    }
8715
 
8716
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
8717
    public boolean isSet(_Fields field) {
8718
      switch (field) {
8719
      }
8720
      throw new IllegalStateException();
8721
    }
8722
 
8723
    public boolean isSet(int fieldID) {
8724
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
8725
    }
8726
 
8727
    @Override
8728
    public boolean equals(Object that) {
8729
      if (that == null)
8730
        return false;
8731
      if (that instanceof getAllAgents_args)
8732
        return this.equals((getAllAgents_args)that);
8733
      return false;
8734
    }
8735
 
8736
    public boolean equals(getAllAgents_args that) {
8737
      if (that == null)
8738
        return false;
8739
 
8740
      return true;
8741
    }
8742
 
8743
    @Override
8744
    public int hashCode() {
8745
      return 0;
8746
    }
8747
 
8748
    public int compareTo(getAllAgents_args other) {
8749
      if (!getClass().equals(other.getClass())) {
8750
        return getClass().getName().compareTo(other.getClass().getName());
8751
      }
8752
 
8753
      int lastComparison = 0;
8754
      getAllAgents_args typedOther = (getAllAgents_args)other;
8755
 
8756
      return 0;
8757
    }
8758
 
8759
    public void read(TProtocol iprot) throws TException {
8760
      TField field;
8761
      iprot.readStructBegin();
8762
      while (true)
8763
      {
8764
        field = iprot.readFieldBegin();
8765
        if (field.type == TType.STOP) { 
8766
          break;
8767
        }
8768
        _Fields fieldId = _Fields.findByThriftId(field.id);
8769
        if (fieldId == null) {
8770
          TProtocolUtil.skip(iprot, field.type);
8771
        } else {
8772
          switch (fieldId) {
8773
          }
8774
          iprot.readFieldEnd();
8775
        }
8776
      }
8777
      iprot.readStructEnd();
8778
      validate();
8779
    }
8780
 
8781
    public void write(TProtocol oprot) throws TException {
8782
      validate();
8783
 
8784
      oprot.writeStructBegin(STRUCT_DESC);
8785
      oprot.writeFieldStop();
8786
      oprot.writeStructEnd();
8787
    }
8788
 
8789
    @Override
8790
    public String toString() {
8791
      StringBuilder sb = new StringBuilder("getAllAgents_args(");
8792
      boolean first = true;
8793
 
8794
      sb.append(")");
8795
      return sb.toString();
8796
    }
8797
 
8798
    public void validate() throws TException {
8799
      // check for required fields
8800
    }
8801
 
8802
  }
8803
 
8804
  public static class getAllAgents_result implements TBase<getAllAgents_result._Fields>, java.io.Serializable, Cloneable, Comparable<getAllAgents_result>   {
8805
    private static final TStruct STRUCT_DESC = new TStruct("getAllAgents_result");
8806
 
8807
    private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.LIST, (short)0);
8808
 
8809
    private List<Agent> success;
8810
 
8811
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8812
    public enum _Fields implements TFieldIdEnum {
8813
      SUCCESS((short)0, "success");
8814
 
8815
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
8816
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8817
 
8818
      static {
8819
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8820
          byId.put((int)field._thriftId, field);
8821
          byName.put(field.getFieldName(), field);
8822
        }
8823
      }
8824
 
8825
      /**
8826
       * Find the _Fields constant that matches fieldId, or null if its not found.
8827
       */
8828
      public static _Fields findByThriftId(int fieldId) {
8829
        return byId.get(fieldId);
8830
      }
8831
 
8832
      /**
8833
       * Find the _Fields constant that matches fieldId, throwing an exception
8834
       * if it is not found.
8835
       */
8836
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8837
        _Fields fields = findByThriftId(fieldId);
8838
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8839
        return fields;
8840
      }
8841
 
8842
      /**
8843
       * Find the _Fields constant that matches name, or null if its not found.
8844
       */
8845
      public static _Fields findByName(String name) {
8846
        return byName.get(name);
8847
      }
8848
 
8849
      private final short _thriftId;
8850
      private final String _fieldName;
8851
 
8852
      _Fields(short thriftId, String fieldName) {
8853
        _thriftId = thriftId;
8854
        _fieldName = fieldName;
8855
      }
8856
 
8857
      public short getThriftFieldId() {
8858
        return _thriftId;
8859
      }
8860
 
8861
      public String getFieldName() {
8862
        return _fieldName;
8863
      }
8864
    }
8865
 
8866
    // isset id assignments
8867
 
8868
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
8869
      put(_Fields.SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, 
8870
          new ListMetaData(TType.LIST, 
8871
              new StructMetaData(TType.STRUCT, Agent.class))));
8872
    }});
8873
 
8874
    static {
8875
      FieldMetaData.addStructMetaDataMap(getAllAgents_result.class, metaDataMap);
8876
    }
8877
 
8878
    public getAllAgents_result() {
8879
    }
8880
 
8881
    public getAllAgents_result(
8882
      List<Agent> success)
8883
    {
8884
      this();
8885
      this.success = success;
8886
    }
8887
 
8888
    /**
8889
     * Performs a deep copy on <i>other</i>.
8890
     */
8891
    public getAllAgents_result(getAllAgents_result other) {
8892
      if (other.isSetSuccess()) {
8893
        List<Agent> __this__success = new ArrayList<Agent>();
8894
        for (Agent other_element : other.success) {
8895
          __this__success.add(new Agent(other_element));
8896
        }
8897
        this.success = __this__success;
8898
      }
8899
    }
8900
 
8901
    public getAllAgents_result deepCopy() {
8902
      return new getAllAgents_result(this);
8903
    }
8904
 
8905
    @Deprecated
8906
    public getAllAgents_result clone() {
8907
      return new getAllAgents_result(this);
8908
    }
8909
 
8910
    public int getSuccessSize() {
8911
      return (this.success == null) ? 0 : this.success.size();
8912
    }
8913
 
8914
    public java.util.Iterator<Agent> getSuccessIterator() {
8915
      return (this.success == null) ? null : this.success.iterator();
8916
    }
8917
 
8918
    public void addToSuccess(Agent elem) {
8919
      if (this.success == null) {
8920
        this.success = new ArrayList<Agent>();
8921
      }
8922
      this.success.add(elem);
8923
    }
8924
 
8925
    public List<Agent> getSuccess() {
8926
      return this.success;
8927
    }
8928
 
8929
    public getAllAgents_result setSuccess(List<Agent> success) {
8930
      this.success = success;
8931
      return this;
8932
    }
8933
 
8934
    public void unsetSuccess() {
8935
      this.success = null;
8936
    }
8937
 
8938
    /** Returns true if field success is set (has been asigned a value) and false otherwise */
8939
    public boolean isSetSuccess() {
8940
      return this.success != null;
8941
    }
8942
 
8943
    public void setSuccessIsSet(boolean value) {
8944
      if (!value) {
8945
        this.success = null;
8946
      }
8947
    }
8948
 
8949
    public void setFieldValue(_Fields field, Object value) {
8950
      switch (field) {
8951
      case SUCCESS:
8952
        if (value == null) {
8953
          unsetSuccess();
8954
        } else {
8955
          setSuccess((List<Agent>)value);
8956
        }
8957
        break;
8958
 
8959
      }
8960
    }
8961
 
8962
    public void setFieldValue(int fieldID, Object value) {
8963
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
8964
    }
8965
 
8966
    public Object getFieldValue(_Fields field) {
8967
      switch (field) {
8968
      case SUCCESS:
8969
        return getSuccess();
8970
 
8971
      }
8972
      throw new IllegalStateException();
8973
    }
8974
 
8975
    public Object getFieldValue(int fieldId) {
8976
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
8977
    }
8978
 
8979
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
8980
    public boolean isSet(_Fields field) {
8981
      switch (field) {
8982
      case SUCCESS:
8983
        return isSetSuccess();
8984
      }
8985
      throw new IllegalStateException();
8986
    }
8987
 
8988
    public boolean isSet(int fieldID) {
8989
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
8990
    }
8991
 
8992
    @Override
8993
    public boolean equals(Object that) {
8994
      if (that == null)
8995
        return false;
8996
      if (that instanceof getAllAgents_result)
8997
        return this.equals((getAllAgents_result)that);
8998
      return false;
8999
    }
9000
 
9001
    public boolean equals(getAllAgents_result that) {
9002
      if (that == null)
9003
        return false;
9004
 
9005
      boolean this_present_success = true && this.isSetSuccess();
9006
      boolean that_present_success = true && that.isSetSuccess();
9007
      if (this_present_success || that_present_success) {
9008
        if (!(this_present_success && that_present_success))
9009
          return false;
9010
        if (!this.success.equals(that.success))
9011
          return false;
9012
      }
9013
 
9014
      return true;
9015
    }
9016
 
9017
    @Override
9018
    public int hashCode() {
9019
      return 0;
9020
    }
9021
 
9022
    public int compareTo(getAllAgents_result other) {
9023
      if (!getClass().equals(other.getClass())) {
9024
        return getClass().getName().compareTo(other.getClass().getName());
9025
      }
9026
 
9027
      int lastComparison = 0;
9028
      getAllAgents_result typedOther = (getAllAgents_result)other;
9029
 
9030
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(isSetSuccess());
9031
      if (lastComparison != 0) {
9032
        return lastComparison;
9033
      }
9034
      lastComparison = TBaseHelper.compareTo(success, typedOther.success);
9035
      if (lastComparison != 0) {
9036
        return lastComparison;
9037
      }
9038
      return 0;
9039
    }
9040
 
9041
    public void read(TProtocol iprot) throws TException {
9042
      TField field;
9043
      iprot.readStructBegin();
9044
      while (true)
9045
      {
9046
        field = iprot.readFieldBegin();
9047
        if (field.type == TType.STOP) { 
9048
          break;
9049
        }
9050
        _Fields fieldId = _Fields.findByThriftId(field.id);
9051
        if (fieldId == null) {
9052
          TProtocolUtil.skip(iprot, field.type);
9053
        } else {
9054
          switch (fieldId) {
9055
            case SUCCESS:
9056
              if (field.type == TType.LIST) {
9057
                {
3339 mandeep.dh 9058
                  TList _list28 = iprot.readListBegin();
9059
                  this.success = new ArrayList<Agent>(_list28.size);
9060
                  for (int _i29 = 0; _i29 < _list28.size; ++_i29)
3087 mandeep.dh 9061
                  {
3339 mandeep.dh 9062
                    Agent _elem30;
9063
                    _elem30 = new Agent();
9064
                    _elem30.read(iprot);
9065
                    this.success.add(_elem30);
3087 mandeep.dh 9066
                  }
9067
                  iprot.readListEnd();
9068
                }
9069
              } else { 
9070
                TProtocolUtil.skip(iprot, field.type);
9071
              }
9072
              break;
9073
          }
9074
          iprot.readFieldEnd();
9075
        }
9076
      }
9077
      iprot.readStructEnd();
9078
      validate();
9079
    }
9080
 
9081
    public void write(TProtocol oprot) throws TException {
9082
      oprot.writeStructBegin(STRUCT_DESC);
9083
 
9084
      if (this.isSetSuccess()) {
9085
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
9086
        {
9087
          oprot.writeListBegin(new TList(TType.STRUCT, this.success.size()));
3339 mandeep.dh 9088
          for (Agent _iter31 : this.success)
3087 mandeep.dh 9089
          {
3339 mandeep.dh 9090
            _iter31.write(oprot);
3087 mandeep.dh 9091
          }
9092
          oprot.writeListEnd();
9093
        }
9094
        oprot.writeFieldEnd();
9095
      }
9096
      oprot.writeFieldStop();
9097
      oprot.writeStructEnd();
9098
    }
9099
 
9100
    @Override
9101
    public String toString() {
9102
      StringBuilder sb = new StringBuilder("getAllAgents_result(");
9103
      boolean first = true;
9104
 
9105
      sb.append("success:");
9106
      if (this.success == null) {
9107
        sb.append("null");
9108
      } else {
9109
        sb.append(this.success);
9110
      }
9111
      first = false;
9112
      sb.append(")");
9113
      return sb.toString();
9114
    }
9115
 
9116
    public void validate() throws TException {
9117
      // check for required fields
9118
    }
9119
 
9120
  }
9121
 
3028 mandeep.dh 9122
  public static class getAgent_args implements TBase<getAgent_args._Fields>, java.io.Serializable, Cloneable, Comparable<getAgent_args>   {
9123
    private static final TStruct STRUCT_DESC = new TStruct("getAgent_args");
9124
 
9125
    private static final TField AGENT_ID_FIELD_DESC = new TField("agentId", TType.I64, (short)1);
9126
 
9127
    private long agentId;
9128
 
9129
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
9130
    public enum _Fields implements TFieldIdEnum {
9131
      AGENT_ID((short)1, "agentId");
9132
 
9133
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
9134
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9135
 
9136
      static {
9137
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9138
          byId.put((int)field._thriftId, field);
9139
          byName.put(field.getFieldName(), field);
9140
        }
9141
      }
9142
 
9143
      /**
9144
       * Find the _Fields constant that matches fieldId, or null if its not found.
9145
       */
9146
      public static _Fields findByThriftId(int fieldId) {
9147
        return byId.get(fieldId);
9148
      }
9149
 
9150
      /**
9151
       * Find the _Fields constant that matches fieldId, throwing an exception
9152
       * if it is not found.
9153
       */
9154
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9155
        _Fields fields = findByThriftId(fieldId);
9156
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9157
        return fields;
9158
      }
9159
 
9160
      /**
9161
       * Find the _Fields constant that matches name, or null if its not found.
9162
       */
9163
      public static _Fields findByName(String name) {
9164
        return byName.get(name);
9165
      }
9166
 
9167
      private final short _thriftId;
9168
      private final String _fieldName;
9169
 
9170
      _Fields(short thriftId, String fieldName) {
9171
        _thriftId = thriftId;
9172
        _fieldName = fieldName;
9173
      }
9174
 
9175
      public short getThriftFieldId() {
9176
        return _thriftId;
9177
      }
9178
 
9179
      public String getFieldName() {
9180
        return _fieldName;
9181
      }
9182
    }
9183
 
9184
    // isset id assignments
9185
    private static final int __AGENTID_ISSET_ID = 0;
9186
    private BitSet __isset_bit_vector = new BitSet(1);
9187
 
9188
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
9189
      put(_Fields.AGENT_ID, new FieldMetaData("agentId", TFieldRequirementType.DEFAULT, 
9190
          new FieldValueMetaData(TType.I64)));
9191
    }});
9192
 
9193
    static {
9194
      FieldMetaData.addStructMetaDataMap(getAgent_args.class, metaDataMap);
9195
    }
9196
 
9197
    public getAgent_args() {
9198
    }
9199
 
9200
    public getAgent_args(
9201
      long agentId)
9202
    {
9203
      this();
9204
      this.agentId = agentId;
9205
      setAgentIdIsSet(true);
9206
    }
9207
 
9208
    /**
9209
     * Performs a deep copy on <i>other</i>.
9210
     */
9211
    public getAgent_args(getAgent_args other) {
9212
      __isset_bit_vector.clear();
9213
      __isset_bit_vector.or(other.__isset_bit_vector);
9214
      this.agentId = other.agentId;
9215
    }
9216
 
9217
    public getAgent_args deepCopy() {
9218
      return new getAgent_args(this);
9219
    }
9220
 
9221
    @Deprecated
9222
    public getAgent_args clone() {
9223
      return new getAgent_args(this);
9224
    }
9225
 
9226
    public long getAgentId() {
9227
      return this.agentId;
9228
    }
9229
 
9230
    public getAgent_args setAgentId(long agentId) {
9231
      this.agentId = agentId;
9232
      setAgentIdIsSet(true);
9233
      return this;
9234
    }
9235
 
9236
    public void unsetAgentId() {
9237
      __isset_bit_vector.clear(__AGENTID_ISSET_ID);
9238
    }
9239
 
9240
    /** Returns true if field agentId is set (has been asigned a value) and false otherwise */
9241
    public boolean isSetAgentId() {
9242
      return __isset_bit_vector.get(__AGENTID_ISSET_ID);
9243
    }
9244
 
9245
    public void setAgentIdIsSet(boolean value) {
9246
      __isset_bit_vector.set(__AGENTID_ISSET_ID, value);
9247
    }
9248
 
9249
    public void setFieldValue(_Fields field, Object value) {
9250
      switch (field) {
9251
      case AGENT_ID:
9252
        if (value == null) {
9253
          unsetAgentId();
9254
        } else {
9255
          setAgentId((Long)value);
9256
        }
9257
        break;
9258
 
9259
      }
9260
    }
9261
 
9262
    public void setFieldValue(int fieldID, Object value) {
9263
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
9264
    }
9265
 
9266
    public Object getFieldValue(_Fields field) {
9267
      switch (field) {
9268
      case AGENT_ID:
9269
        return new Long(getAgentId());
9270
 
9271
      }
9272
      throw new IllegalStateException();
9273
    }
9274
 
9275
    public Object getFieldValue(int fieldId) {
9276
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
9277
    }
9278
 
9279
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
9280
    public boolean isSet(_Fields field) {
9281
      switch (field) {
9282
      case AGENT_ID:
9283
        return isSetAgentId();
9284
      }
9285
      throw new IllegalStateException();
9286
    }
9287
 
9288
    public boolean isSet(int fieldID) {
9289
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
9290
    }
9291
 
9292
    @Override
9293
    public boolean equals(Object that) {
9294
      if (that == null)
9295
        return false;
9296
      if (that instanceof getAgent_args)
9297
        return this.equals((getAgent_args)that);
9298
      return false;
9299
    }
9300
 
9301
    public boolean equals(getAgent_args that) {
9302
      if (that == null)
9303
        return false;
9304
 
9305
      boolean this_present_agentId = true;
9306
      boolean that_present_agentId = true;
9307
      if (this_present_agentId || that_present_agentId) {
9308
        if (!(this_present_agentId && that_present_agentId))
9309
          return false;
9310
        if (this.agentId != that.agentId)
9311
          return false;
9312
      }
9313
 
9314
      return true;
9315
    }
9316
 
9317
    @Override
9318
    public int hashCode() {
9319
      return 0;
9320
    }
9321
 
9322
    public int compareTo(getAgent_args other) {
9323
      if (!getClass().equals(other.getClass())) {
9324
        return getClass().getName().compareTo(other.getClass().getName());
9325
      }
9326
 
9327
      int lastComparison = 0;
9328
      getAgent_args typedOther = (getAgent_args)other;
9329
 
9330
      lastComparison = Boolean.valueOf(isSetAgentId()).compareTo(isSetAgentId());
9331
      if (lastComparison != 0) {
9332
        return lastComparison;
9333
      }
9334
      lastComparison = TBaseHelper.compareTo(agentId, typedOther.agentId);
9335
      if (lastComparison != 0) {
9336
        return lastComparison;
9337
      }
9338
      return 0;
9339
    }
9340
 
9341
    public void read(TProtocol iprot) throws TException {
9342
      TField field;
9343
      iprot.readStructBegin();
9344
      while (true)
9345
      {
9346
        field = iprot.readFieldBegin();
9347
        if (field.type == TType.STOP) { 
9348
          break;
9349
        }
9350
        _Fields fieldId = _Fields.findByThriftId(field.id);
9351
        if (fieldId == null) {
9352
          TProtocolUtil.skip(iprot, field.type);
9353
        } else {
9354
          switch (fieldId) {
9355
            case AGENT_ID:
9356
              if (field.type == TType.I64) {
9357
                this.agentId = iprot.readI64();
9358
                setAgentIdIsSet(true);
9359
              } else { 
9360
                TProtocolUtil.skip(iprot, field.type);
9361
              }
9362
              break;
9363
          }
9364
          iprot.readFieldEnd();
9365
        }
9366
      }
9367
      iprot.readStructEnd();
9368
      validate();
9369
    }
9370
 
9371
    public void write(TProtocol oprot) throws TException {
9372
      validate();
9373
 
9374
      oprot.writeStructBegin(STRUCT_DESC);
9375
      oprot.writeFieldBegin(AGENT_ID_FIELD_DESC);
9376
      oprot.writeI64(this.agentId);
9377
      oprot.writeFieldEnd();
9378
      oprot.writeFieldStop();
9379
      oprot.writeStructEnd();
9380
    }
9381
 
9382
    @Override
9383
    public String toString() {
9384
      StringBuilder sb = new StringBuilder("getAgent_args(");
9385
      boolean first = true;
9386
 
9387
      sb.append("agentId:");
9388
      sb.append(this.agentId);
9389
      first = false;
9390
      sb.append(")");
9391
      return sb.toString();
9392
    }
9393
 
9394
    public void validate() throws TException {
9395
      // check for required fields
9396
    }
9397
 
9398
  }
9399
 
9400
  public static class getAgent_result implements TBase<getAgent_result._Fields>, java.io.Serializable, Cloneable, Comparable<getAgent_result>   {
9401
    private static final TStruct STRUCT_DESC = new TStruct("getAgent_result");
9402
 
9403
    private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0);
9404
 
9405
    private Agent success;
9406
 
9407
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
9408
    public enum _Fields implements TFieldIdEnum {
9409
      SUCCESS((short)0, "success");
9410
 
9411
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
9412
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9413
 
9414
      static {
9415
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9416
          byId.put((int)field._thriftId, field);
9417
          byName.put(field.getFieldName(), field);
9418
        }
9419
      }
9420
 
9421
      /**
9422
       * Find the _Fields constant that matches fieldId, or null if its not found.
9423
       */
9424
      public static _Fields findByThriftId(int fieldId) {
9425
        return byId.get(fieldId);
9426
      }
9427
 
9428
      /**
9429
       * Find the _Fields constant that matches fieldId, throwing an exception
9430
       * if it is not found.
9431
       */
9432
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9433
        _Fields fields = findByThriftId(fieldId);
9434
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9435
        return fields;
9436
      }
9437
 
9438
      /**
9439
       * Find the _Fields constant that matches name, or null if its not found.
9440
       */
9441
      public static _Fields findByName(String name) {
9442
        return byName.get(name);
9443
      }
9444
 
9445
      private final short _thriftId;
9446
      private final String _fieldName;
9447
 
9448
      _Fields(short thriftId, String fieldName) {
9449
        _thriftId = thriftId;
9450
        _fieldName = fieldName;
9451
      }
9452
 
9453
      public short getThriftFieldId() {
9454
        return _thriftId;
9455
      }
9456
 
9457
      public String getFieldName() {
9458
        return _fieldName;
9459
      }
9460
    }
9461
 
9462
    // isset id assignments
9463
 
9464
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
9465
      put(_Fields.SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, 
9466
          new StructMetaData(TType.STRUCT, Agent.class)));
9467
    }});
9468
 
9469
    static {
9470
      FieldMetaData.addStructMetaDataMap(getAgent_result.class, metaDataMap);
9471
    }
9472
 
9473
    public getAgent_result() {
9474
    }
9475
 
9476
    public getAgent_result(
9477
      Agent success)
9478
    {
9479
      this();
9480
      this.success = success;
9481
    }
9482
 
9483
    /**
9484
     * Performs a deep copy on <i>other</i>.
9485
     */
9486
    public getAgent_result(getAgent_result other) {
9487
      if (other.isSetSuccess()) {
9488
        this.success = new Agent(other.success);
9489
      }
9490
    }
9491
 
9492
    public getAgent_result deepCopy() {
9493
      return new getAgent_result(this);
9494
    }
9495
 
9496
    @Deprecated
9497
    public getAgent_result clone() {
9498
      return new getAgent_result(this);
9499
    }
9500
 
9501
    public Agent getSuccess() {
9502
      return this.success;
9503
    }
9504
 
9505
    public getAgent_result setSuccess(Agent success) {
9506
      this.success = success;
9507
      return this;
9508
    }
9509
 
9510
    public void unsetSuccess() {
9511
      this.success = null;
9512
    }
9513
 
9514
    /** Returns true if field success is set (has been asigned a value) and false otherwise */
9515
    public boolean isSetSuccess() {
9516
      return this.success != null;
9517
    }
9518
 
9519
    public void setSuccessIsSet(boolean value) {
9520
      if (!value) {
9521
        this.success = null;
9522
      }
9523
    }
9524
 
9525
    public void setFieldValue(_Fields field, Object value) {
9526
      switch (field) {
9527
      case SUCCESS:
9528
        if (value == null) {
9529
          unsetSuccess();
9530
        } else {
9531
          setSuccess((Agent)value);
9532
        }
9533
        break;
9534
 
9535
      }
9536
    }
9537
 
9538
    public void setFieldValue(int fieldID, Object value) {
9539
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
9540
    }
9541
 
9542
    public Object getFieldValue(_Fields field) {
9543
      switch (field) {
9544
      case SUCCESS:
9545
        return getSuccess();
9546
 
9547
      }
9548
      throw new IllegalStateException();
9549
    }
9550
 
9551
    public Object getFieldValue(int fieldId) {
9552
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
9553
    }
9554
 
9555
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
9556
    public boolean isSet(_Fields field) {
9557
      switch (field) {
9558
      case SUCCESS:
9559
        return isSetSuccess();
9560
      }
9561
      throw new IllegalStateException();
9562
    }
9563
 
9564
    public boolean isSet(int fieldID) {
9565
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
9566
    }
9567
 
9568
    @Override
9569
    public boolean equals(Object that) {
9570
      if (that == null)
9571
        return false;
9572
      if (that instanceof getAgent_result)
9573
        return this.equals((getAgent_result)that);
9574
      return false;
9575
    }
9576
 
9577
    public boolean equals(getAgent_result that) {
9578
      if (that == null)
9579
        return false;
9580
 
9581
      boolean this_present_success = true && this.isSetSuccess();
9582
      boolean that_present_success = true && that.isSetSuccess();
9583
      if (this_present_success || that_present_success) {
9584
        if (!(this_present_success && that_present_success))
9585
          return false;
9586
        if (!this.success.equals(that.success))
9587
          return false;
9588
      }
9589
 
9590
      return true;
9591
    }
9592
 
9593
    @Override
9594
    public int hashCode() {
9595
      return 0;
9596
    }
9597
 
9598
    public int compareTo(getAgent_result other) {
9599
      if (!getClass().equals(other.getClass())) {
9600
        return getClass().getName().compareTo(other.getClass().getName());
9601
      }
9602
 
9603
      int lastComparison = 0;
9604
      getAgent_result typedOther = (getAgent_result)other;
9605
 
9606
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(isSetSuccess());
9607
      if (lastComparison != 0) {
9608
        return lastComparison;
9609
      }
9610
      lastComparison = TBaseHelper.compareTo(success, typedOther.success);
9611
      if (lastComparison != 0) {
9612
        return lastComparison;
9613
      }
9614
      return 0;
9615
    }
9616
 
9617
    public void read(TProtocol iprot) throws TException {
9618
      TField field;
9619
      iprot.readStructBegin();
9620
      while (true)
9621
      {
9622
        field = iprot.readFieldBegin();
9623
        if (field.type == TType.STOP) { 
9624
          break;
9625
        }
9626
        _Fields fieldId = _Fields.findByThriftId(field.id);
9627
        if (fieldId == null) {
9628
          TProtocolUtil.skip(iprot, field.type);
9629
        } else {
9630
          switch (fieldId) {
9631
            case SUCCESS:
9632
              if (field.type == TType.STRUCT) {
9633
                this.success = new Agent();
9634
                this.success.read(iprot);
9635
              } else { 
9636
                TProtocolUtil.skip(iprot, field.type);
9637
              }
9638
              break;
9639
          }
9640
          iprot.readFieldEnd();
9641
        }
9642
      }
9643
      iprot.readStructEnd();
9644
      validate();
9645
    }
9646
 
9647
    public void write(TProtocol oprot) throws TException {
9648
      oprot.writeStructBegin(STRUCT_DESC);
9649
 
9650
      if (this.isSetSuccess()) {
9651
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
9652
        this.success.write(oprot);
9653
        oprot.writeFieldEnd();
9654
      }
9655
      oprot.writeFieldStop();
9656
      oprot.writeStructEnd();
9657
    }
9658
 
9659
    @Override
9660
    public String toString() {
9661
      StringBuilder sb = new StringBuilder("getAgent_result(");
9662
      boolean first = true;
9663
 
9664
      sb.append("success:");
9665
      if (this.success == null) {
9666
        sb.append("null");
9667
      } else {
9668
        sb.append(this.success);
9669
      }
9670
      first = false;
9671
      sb.append(")");
9672
      return sb.toString();
9673
    }
9674
 
9675
    public void validate() throws TException {
9676
      // check for required fields
9677
    }
9678
 
9679
  }
9680
 
9681
  public static class getAgentByEmailId_args implements TBase<getAgentByEmailId_args._Fields>, java.io.Serializable, Cloneable, Comparable<getAgentByEmailId_args>   {
9682
    private static final TStruct STRUCT_DESC = new TStruct("getAgentByEmailId_args");
9683
 
9684
    private static final TField AGENT_EMAIL_ID_FIELD_DESC = new TField("agentEmailId", TType.STRING, (short)1);
9685
 
9686
    private String agentEmailId;
9687
 
9688
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
9689
    public enum _Fields implements TFieldIdEnum {
9690
      AGENT_EMAIL_ID((short)1, "agentEmailId");
9691
 
9692
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
9693
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9694
 
9695
      static {
9696
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9697
          byId.put((int)field._thriftId, field);
9698
          byName.put(field.getFieldName(), field);
9699
        }
9700
      }
9701
 
9702
      /**
9703
       * Find the _Fields constant that matches fieldId, or null if its not found.
9704
       */
9705
      public static _Fields findByThriftId(int fieldId) {
9706
        return byId.get(fieldId);
9707
      }
9708
 
9709
      /**
9710
       * Find the _Fields constant that matches fieldId, throwing an exception
9711
       * if it is not found.
9712
       */
9713
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9714
        _Fields fields = findByThriftId(fieldId);
9715
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9716
        return fields;
9717
      }
9718
 
9719
      /**
9720
       * Find the _Fields constant that matches name, or null if its not found.
9721
       */
9722
      public static _Fields findByName(String name) {
9723
        return byName.get(name);
9724
      }
9725
 
9726
      private final short _thriftId;
9727
      private final String _fieldName;
9728
 
9729
      _Fields(short thriftId, String fieldName) {
9730
        _thriftId = thriftId;
9731
        _fieldName = fieldName;
9732
      }
9733
 
9734
      public short getThriftFieldId() {
9735
        return _thriftId;
9736
      }
9737
 
9738
      public String getFieldName() {
9739
        return _fieldName;
9740
      }
9741
    }
9742
 
9743
    // isset id assignments
9744
 
9745
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
9746
      put(_Fields.AGENT_EMAIL_ID, new FieldMetaData("agentEmailId", TFieldRequirementType.DEFAULT, 
9747
          new FieldValueMetaData(TType.STRING)));
9748
    }});
9749
 
9750
    static {
9751
      FieldMetaData.addStructMetaDataMap(getAgentByEmailId_args.class, metaDataMap);
9752
    }
9753
 
9754
    public getAgentByEmailId_args() {
9755
    }
9756
 
9757
    public getAgentByEmailId_args(
9758
      String agentEmailId)
9759
    {
9760
      this();
9761
      this.agentEmailId = agentEmailId;
9762
    }
9763
 
9764
    /**
9765
     * Performs a deep copy on <i>other</i>.
9766
     */
9767
    public getAgentByEmailId_args(getAgentByEmailId_args other) {
9768
      if (other.isSetAgentEmailId()) {
9769
        this.agentEmailId = other.agentEmailId;
9770
      }
9771
    }
9772
 
9773
    public getAgentByEmailId_args deepCopy() {
9774
      return new getAgentByEmailId_args(this);
9775
    }
9776
 
9777
    @Deprecated
9778
    public getAgentByEmailId_args clone() {
9779
      return new getAgentByEmailId_args(this);
9780
    }
9781
 
9782
    public String getAgentEmailId() {
9783
      return this.agentEmailId;
9784
    }
9785
 
9786
    public getAgentByEmailId_args setAgentEmailId(String agentEmailId) {
9787
      this.agentEmailId = agentEmailId;
9788
      return this;
9789
    }
9790
 
9791
    public void unsetAgentEmailId() {
9792
      this.agentEmailId = null;
9793
    }
9794
 
9795
    /** Returns true if field agentEmailId is set (has been asigned a value) and false otherwise */
9796
    public boolean isSetAgentEmailId() {
9797
      return this.agentEmailId != null;
9798
    }
9799
 
9800
    public void setAgentEmailIdIsSet(boolean value) {
9801
      if (!value) {
9802
        this.agentEmailId = null;
9803
      }
9804
    }
9805
 
9806
    public void setFieldValue(_Fields field, Object value) {
9807
      switch (field) {
9808
      case AGENT_EMAIL_ID:
9809
        if (value == null) {
9810
          unsetAgentEmailId();
9811
        } else {
9812
          setAgentEmailId((String)value);
9813
        }
9814
        break;
9815
 
9816
      }
9817
    }
9818
 
9819
    public void setFieldValue(int fieldID, Object value) {
9820
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
9821
    }
9822
 
9823
    public Object getFieldValue(_Fields field) {
9824
      switch (field) {
9825
      case AGENT_EMAIL_ID:
9826
        return getAgentEmailId();
9827
 
9828
      }
9829
      throw new IllegalStateException();
9830
    }
9831
 
9832
    public Object getFieldValue(int fieldId) {
9833
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
9834
    }
9835
 
9836
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
9837
    public boolean isSet(_Fields field) {
9838
      switch (field) {
9839
      case AGENT_EMAIL_ID:
9840
        return isSetAgentEmailId();
9841
      }
9842
      throw new IllegalStateException();
9843
    }
9844
 
9845
    public boolean isSet(int fieldID) {
9846
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
9847
    }
9848
 
9849
    @Override
9850
    public boolean equals(Object that) {
9851
      if (that == null)
9852
        return false;
9853
      if (that instanceof getAgentByEmailId_args)
9854
        return this.equals((getAgentByEmailId_args)that);
9855
      return false;
9856
    }
9857
 
9858
    public boolean equals(getAgentByEmailId_args that) {
9859
      if (that == null)
9860
        return false;
9861
 
9862
      boolean this_present_agentEmailId = true && this.isSetAgentEmailId();
9863
      boolean that_present_agentEmailId = true && that.isSetAgentEmailId();
9864
      if (this_present_agentEmailId || that_present_agentEmailId) {
9865
        if (!(this_present_agentEmailId && that_present_agentEmailId))
9866
          return false;
9867
        if (!this.agentEmailId.equals(that.agentEmailId))
9868
          return false;
9869
      }
9870
 
9871
      return true;
9872
    }
9873
 
9874
    @Override
9875
    public int hashCode() {
9876
      return 0;
9877
    }
9878
 
9879
    public int compareTo(getAgentByEmailId_args other) {
9880
      if (!getClass().equals(other.getClass())) {
9881
        return getClass().getName().compareTo(other.getClass().getName());
9882
      }
9883
 
9884
      int lastComparison = 0;
9885
      getAgentByEmailId_args typedOther = (getAgentByEmailId_args)other;
9886
 
9887
      lastComparison = Boolean.valueOf(isSetAgentEmailId()).compareTo(isSetAgentEmailId());
9888
      if (lastComparison != 0) {
9889
        return lastComparison;
9890
      }
9891
      lastComparison = TBaseHelper.compareTo(agentEmailId, typedOther.agentEmailId);
9892
      if (lastComparison != 0) {
9893
        return lastComparison;
9894
      }
9895
      return 0;
9896
    }
9897
 
9898
    public void read(TProtocol iprot) throws TException {
9899
      TField field;
9900
      iprot.readStructBegin();
9901
      while (true)
9902
      {
9903
        field = iprot.readFieldBegin();
9904
        if (field.type == TType.STOP) { 
9905
          break;
9906
        }
9907
        _Fields fieldId = _Fields.findByThriftId(field.id);
9908
        if (fieldId == null) {
9909
          TProtocolUtil.skip(iprot, field.type);
9910
        } else {
9911
          switch (fieldId) {
9912
            case AGENT_EMAIL_ID:
9913
              if (field.type == TType.STRING) {
9914
                this.agentEmailId = iprot.readString();
9915
              } else { 
9916
                TProtocolUtil.skip(iprot, field.type);
9917
              }
9918
              break;
9919
          }
9920
          iprot.readFieldEnd();
9921
        }
9922
      }
9923
      iprot.readStructEnd();
9924
      validate();
9925
    }
9926
 
9927
    public void write(TProtocol oprot) throws TException {
9928
      validate();
9929
 
9930
      oprot.writeStructBegin(STRUCT_DESC);
9931
      if (this.agentEmailId != null) {
9932
        oprot.writeFieldBegin(AGENT_EMAIL_ID_FIELD_DESC);
9933
        oprot.writeString(this.agentEmailId);
9934
        oprot.writeFieldEnd();
9935
      }
9936
      oprot.writeFieldStop();
9937
      oprot.writeStructEnd();
9938
    }
9939
 
9940
    @Override
9941
    public String toString() {
9942
      StringBuilder sb = new StringBuilder("getAgentByEmailId_args(");
9943
      boolean first = true;
9944
 
9945
      sb.append("agentEmailId:");
9946
      if (this.agentEmailId == null) {
9947
        sb.append("null");
9948
      } else {
9949
        sb.append(this.agentEmailId);
9950
      }
9951
      first = false;
9952
      sb.append(")");
9953
      return sb.toString();
9954
    }
9955
 
9956
    public void validate() throws TException {
9957
      // check for required fields
9958
    }
9959
 
9960
  }
9961
 
9962
  public static class getAgentByEmailId_result implements TBase<getAgentByEmailId_result._Fields>, java.io.Serializable, Cloneable, Comparable<getAgentByEmailId_result>   {
9963
    private static final TStruct STRUCT_DESC = new TStruct("getAgentByEmailId_result");
9964
 
9965
    private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.STRUCT, (short)0);
9966
 
9967
    private Agent success;
9968
 
9969
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
9970
    public enum _Fields implements TFieldIdEnum {
9971
      SUCCESS((short)0, "success");
9972
 
9973
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
9974
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9975
 
9976
      static {
9977
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9978
          byId.put((int)field._thriftId, field);
9979
          byName.put(field.getFieldName(), field);
9980
        }
9981
      }
9982
 
9983
      /**
9984
       * Find the _Fields constant that matches fieldId, or null if its not found.
9985
       */
9986
      public static _Fields findByThriftId(int fieldId) {
9987
        return byId.get(fieldId);
9988
      }
9989
 
9990
      /**
9991
       * Find the _Fields constant that matches fieldId, throwing an exception
9992
       * if it is not found.
9993
       */
9994
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9995
        _Fields fields = findByThriftId(fieldId);
9996
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9997
        return fields;
9998
      }
9999
 
10000
      /**
10001
       * Find the _Fields constant that matches name, or null if its not found.
10002
       */
10003
      public static _Fields findByName(String name) {
10004
        return byName.get(name);
10005
      }
10006
 
10007
      private final short _thriftId;
10008
      private final String _fieldName;
10009
 
10010
      _Fields(short thriftId, String fieldName) {
10011
        _thriftId = thriftId;
10012
        _fieldName = fieldName;
10013
      }
10014
 
10015
      public short getThriftFieldId() {
10016
        return _thriftId;
10017
      }
10018
 
10019
      public String getFieldName() {
10020
        return _fieldName;
10021
      }
10022
    }
10023
 
10024
    // isset id assignments
10025
 
10026
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
10027
      put(_Fields.SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, 
10028
          new StructMetaData(TType.STRUCT, Agent.class)));
10029
    }});
10030
 
10031
    static {
10032
      FieldMetaData.addStructMetaDataMap(getAgentByEmailId_result.class, metaDataMap);
10033
    }
10034
 
10035
    public getAgentByEmailId_result() {
10036
    }
10037
 
10038
    public getAgentByEmailId_result(
10039
      Agent success)
10040
    {
10041
      this();
10042
      this.success = success;
10043
    }
10044
 
10045
    /**
10046
     * Performs a deep copy on <i>other</i>.
10047
     */
10048
    public getAgentByEmailId_result(getAgentByEmailId_result other) {
10049
      if (other.isSetSuccess()) {
10050
        this.success = new Agent(other.success);
10051
      }
10052
    }
10053
 
10054
    public getAgentByEmailId_result deepCopy() {
10055
      return new getAgentByEmailId_result(this);
10056
    }
10057
 
10058
    @Deprecated
10059
    public getAgentByEmailId_result clone() {
10060
      return new getAgentByEmailId_result(this);
10061
    }
10062
 
10063
    public Agent getSuccess() {
10064
      return this.success;
10065
    }
10066
 
10067
    public getAgentByEmailId_result setSuccess(Agent success) {
10068
      this.success = success;
10069
      return this;
10070
    }
10071
 
10072
    public void unsetSuccess() {
10073
      this.success = null;
10074
    }
10075
 
10076
    /** Returns true if field success is set (has been asigned a value) and false otherwise */
10077
    public boolean isSetSuccess() {
10078
      return this.success != null;
10079
    }
10080
 
10081
    public void setSuccessIsSet(boolean value) {
10082
      if (!value) {
10083
        this.success = null;
10084
      }
10085
    }
10086
 
10087
    public void setFieldValue(_Fields field, Object value) {
10088
      switch (field) {
10089
      case SUCCESS:
10090
        if (value == null) {
10091
          unsetSuccess();
10092
        } else {
10093
          setSuccess((Agent)value);
10094
        }
10095
        break;
10096
 
10097
      }
10098
    }
10099
 
10100
    public void setFieldValue(int fieldID, Object value) {
10101
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
10102
    }
10103
 
10104
    public Object getFieldValue(_Fields field) {
10105
      switch (field) {
10106
      case SUCCESS:
10107
        return getSuccess();
10108
 
10109
      }
10110
      throw new IllegalStateException();
10111
    }
10112
 
10113
    public Object getFieldValue(int fieldId) {
10114
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
10115
    }
10116
 
10117
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
10118
    public boolean isSet(_Fields field) {
10119
      switch (field) {
10120
      case SUCCESS:
10121
        return isSetSuccess();
10122
      }
10123
      throw new IllegalStateException();
10124
    }
10125
 
10126
    public boolean isSet(int fieldID) {
10127
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
10128
    }
10129
 
10130
    @Override
10131
    public boolean equals(Object that) {
10132
      if (that == null)
10133
        return false;
10134
      if (that instanceof getAgentByEmailId_result)
10135
        return this.equals((getAgentByEmailId_result)that);
10136
      return false;
10137
    }
10138
 
10139
    public boolean equals(getAgentByEmailId_result that) {
10140
      if (that == null)
10141
        return false;
10142
 
10143
      boolean this_present_success = true && this.isSetSuccess();
10144
      boolean that_present_success = true && that.isSetSuccess();
10145
      if (this_present_success || that_present_success) {
10146
        if (!(this_present_success && that_present_success))
10147
          return false;
10148
        if (!this.success.equals(that.success))
10149
          return false;
10150
      }
10151
 
10152
      return true;
10153
    }
10154
 
10155
    @Override
10156
    public int hashCode() {
10157
      return 0;
10158
    }
10159
 
10160
    public int compareTo(getAgentByEmailId_result other) {
10161
      if (!getClass().equals(other.getClass())) {
10162
        return getClass().getName().compareTo(other.getClass().getName());
10163
      }
10164
 
10165
      int lastComparison = 0;
10166
      getAgentByEmailId_result typedOther = (getAgentByEmailId_result)other;
10167
 
10168
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(isSetSuccess());
10169
      if (lastComparison != 0) {
10170
        return lastComparison;
10171
      }
10172
      lastComparison = TBaseHelper.compareTo(success, typedOther.success);
10173
      if (lastComparison != 0) {
10174
        return lastComparison;
10175
      }
10176
      return 0;
10177
    }
10178
 
10179
    public void read(TProtocol iprot) throws TException {
10180
      TField field;
10181
      iprot.readStructBegin();
10182
      while (true)
10183
      {
10184
        field = iprot.readFieldBegin();
10185
        if (field.type == TType.STOP) { 
10186
          break;
10187
        }
10188
        _Fields fieldId = _Fields.findByThriftId(field.id);
10189
        if (fieldId == null) {
10190
          TProtocolUtil.skip(iprot, field.type);
10191
        } else {
10192
          switch (fieldId) {
10193
            case SUCCESS:
10194
              if (field.type == TType.STRUCT) {
10195
                this.success = new Agent();
10196
                this.success.read(iprot);
10197
              } else { 
10198
                TProtocolUtil.skip(iprot, field.type);
10199
              }
10200
              break;
10201
          }
10202
          iprot.readFieldEnd();
10203
        }
10204
      }
10205
      iprot.readStructEnd();
10206
      validate();
10207
    }
10208
 
10209
    public void write(TProtocol oprot) throws TException {
10210
      oprot.writeStructBegin(STRUCT_DESC);
10211
 
10212
      if (this.isSetSuccess()) {
10213
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
10214
        this.success.write(oprot);
10215
        oprot.writeFieldEnd();
10216
      }
10217
      oprot.writeFieldStop();
10218
      oprot.writeStructEnd();
10219
    }
10220
 
10221
    @Override
10222
    public String toString() {
10223
      StringBuilder sb = new StringBuilder("getAgentByEmailId_result(");
10224
      boolean first = true;
10225
 
10226
      sb.append("success:");
10227
      if (this.success == null) {
10228
        sb.append("null");
10229
      } else {
10230
        sb.append(this.success);
10231
      }
10232
      first = false;
10233
      sb.append(")");
10234
      return sb.toString();
10235
    }
10236
 
10237
    public void validate() throws TException {
10238
      // check for required fields
10239
    }
10240
 
10241
  }
10242
 
3087 mandeep.dh 10243
  public static class updatePasswordForAgent_args implements TBase<updatePasswordForAgent_args._Fields>, java.io.Serializable, Cloneable, Comparable<updatePasswordForAgent_args>   {
10244
    private static final TStruct STRUCT_DESC = new TStruct("updatePasswordForAgent_args");
10245
 
10246
    private static final TField AGENT_EMAIL_ID_FIELD_DESC = new TField("agentEmailId", TType.STRING, (short)1);
10247
    private static final TField PASSWORD_FIELD_DESC = new TField("password", TType.STRING, (short)2);
10248
 
10249
    private String agentEmailId;
10250
    private String password;
10251
 
10252
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
10253
    public enum _Fields implements TFieldIdEnum {
10254
      AGENT_EMAIL_ID((short)1, "agentEmailId"),
10255
      PASSWORD((short)2, "password");
10256
 
10257
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
10258
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
10259
 
10260
      static {
10261
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
10262
          byId.put((int)field._thriftId, field);
10263
          byName.put(field.getFieldName(), field);
10264
        }
10265
      }
10266
 
10267
      /**
10268
       * Find the _Fields constant that matches fieldId, or null if its not found.
10269
       */
10270
      public static _Fields findByThriftId(int fieldId) {
10271
        return byId.get(fieldId);
10272
      }
10273
 
10274
      /**
10275
       * Find the _Fields constant that matches fieldId, throwing an exception
10276
       * if it is not found.
10277
       */
10278
      public static _Fields findByThriftIdOrThrow(int fieldId) {
10279
        _Fields fields = findByThriftId(fieldId);
10280
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
10281
        return fields;
10282
      }
10283
 
10284
      /**
10285
       * Find the _Fields constant that matches name, or null if its not found.
10286
       */
10287
      public static _Fields findByName(String name) {
10288
        return byName.get(name);
10289
      }
10290
 
10291
      private final short _thriftId;
10292
      private final String _fieldName;
10293
 
10294
      _Fields(short thriftId, String fieldName) {
10295
        _thriftId = thriftId;
10296
        _fieldName = fieldName;
10297
      }
10298
 
10299
      public short getThriftFieldId() {
10300
        return _thriftId;
10301
      }
10302
 
10303
      public String getFieldName() {
10304
        return _fieldName;
10305
      }
10306
    }
10307
 
10308
    // isset id assignments
10309
 
10310
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
10311
      put(_Fields.AGENT_EMAIL_ID, new FieldMetaData("agentEmailId", TFieldRequirementType.DEFAULT, 
10312
          new FieldValueMetaData(TType.STRING)));
10313
      put(_Fields.PASSWORD, new FieldMetaData("password", TFieldRequirementType.DEFAULT, 
10314
          new FieldValueMetaData(TType.STRING)));
10315
    }});
10316
 
10317
    static {
10318
      FieldMetaData.addStructMetaDataMap(updatePasswordForAgent_args.class, metaDataMap);
10319
    }
10320
 
10321
    public updatePasswordForAgent_args() {
10322
    }
10323
 
10324
    public updatePasswordForAgent_args(
10325
      String agentEmailId,
10326
      String password)
10327
    {
10328
      this();
10329
      this.agentEmailId = agentEmailId;
10330
      this.password = password;
10331
    }
10332
 
10333
    /**
10334
     * Performs a deep copy on <i>other</i>.
10335
     */
10336
    public updatePasswordForAgent_args(updatePasswordForAgent_args other) {
10337
      if (other.isSetAgentEmailId()) {
10338
        this.agentEmailId = other.agentEmailId;
10339
      }
10340
      if (other.isSetPassword()) {
10341
        this.password = other.password;
10342
      }
10343
    }
10344
 
10345
    public updatePasswordForAgent_args deepCopy() {
10346
      return new updatePasswordForAgent_args(this);
10347
    }
10348
 
10349
    @Deprecated
10350
    public updatePasswordForAgent_args clone() {
10351
      return new updatePasswordForAgent_args(this);
10352
    }
10353
 
10354
    public String getAgentEmailId() {
10355
      return this.agentEmailId;
10356
    }
10357
 
10358
    public updatePasswordForAgent_args setAgentEmailId(String agentEmailId) {
10359
      this.agentEmailId = agentEmailId;
10360
      return this;
10361
    }
10362
 
10363
    public void unsetAgentEmailId() {
10364
      this.agentEmailId = null;
10365
    }
10366
 
10367
    /** Returns true if field agentEmailId is set (has been asigned a value) and false otherwise */
10368
    public boolean isSetAgentEmailId() {
10369
      return this.agentEmailId != null;
10370
    }
10371
 
10372
    public void setAgentEmailIdIsSet(boolean value) {
10373
      if (!value) {
10374
        this.agentEmailId = null;
10375
      }
10376
    }
10377
 
10378
    public String getPassword() {
10379
      return this.password;
10380
    }
10381
 
10382
    public updatePasswordForAgent_args setPassword(String password) {
10383
      this.password = password;
10384
      return this;
10385
    }
10386
 
10387
    public void unsetPassword() {
10388
      this.password = null;
10389
    }
10390
 
10391
    /** Returns true if field password is set (has been asigned a value) and false otherwise */
10392
    public boolean isSetPassword() {
10393
      return this.password != null;
10394
    }
10395
 
10396
    public void setPasswordIsSet(boolean value) {
10397
      if (!value) {
10398
        this.password = null;
10399
      }
10400
    }
10401
 
10402
    public void setFieldValue(_Fields field, Object value) {
10403
      switch (field) {
10404
      case AGENT_EMAIL_ID:
10405
        if (value == null) {
10406
          unsetAgentEmailId();
10407
        } else {
10408
          setAgentEmailId((String)value);
10409
        }
10410
        break;
10411
 
10412
      case PASSWORD:
10413
        if (value == null) {
10414
          unsetPassword();
10415
        } else {
10416
          setPassword((String)value);
10417
        }
10418
        break;
10419
 
10420
      }
10421
    }
10422
 
10423
    public void setFieldValue(int fieldID, Object value) {
10424
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
10425
    }
10426
 
10427
    public Object getFieldValue(_Fields field) {
10428
      switch (field) {
10429
      case AGENT_EMAIL_ID:
10430
        return getAgentEmailId();
10431
 
10432
      case PASSWORD:
10433
        return getPassword();
10434
 
10435
      }
10436
      throw new IllegalStateException();
10437
    }
10438
 
10439
    public Object getFieldValue(int fieldId) {
10440
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
10441
    }
10442
 
10443
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
10444
    public boolean isSet(_Fields field) {
10445
      switch (field) {
10446
      case AGENT_EMAIL_ID:
10447
        return isSetAgentEmailId();
10448
      case PASSWORD:
10449
        return isSetPassword();
10450
      }
10451
      throw new IllegalStateException();
10452
    }
10453
 
10454
    public boolean isSet(int fieldID) {
10455
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
10456
    }
10457
 
10458
    @Override
10459
    public boolean equals(Object that) {
10460
      if (that == null)
10461
        return false;
10462
      if (that instanceof updatePasswordForAgent_args)
10463
        return this.equals((updatePasswordForAgent_args)that);
10464
      return false;
10465
    }
10466
 
10467
    public boolean equals(updatePasswordForAgent_args that) {
10468
      if (that == null)
10469
        return false;
10470
 
10471
      boolean this_present_agentEmailId = true && this.isSetAgentEmailId();
10472
      boolean that_present_agentEmailId = true && that.isSetAgentEmailId();
10473
      if (this_present_agentEmailId || that_present_agentEmailId) {
10474
        if (!(this_present_agentEmailId && that_present_agentEmailId))
10475
          return false;
10476
        if (!this.agentEmailId.equals(that.agentEmailId))
10477
          return false;
10478
      }
10479
 
10480
      boolean this_present_password = true && this.isSetPassword();
10481
      boolean that_present_password = true && that.isSetPassword();
10482
      if (this_present_password || that_present_password) {
10483
        if (!(this_present_password && that_present_password))
10484
          return false;
10485
        if (!this.password.equals(that.password))
10486
          return false;
10487
      }
10488
 
10489
      return true;
10490
    }
10491
 
10492
    @Override
10493
    public int hashCode() {
10494
      return 0;
10495
    }
10496
 
10497
    public int compareTo(updatePasswordForAgent_args other) {
10498
      if (!getClass().equals(other.getClass())) {
10499
        return getClass().getName().compareTo(other.getClass().getName());
10500
      }
10501
 
10502
      int lastComparison = 0;
10503
      updatePasswordForAgent_args typedOther = (updatePasswordForAgent_args)other;
10504
 
10505
      lastComparison = Boolean.valueOf(isSetAgentEmailId()).compareTo(isSetAgentEmailId());
10506
      if (lastComparison != 0) {
10507
        return lastComparison;
10508
      }
10509
      lastComparison = TBaseHelper.compareTo(agentEmailId, typedOther.agentEmailId);
10510
      if (lastComparison != 0) {
10511
        return lastComparison;
10512
      }
10513
      lastComparison = Boolean.valueOf(isSetPassword()).compareTo(isSetPassword());
10514
      if (lastComparison != 0) {
10515
        return lastComparison;
10516
      }
10517
      lastComparison = TBaseHelper.compareTo(password, typedOther.password);
10518
      if (lastComparison != 0) {
10519
        return lastComparison;
10520
      }
10521
      return 0;
10522
    }
10523
 
10524
    public void read(TProtocol iprot) throws TException {
10525
      TField field;
10526
      iprot.readStructBegin();
10527
      while (true)
10528
      {
10529
        field = iprot.readFieldBegin();
10530
        if (field.type == TType.STOP) { 
10531
          break;
10532
        }
10533
        _Fields fieldId = _Fields.findByThriftId(field.id);
10534
        if (fieldId == null) {
10535
          TProtocolUtil.skip(iprot, field.type);
10536
        } else {
10537
          switch (fieldId) {
10538
            case AGENT_EMAIL_ID:
10539
              if (field.type == TType.STRING) {
10540
                this.agentEmailId = iprot.readString();
10541
              } else { 
10542
                TProtocolUtil.skip(iprot, field.type);
10543
              }
10544
              break;
10545
            case PASSWORD:
10546
              if (field.type == TType.STRING) {
10547
                this.password = iprot.readString();
10548
              } else { 
10549
                TProtocolUtil.skip(iprot, field.type);
10550
              }
10551
              break;
10552
          }
10553
          iprot.readFieldEnd();
10554
        }
10555
      }
10556
      iprot.readStructEnd();
10557
      validate();
10558
    }
10559
 
10560
    public void write(TProtocol oprot) throws TException {
10561
      validate();
10562
 
10563
      oprot.writeStructBegin(STRUCT_DESC);
10564
      if (this.agentEmailId != null) {
10565
        oprot.writeFieldBegin(AGENT_EMAIL_ID_FIELD_DESC);
10566
        oprot.writeString(this.agentEmailId);
10567
        oprot.writeFieldEnd();
10568
      }
10569
      if (this.password != null) {
10570
        oprot.writeFieldBegin(PASSWORD_FIELD_DESC);
10571
        oprot.writeString(this.password);
10572
        oprot.writeFieldEnd();
10573
      }
10574
      oprot.writeFieldStop();
10575
      oprot.writeStructEnd();
10576
    }
10577
 
10578
    @Override
10579
    public String toString() {
10580
      StringBuilder sb = new StringBuilder("updatePasswordForAgent_args(");
10581
      boolean first = true;
10582
 
10583
      sb.append("agentEmailId:");
10584
      if (this.agentEmailId == null) {
10585
        sb.append("null");
10586
      } else {
10587
        sb.append(this.agentEmailId);
10588
      }
10589
      first = false;
10590
      if (!first) sb.append(", ");
10591
      sb.append("password:");
10592
      if (this.password == null) {
10593
        sb.append("null");
10594
      } else {
10595
        sb.append(this.password);
10596
      }
10597
      first = false;
10598
      sb.append(")");
10599
      return sb.toString();
10600
    }
10601
 
10602
    public void validate() throws TException {
10603
      // check for required fields
10604
    }
10605
 
10606
  }
10607
 
10608
  public static class updatePasswordForAgent_result implements TBase<updatePasswordForAgent_result._Fields>, java.io.Serializable, Cloneable, Comparable<updatePasswordForAgent_result>   {
10609
    private static final TStruct STRUCT_DESC = new TStruct("updatePasswordForAgent_result");
10610
 
10611
 
10612
 
10613
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
10614
    public enum _Fields implements TFieldIdEnum {
10615
;
10616
 
10617
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
10618
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
10619
 
10620
      static {
10621
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
10622
          byId.put((int)field._thriftId, field);
10623
          byName.put(field.getFieldName(), field);
10624
        }
10625
      }
10626
 
10627
      /**
10628
       * Find the _Fields constant that matches fieldId, or null if its not found.
10629
       */
10630
      public static _Fields findByThriftId(int fieldId) {
10631
        return byId.get(fieldId);
10632
      }
10633
 
10634
      /**
10635
       * Find the _Fields constant that matches fieldId, throwing an exception
10636
       * if it is not found.
10637
       */
10638
      public static _Fields findByThriftIdOrThrow(int fieldId) {
10639
        _Fields fields = findByThriftId(fieldId);
10640
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
10641
        return fields;
10642
      }
10643
 
10644
      /**
10645
       * Find the _Fields constant that matches name, or null if its not found.
10646
       */
10647
      public static _Fields findByName(String name) {
10648
        return byName.get(name);
10649
      }
10650
 
10651
      private final short _thriftId;
10652
      private final String _fieldName;
10653
 
10654
      _Fields(short thriftId, String fieldName) {
10655
        _thriftId = thriftId;
10656
        _fieldName = fieldName;
10657
      }
10658
 
10659
      public short getThriftFieldId() {
10660
        return _thriftId;
10661
      }
10662
 
10663
      public String getFieldName() {
10664
        return _fieldName;
10665
      }
10666
    }
10667
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
10668
    }});
10669
 
10670
    static {
10671
      FieldMetaData.addStructMetaDataMap(updatePasswordForAgent_result.class, metaDataMap);
10672
    }
10673
 
10674
    public updatePasswordForAgent_result() {
10675
    }
10676
 
10677
    /**
10678
     * Performs a deep copy on <i>other</i>.
10679
     */
10680
    public updatePasswordForAgent_result(updatePasswordForAgent_result other) {
10681
    }
10682
 
10683
    public updatePasswordForAgent_result deepCopy() {
10684
      return new updatePasswordForAgent_result(this);
10685
    }
10686
 
10687
    @Deprecated
10688
    public updatePasswordForAgent_result clone() {
10689
      return new updatePasswordForAgent_result(this);
10690
    }
10691
 
10692
    public void setFieldValue(_Fields field, Object value) {
10693
      switch (field) {
10694
      }
10695
    }
10696
 
10697
    public void setFieldValue(int fieldID, Object value) {
10698
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
10699
    }
10700
 
10701
    public Object getFieldValue(_Fields field) {
10702
      switch (field) {
10703
      }
10704
      throw new IllegalStateException();
10705
    }
10706
 
10707
    public Object getFieldValue(int fieldId) {
10708
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
10709
    }
10710
 
10711
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
10712
    public boolean isSet(_Fields field) {
10713
      switch (field) {
10714
      }
10715
      throw new IllegalStateException();
10716
    }
10717
 
10718
    public boolean isSet(int fieldID) {
10719
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
10720
    }
10721
 
10722
    @Override
10723
    public boolean equals(Object that) {
10724
      if (that == null)
10725
        return false;
10726
      if (that instanceof updatePasswordForAgent_result)
10727
        return this.equals((updatePasswordForAgent_result)that);
10728
      return false;
10729
    }
10730
 
10731
    public boolean equals(updatePasswordForAgent_result that) {
10732
      if (that == null)
10733
        return false;
10734
 
10735
      return true;
10736
    }
10737
 
10738
    @Override
10739
    public int hashCode() {
10740
      return 0;
10741
    }
10742
 
10743
    public int compareTo(updatePasswordForAgent_result other) {
10744
      if (!getClass().equals(other.getClass())) {
10745
        return getClass().getName().compareTo(other.getClass().getName());
10746
      }
10747
 
10748
      int lastComparison = 0;
10749
      updatePasswordForAgent_result typedOther = (updatePasswordForAgent_result)other;
10750
 
10751
      return 0;
10752
    }
10753
 
10754
    public void read(TProtocol iprot) throws TException {
10755
      TField field;
10756
      iprot.readStructBegin();
10757
      while (true)
10758
      {
10759
        field = iprot.readFieldBegin();
10760
        if (field.type == TType.STOP) { 
10761
          break;
10762
        }
10763
        _Fields fieldId = _Fields.findByThriftId(field.id);
10764
        if (fieldId == null) {
10765
          TProtocolUtil.skip(iprot, field.type);
10766
        } else {
10767
          switch (fieldId) {
10768
          }
10769
          iprot.readFieldEnd();
10770
        }
10771
      }
10772
      iprot.readStructEnd();
10773
      validate();
10774
    }
10775
 
10776
    public void write(TProtocol oprot) throws TException {
10777
      oprot.writeStructBegin(STRUCT_DESC);
10778
 
10779
      oprot.writeFieldStop();
10780
      oprot.writeStructEnd();
10781
    }
10782
 
10783
    @Override
10784
    public String toString() {
10785
      StringBuilder sb = new StringBuilder("updatePasswordForAgent_result(");
10786
      boolean first = true;
10787
 
10788
      sb.append(")");
10789
      return sb.toString();
10790
    }
10791
 
10792
    public void validate() throws TException {
10793
      // check for required fields
10794
    }
10795
 
10796
  }
10797
 
10798
  public static class getRoleNamesForAgent_args implements TBase<getRoleNamesForAgent_args._Fields>, java.io.Serializable, Cloneable, Comparable<getRoleNamesForAgent_args>   {
10799
    private static final TStruct STRUCT_DESC = new TStruct("getRoleNamesForAgent_args");
10800
 
10801
    private static final TField AGENT_EMAIL_ID_FIELD_DESC = new TField("agentEmailId", TType.STRING, (short)1);
10802
 
10803
    private String agentEmailId;
10804
 
10805
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
10806
    public enum _Fields implements TFieldIdEnum {
10807
      AGENT_EMAIL_ID((short)1, "agentEmailId");
10808
 
10809
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
10810
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
10811
 
10812
      static {
10813
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
10814
          byId.put((int)field._thriftId, field);
10815
          byName.put(field.getFieldName(), field);
10816
        }
10817
      }
10818
 
10819
      /**
10820
       * Find the _Fields constant that matches fieldId, or null if its not found.
10821
       */
10822
      public static _Fields findByThriftId(int fieldId) {
10823
        return byId.get(fieldId);
10824
      }
10825
 
10826
      /**
10827
       * Find the _Fields constant that matches fieldId, throwing an exception
10828
       * if it is not found.
10829
       */
10830
      public static _Fields findByThriftIdOrThrow(int fieldId) {
10831
        _Fields fields = findByThriftId(fieldId);
10832
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
10833
        return fields;
10834
      }
10835
 
10836
      /**
10837
       * Find the _Fields constant that matches name, or null if its not found.
10838
       */
10839
      public static _Fields findByName(String name) {
10840
        return byName.get(name);
10841
      }
10842
 
10843
      private final short _thriftId;
10844
      private final String _fieldName;
10845
 
10846
      _Fields(short thriftId, String fieldName) {
10847
        _thriftId = thriftId;
10848
        _fieldName = fieldName;
10849
      }
10850
 
10851
      public short getThriftFieldId() {
10852
        return _thriftId;
10853
      }
10854
 
10855
      public String getFieldName() {
10856
        return _fieldName;
10857
      }
10858
    }
10859
 
10860
    // isset id assignments
10861
 
10862
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
10863
      put(_Fields.AGENT_EMAIL_ID, new FieldMetaData("agentEmailId", TFieldRequirementType.DEFAULT, 
10864
          new FieldValueMetaData(TType.STRING)));
10865
    }});
10866
 
10867
    static {
10868
      FieldMetaData.addStructMetaDataMap(getRoleNamesForAgent_args.class, metaDataMap);
10869
    }
10870
 
10871
    public getRoleNamesForAgent_args() {
10872
    }
10873
 
10874
    public getRoleNamesForAgent_args(
10875
      String agentEmailId)
10876
    {
10877
      this();
10878
      this.agentEmailId = agentEmailId;
10879
    }
10880
 
10881
    /**
10882
     * Performs a deep copy on <i>other</i>.
10883
     */
10884
    public getRoleNamesForAgent_args(getRoleNamesForAgent_args other) {
10885
      if (other.isSetAgentEmailId()) {
10886
        this.agentEmailId = other.agentEmailId;
10887
      }
10888
    }
10889
 
10890
    public getRoleNamesForAgent_args deepCopy() {
10891
      return new getRoleNamesForAgent_args(this);
10892
    }
10893
 
10894
    @Deprecated
10895
    public getRoleNamesForAgent_args clone() {
10896
      return new getRoleNamesForAgent_args(this);
10897
    }
10898
 
10899
    public String getAgentEmailId() {
10900
      return this.agentEmailId;
10901
    }
10902
 
10903
    public getRoleNamesForAgent_args setAgentEmailId(String agentEmailId) {
10904
      this.agentEmailId = agentEmailId;
10905
      return this;
10906
    }
10907
 
10908
    public void unsetAgentEmailId() {
10909
      this.agentEmailId = null;
10910
    }
10911
 
10912
    /** Returns true if field agentEmailId is set (has been asigned a value) and false otherwise */
10913
    public boolean isSetAgentEmailId() {
10914
      return this.agentEmailId != null;
10915
    }
10916
 
10917
    public void setAgentEmailIdIsSet(boolean value) {
10918
      if (!value) {
10919
        this.agentEmailId = null;
10920
      }
10921
    }
10922
 
10923
    public void setFieldValue(_Fields field, Object value) {
10924
      switch (field) {
10925
      case AGENT_EMAIL_ID:
10926
        if (value == null) {
10927
          unsetAgentEmailId();
10928
        } else {
10929
          setAgentEmailId((String)value);
10930
        }
10931
        break;
10932
 
10933
      }
10934
    }
10935
 
10936
    public void setFieldValue(int fieldID, Object value) {
10937
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
10938
    }
10939
 
10940
    public Object getFieldValue(_Fields field) {
10941
      switch (field) {
10942
      case AGENT_EMAIL_ID:
10943
        return getAgentEmailId();
10944
 
10945
      }
10946
      throw new IllegalStateException();
10947
    }
10948
 
10949
    public Object getFieldValue(int fieldId) {
10950
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
10951
    }
10952
 
10953
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
10954
    public boolean isSet(_Fields field) {
10955
      switch (field) {
10956
      case AGENT_EMAIL_ID:
10957
        return isSetAgentEmailId();
10958
      }
10959
      throw new IllegalStateException();
10960
    }
10961
 
10962
    public boolean isSet(int fieldID) {
10963
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
10964
    }
10965
 
10966
    @Override
10967
    public boolean equals(Object that) {
10968
      if (that == null)
10969
        return false;
10970
      if (that instanceof getRoleNamesForAgent_args)
10971
        return this.equals((getRoleNamesForAgent_args)that);
10972
      return false;
10973
    }
10974
 
10975
    public boolean equals(getRoleNamesForAgent_args that) {
10976
      if (that == null)
10977
        return false;
10978
 
10979
      boolean this_present_agentEmailId = true && this.isSetAgentEmailId();
10980
      boolean that_present_agentEmailId = true && that.isSetAgentEmailId();
10981
      if (this_present_agentEmailId || that_present_agentEmailId) {
10982
        if (!(this_present_agentEmailId && that_present_agentEmailId))
10983
          return false;
10984
        if (!this.agentEmailId.equals(that.agentEmailId))
10985
          return false;
10986
      }
10987
 
10988
      return true;
10989
    }
10990
 
10991
    @Override
10992
    public int hashCode() {
10993
      return 0;
10994
    }
10995
 
10996
    public int compareTo(getRoleNamesForAgent_args other) {
10997
      if (!getClass().equals(other.getClass())) {
10998
        return getClass().getName().compareTo(other.getClass().getName());
10999
      }
11000
 
11001
      int lastComparison = 0;
11002
      getRoleNamesForAgent_args typedOther = (getRoleNamesForAgent_args)other;
11003
 
11004
      lastComparison = Boolean.valueOf(isSetAgentEmailId()).compareTo(isSetAgentEmailId());
11005
      if (lastComparison != 0) {
11006
        return lastComparison;
11007
      }
11008
      lastComparison = TBaseHelper.compareTo(agentEmailId, typedOther.agentEmailId);
11009
      if (lastComparison != 0) {
11010
        return lastComparison;
11011
      }
11012
      return 0;
11013
    }
11014
 
11015
    public void read(TProtocol iprot) throws TException {
11016
      TField field;
11017
      iprot.readStructBegin();
11018
      while (true)
11019
      {
11020
        field = iprot.readFieldBegin();
11021
        if (field.type == TType.STOP) { 
11022
          break;
11023
        }
11024
        _Fields fieldId = _Fields.findByThriftId(field.id);
11025
        if (fieldId == null) {
11026
          TProtocolUtil.skip(iprot, field.type);
11027
        } else {
11028
          switch (fieldId) {
11029
            case AGENT_EMAIL_ID:
11030
              if (field.type == TType.STRING) {
11031
                this.agentEmailId = iprot.readString();
11032
              } else { 
11033
                TProtocolUtil.skip(iprot, field.type);
11034
              }
11035
              break;
11036
          }
11037
          iprot.readFieldEnd();
11038
        }
11039
      }
11040
      iprot.readStructEnd();
11041
      validate();
11042
    }
11043
 
11044
    public void write(TProtocol oprot) throws TException {
11045
      validate();
11046
 
11047
      oprot.writeStructBegin(STRUCT_DESC);
11048
      if (this.agentEmailId != null) {
11049
        oprot.writeFieldBegin(AGENT_EMAIL_ID_FIELD_DESC);
11050
        oprot.writeString(this.agentEmailId);
11051
        oprot.writeFieldEnd();
11052
      }
11053
      oprot.writeFieldStop();
11054
      oprot.writeStructEnd();
11055
    }
11056
 
11057
    @Override
11058
    public String toString() {
11059
      StringBuilder sb = new StringBuilder("getRoleNamesForAgent_args(");
11060
      boolean first = true;
11061
 
11062
      sb.append("agentEmailId:");
11063
      if (this.agentEmailId == null) {
11064
        sb.append("null");
11065
      } else {
11066
        sb.append(this.agentEmailId);
11067
      }
11068
      first = false;
11069
      sb.append(")");
11070
      return sb.toString();
11071
    }
11072
 
11073
    public void validate() throws TException {
11074
      // check for required fields
11075
    }
11076
 
11077
  }
11078
 
11079
  public static class getRoleNamesForAgent_result implements TBase<getRoleNamesForAgent_result._Fields>, java.io.Serializable, Cloneable, Comparable<getRoleNamesForAgent_result>   {
11080
    private static final TStruct STRUCT_DESC = new TStruct("getRoleNamesForAgent_result");
11081
 
11082
    private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.LIST, (short)0);
11083
 
11084
    private List<String> success;
11085
 
11086
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
11087
    public enum _Fields implements TFieldIdEnum {
11088
      SUCCESS((short)0, "success");
11089
 
11090
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
11091
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11092
 
11093
      static {
11094
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11095
          byId.put((int)field._thriftId, field);
11096
          byName.put(field.getFieldName(), field);
11097
        }
11098
      }
11099
 
11100
      /**
11101
       * Find the _Fields constant that matches fieldId, or null if its not found.
11102
       */
11103
      public static _Fields findByThriftId(int fieldId) {
11104
        return byId.get(fieldId);
11105
      }
11106
 
11107
      /**
11108
       * Find the _Fields constant that matches fieldId, throwing an exception
11109
       * if it is not found.
11110
       */
11111
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11112
        _Fields fields = findByThriftId(fieldId);
11113
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11114
        return fields;
11115
      }
11116
 
11117
      /**
11118
       * Find the _Fields constant that matches name, or null if its not found.
11119
       */
11120
      public static _Fields findByName(String name) {
11121
        return byName.get(name);
11122
      }
11123
 
11124
      private final short _thriftId;
11125
      private final String _fieldName;
11126
 
11127
      _Fields(short thriftId, String fieldName) {
11128
        _thriftId = thriftId;
11129
        _fieldName = fieldName;
11130
      }
11131
 
11132
      public short getThriftFieldId() {
11133
        return _thriftId;
11134
      }
11135
 
11136
      public String getFieldName() {
11137
        return _fieldName;
11138
      }
11139
    }
11140
 
11141
    // isset id assignments
11142
 
11143
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
11144
      put(_Fields.SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, 
11145
          new ListMetaData(TType.LIST, 
11146
              new FieldValueMetaData(TType.STRING))));
11147
    }});
11148
 
11149
    static {
11150
      FieldMetaData.addStructMetaDataMap(getRoleNamesForAgent_result.class, metaDataMap);
11151
    }
11152
 
11153
    public getRoleNamesForAgent_result() {
11154
    }
11155
 
11156
    public getRoleNamesForAgent_result(
11157
      List<String> success)
11158
    {
11159
      this();
11160
      this.success = success;
11161
    }
11162
 
11163
    /**
11164
     * Performs a deep copy on <i>other</i>.
11165
     */
11166
    public getRoleNamesForAgent_result(getRoleNamesForAgent_result other) {
11167
      if (other.isSetSuccess()) {
11168
        List<String> __this__success = new ArrayList<String>();
11169
        for (String other_element : other.success) {
11170
          __this__success.add(other_element);
11171
        }
11172
        this.success = __this__success;
11173
      }
11174
    }
11175
 
11176
    public getRoleNamesForAgent_result deepCopy() {
11177
      return new getRoleNamesForAgent_result(this);
11178
    }
11179
 
11180
    @Deprecated
11181
    public getRoleNamesForAgent_result clone() {
11182
      return new getRoleNamesForAgent_result(this);
11183
    }
11184
 
11185
    public int getSuccessSize() {
11186
      return (this.success == null) ? 0 : this.success.size();
11187
    }
11188
 
11189
    public java.util.Iterator<String> getSuccessIterator() {
11190
      return (this.success == null) ? null : this.success.iterator();
11191
    }
11192
 
11193
    public void addToSuccess(String elem) {
11194
      if (this.success == null) {
11195
        this.success = new ArrayList<String>();
11196
      }
11197
      this.success.add(elem);
11198
    }
11199
 
11200
    public List<String> getSuccess() {
11201
      return this.success;
11202
    }
11203
 
11204
    public getRoleNamesForAgent_result setSuccess(List<String> success) {
11205
      this.success = success;
11206
      return this;
11207
    }
11208
 
11209
    public void unsetSuccess() {
11210
      this.success = null;
11211
    }
11212
 
11213
    /** Returns true if field success is set (has been asigned a value) and false otherwise */
11214
    public boolean isSetSuccess() {
11215
      return this.success != null;
11216
    }
11217
 
11218
    public void setSuccessIsSet(boolean value) {
11219
      if (!value) {
11220
        this.success = null;
11221
      }
11222
    }
11223
 
11224
    public void setFieldValue(_Fields field, Object value) {
11225
      switch (field) {
11226
      case SUCCESS:
11227
        if (value == null) {
11228
          unsetSuccess();
11229
        } else {
11230
          setSuccess((List<String>)value);
11231
        }
11232
        break;
11233
 
11234
      }
11235
    }
11236
 
11237
    public void setFieldValue(int fieldID, Object value) {
11238
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
11239
    }
11240
 
11241
    public Object getFieldValue(_Fields field) {
11242
      switch (field) {
11243
      case SUCCESS:
11244
        return getSuccess();
11245
 
11246
      }
11247
      throw new IllegalStateException();
11248
    }
11249
 
11250
    public Object getFieldValue(int fieldId) {
11251
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
11252
    }
11253
 
11254
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
11255
    public boolean isSet(_Fields field) {
11256
      switch (field) {
11257
      case SUCCESS:
11258
        return isSetSuccess();
11259
      }
11260
      throw new IllegalStateException();
11261
    }
11262
 
11263
    public boolean isSet(int fieldID) {
11264
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
11265
    }
11266
 
11267
    @Override
11268
    public boolean equals(Object that) {
11269
      if (that == null)
11270
        return false;
11271
      if (that instanceof getRoleNamesForAgent_result)
11272
        return this.equals((getRoleNamesForAgent_result)that);
11273
      return false;
11274
    }
11275
 
11276
    public boolean equals(getRoleNamesForAgent_result that) {
11277
      if (that == null)
11278
        return false;
11279
 
11280
      boolean this_present_success = true && this.isSetSuccess();
11281
      boolean that_present_success = true && that.isSetSuccess();
11282
      if (this_present_success || that_present_success) {
11283
        if (!(this_present_success && that_present_success))
11284
          return false;
11285
        if (!this.success.equals(that.success))
11286
          return false;
11287
      }
11288
 
11289
      return true;
11290
    }
11291
 
11292
    @Override
11293
    public int hashCode() {
11294
      return 0;
11295
    }
11296
 
11297
    public int compareTo(getRoleNamesForAgent_result other) {
11298
      if (!getClass().equals(other.getClass())) {
11299
        return getClass().getName().compareTo(other.getClass().getName());
11300
      }
11301
 
11302
      int lastComparison = 0;
11303
      getRoleNamesForAgent_result typedOther = (getRoleNamesForAgent_result)other;
11304
 
11305
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(isSetSuccess());
11306
      if (lastComparison != 0) {
11307
        return lastComparison;
11308
      }
11309
      lastComparison = TBaseHelper.compareTo(success, typedOther.success);
11310
      if (lastComparison != 0) {
11311
        return lastComparison;
11312
      }
11313
      return 0;
11314
    }
11315
 
11316
    public void read(TProtocol iprot) throws TException {
11317
      TField field;
11318
      iprot.readStructBegin();
11319
      while (true)
11320
      {
11321
        field = iprot.readFieldBegin();
11322
        if (field.type == TType.STOP) { 
11323
          break;
11324
        }
11325
        _Fields fieldId = _Fields.findByThriftId(field.id);
11326
        if (fieldId == null) {
11327
          TProtocolUtil.skip(iprot, field.type);
11328
        } else {
11329
          switch (fieldId) {
11330
            case SUCCESS:
11331
              if (field.type == TType.LIST) {
11332
                {
3339 mandeep.dh 11333
                  TList _list32 = iprot.readListBegin();
11334
                  this.success = new ArrayList<String>(_list32.size);
11335
                  for (int _i33 = 0; _i33 < _list32.size; ++_i33)
3087 mandeep.dh 11336
                  {
3339 mandeep.dh 11337
                    String _elem34;
11338
                    _elem34 = iprot.readString();
11339
                    this.success.add(_elem34);
3087 mandeep.dh 11340
                  }
11341
                  iprot.readListEnd();
11342
                }
11343
              } else { 
11344
                TProtocolUtil.skip(iprot, field.type);
11345
              }
11346
              break;
11347
          }
11348
          iprot.readFieldEnd();
11349
        }
11350
      }
11351
      iprot.readStructEnd();
11352
      validate();
11353
    }
11354
 
11355
    public void write(TProtocol oprot) throws TException {
11356
      oprot.writeStructBegin(STRUCT_DESC);
11357
 
11358
      if (this.isSetSuccess()) {
11359
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
11360
        {
11361
          oprot.writeListBegin(new TList(TType.STRING, this.success.size()));
3339 mandeep.dh 11362
          for (String _iter35 : this.success)
3087 mandeep.dh 11363
          {
3339 mandeep.dh 11364
            oprot.writeString(_iter35);
3087 mandeep.dh 11365
          }
11366
          oprot.writeListEnd();
11367
        }
11368
        oprot.writeFieldEnd();
11369
      }
11370
      oprot.writeFieldStop();
11371
      oprot.writeStructEnd();
11372
    }
11373
 
11374
    @Override
11375
    public String toString() {
11376
      StringBuilder sb = new StringBuilder("getRoleNamesForAgent_result(");
11377
      boolean first = true;
11378
 
11379
      sb.append("success:");
11380
      if (this.success == null) {
11381
        sb.append("null");
11382
      } else {
11383
        sb.append(this.success);
11384
      }
11385
      first = false;
11386
      sb.append(")");
11387
      return sb.toString();
11388
    }
11389
 
11390
    public void validate() throws TException {
11391
      // check for required fields
11392
    }
11393
 
11394
  }
11395
 
11396
  public static class getPermissionsForRoleName_args implements TBase<getPermissionsForRoleName_args._Fields>, java.io.Serializable, Cloneable, Comparable<getPermissionsForRoleName_args>   {
11397
    private static final TStruct STRUCT_DESC = new TStruct("getPermissionsForRoleName_args");
11398
 
11399
    private static final TField ROLE_NAME_FIELD_DESC = new TField("roleName", TType.STRING, (short)1);
11400
 
11401
    private String roleName;
11402
 
11403
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
11404
    public enum _Fields implements TFieldIdEnum {
11405
      ROLE_NAME((short)1, "roleName");
11406
 
11407
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
11408
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11409
 
11410
      static {
11411
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11412
          byId.put((int)field._thriftId, field);
11413
          byName.put(field.getFieldName(), field);
11414
        }
11415
      }
11416
 
11417
      /**
11418
       * Find the _Fields constant that matches fieldId, or null if its not found.
11419
       */
11420
      public static _Fields findByThriftId(int fieldId) {
11421
        return byId.get(fieldId);
11422
      }
11423
 
11424
      /**
11425
       * Find the _Fields constant that matches fieldId, throwing an exception
11426
       * if it is not found.
11427
       */
11428
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11429
        _Fields fields = findByThriftId(fieldId);
11430
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11431
        return fields;
11432
      }
11433
 
11434
      /**
11435
       * Find the _Fields constant that matches name, or null if its not found.
11436
       */
11437
      public static _Fields findByName(String name) {
11438
        return byName.get(name);
11439
      }
11440
 
11441
      private final short _thriftId;
11442
      private final String _fieldName;
11443
 
11444
      _Fields(short thriftId, String fieldName) {
11445
        _thriftId = thriftId;
11446
        _fieldName = fieldName;
11447
      }
11448
 
11449
      public short getThriftFieldId() {
11450
        return _thriftId;
11451
      }
11452
 
11453
      public String getFieldName() {
11454
        return _fieldName;
11455
      }
11456
    }
11457
 
11458
    // isset id assignments
11459
 
11460
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
11461
      put(_Fields.ROLE_NAME, new FieldMetaData("roleName", TFieldRequirementType.DEFAULT, 
11462
          new FieldValueMetaData(TType.STRING)));
11463
    }});
11464
 
11465
    static {
11466
      FieldMetaData.addStructMetaDataMap(getPermissionsForRoleName_args.class, metaDataMap);
11467
    }
11468
 
11469
    public getPermissionsForRoleName_args() {
11470
    }
11471
 
11472
    public getPermissionsForRoleName_args(
11473
      String roleName)
11474
    {
11475
      this();
11476
      this.roleName = roleName;
11477
    }
11478
 
11479
    /**
11480
     * Performs a deep copy on <i>other</i>.
11481
     */
11482
    public getPermissionsForRoleName_args(getPermissionsForRoleName_args other) {
11483
      if (other.isSetRoleName()) {
11484
        this.roleName = other.roleName;
11485
      }
11486
    }
11487
 
11488
    public getPermissionsForRoleName_args deepCopy() {
11489
      return new getPermissionsForRoleName_args(this);
11490
    }
11491
 
11492
    @Deprecated
11493
    public getPermissionsForRoleName_args clone() {
11494
      return new getPermissionsForRoleName_args(this);
11495
    }
11496
 
11497
    public String getRoleName() {
11498
      return this.roleName;
11499
    }
11500
 
11501
    public getPermissionsForRoleName_args setRoleName(String roleName) {
11502
      this.roleName = roleName;
11503
      return this;
11504
    }
11505
 
11506
    public void unsetRoleName() {
11507
      this.roleName = null;
11508
    }
11509
 
11510
    /** Returns true if field roleName is set (has been asigned a value) and false otherwise */
11511
    public boolean isSetRoleName() {
11512
      return this.roleName != null;
11513
    }
11514
 
11515
    public void setRoleNameIsSet(boolean value) {
11516
      if (!value) {
11517
        this.roleName = null;
11518
      }
11519
    }
11520
 
11521
    public void setFieldValue(_Fields field, Object value) {
11522
      switch (field) {
11523
      case ROLE_NAME:
11524
        if (value == null) {
11525
          unsetRoleName();
11526
        } else {
11527
          setRoleName((String)value);
11528
        }
11529
        break;
11530
 
11531
      }
11532
    }
11533
 
11534
    public void setFieldValue(int fieldID, Object value) {
11535
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
11536
    }
11537
 
11538
    public Object getFieldValue(_Fields field) {
11539
      switch (field) {
11540
      case ROLE_NAME:
11541
        return getRoleName();
11542
 
11543
      }
11544
      throw new IllegalStateException();
11545
    }
11546
 
11547
    public Object getFieldValue(int fieldId) {
11548
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
11549
    }
11550
 
11551
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
11552
    public boolean isSet(_Fields field) {
11553
      switch (field) {
11554
      case ROLE_NAME:
11555
        return isSetRoleName();
11556
      }
11557
      throw new IllegalStateException();
11558
    }
11559
 
11560
    public boolean isSet(int fieldID) {
11561
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
11562
    }
11563
 
11564
    @Override
11565
    public boolean equals(Object that) {
11566
      if (that == null)
11567
        return false;
11568
      if (that instanceof getPermissionsForRoleName_args)
11569
        return this.equals((getPermissionsForRoleName_args)that);
11570
      return false;
11571
    }
11572
 
11573
    public boolean equals(getPermissionsForRoleName_args that) {
11574
      if (that == null)
11575
        return false;
11576
 
11577
      boolean this_present_roleName = true && this.isSetRoleName();
11578
      boolean that_present_roleName = true && that.isSetRoleName();
11579
      if (this_present_roleName || that_present_roleName) {
11580
        if (!(this_present_roleName && that_present_roleName))
11581
          return false;
11582
        if (!this.roleName.equals(that.roleName))
11583
          return false;
11584
      }
11585
 
11586
      return true;
11587
    }
11588
 
11589
    @Override
11590
    public int hashCode() {
11591
      return 0;
11592
    }
11593
 
11594
    public int compareTo(getPermissionsForRoleName_args other) {
11595
      if (!getClass().equals(other.getClass())) {
11596
        return getClass().getName().compareTo(other.getClass().getName());
11597
      }
11598
 
11599
      int lastComparison = 0;
11600
      getPermissionsForRoleName_args typedOther = (getPermissionsForRoleName_args)other;
11601
 
11602
      lastComparison = Boolean.valueOf(isSetRoleName()).compareTo(isSetRoleName());
11603
      if (lastComparison != 0) {
11604
        return lastComparison;
11605
      }
11606
      lastComparison = TBaseHelper.compareTo(roleName, typedOther.roleName);
11607
      if (lastComparison != 0) {
11608
        return lastComparison;
11609
      }
11610
      return 0;
11611
    }
11612
 
11613
    public void read(TProtocol iprot) throws TException {
11614
      TField field;
11615
      iprot.readStructBegin();
11616
      while (true)
11617
      {
11618
        field = iprot.readFieldBegin();
11619
        if (field.type == TType.STOP) { 
11620
          break;
11621
        }
11622
        _Fields fieldId = _Fields.findByThriftId(field.id);
11623
        if (fieldId == null) {
11624
          TProtocolUtil.skip(iprot, field.type);
11625
        } else {
11626
          switch (fieldId) {
11627
            case ROLE_NAME:
11628
              if (field.type == TType.STRING) {
11629
                this.roleName = iprot.readString();
11630
              } else { 
11631
                TProtocolUtil.skip(iprot, field.type);
11632
              }
11633
              break;
11634
          }
11635
          iprot.readFieldEnd();
11636
        }
11637
      }
11638
      iprot.readStructEnd();
11639
      validate();
11640
    }
11641
 
11642
    public void write(TProtocol oprot) throws TException {
11643
      validate();
11644
 
11645
      oprot.writeStructBegin(STRUCT_DESC);
11646
      if (this.roleName != null) {
11647
        oprot.writeFieldBegin(ROLE_NAME_FIELD_DESC);
11648
        oprot.writeString(this.roleName);
11649
        oprot.writeFieldEnd();
11650
      }
11651
      oprot.writeFieldStop();
11652
      oprot.writeStructEnd();
11653
    }
11654
 
11655
    @Override
11656
    public String toString() {
11657
      StringBuilder sb = new StringBuilder("getPermissionsForRoleName_args(");
11658
      boolean first = true;
11659
 
11660
      sb.append("roleName:");
11661
      if (this.roleName == null) {
11662
        sb.append("null");
11663
      } else {
11664
        sb.append(this.roleName);
11665
      }
11666
      first = false;
11667
      sb.append(")");
11668
      return sb.toString();
11669
    }
11670
 
11671
    public void validate() throws TException {
11672
      // check for required fields
11673
    }
11674
 
11675
  }
11676
 
11677
  public static class getPermissionsForRoleName_result implements TBase<getPermissionsForRoleName_result._Fields>, java.io.Serializable, Cloneable, Comparable<getPermissionsForRoleName_result>   {
11678
    private static final TStruct STRUCT_DESC = new TStruct("getPermissionsForRoleName_result");
11679
 
11680
    private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.LIST, (short)0);
11681
 
11682
    private List<String> success;
11683
 
11684
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
11685
    public enum _Fields implements TFieldIdEnum {
11686
      SUCCESS((short)0, "success");
11687
 
11688
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
11689
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11690
 
11691
      static {
11692
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11693
          byId.put((int)field._thriftId, field);
11694
          byName.put(field.getFieldName(), field);
11695
        }
11696
      }
11697
 
11698
      /**
11699
       * Find the _Fields constant that matches fieldId, or null if its not found.
11700
       */
11701
      public static _Fields findByThriftId(int fieldId) {
11702
        return byId.get(fieldId);
11703
      }
11704
 
11705
      /**
11706
       * Find the _Fields constant that matches fieldId, throwing an exception
11707
       * if it is not found.
11708
       */
11709
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11710
        _Fields fields = findByThriftId(fieldId);
11711
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11712
        return fields;
11713
      }
11714
 
11715
      /**
11716
       * Find the _Fields constant that matches name, or null if its not found.
11717
       */
11718
      public static _Fields findByName(String name) {
11719
        return byName.get(name);
11720
      }
11721
 
11722
      private final short _thriftId;
11723
      private final String _fieldName;
11724
 
11725
      _Fields(short thriftId, String fieldName) {
11726
        _thriftId = thriftId;
11727
        _fieldName = fieldName;
11728
      }
11729
 
11730
      public short getThriftFieldId() {
11731
        return _thriftId;
11732
      }
11733
 
11734
      public String getFieldName() {
11735
        return _fieldName;
11736
      }
11737
    }
11738
 
11739
    // isset id assignments
11740
 
11741
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
11742
      put(_Fields.SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, 
11743
          new ListMetaData(TType.LIST, 
11744
              new FieldValueMetaData(TType.STRING))));
11745
    }});
11746
 
11747
    static {
11748
      FieldMetaData.addStructMetaDataMap(getPermissionsForRoleName_result.class, metaDataMap);
11749
    }
11750
 
11751
    public getPermissionsForRoleName_result() {
11752
    }
11753
 
11754
    public getPermissionsForRoleName_result(
11755
      List<String> success)
11756
    {
11757
      this();
11758
      this.success = success;
11759
    }
11760
 
11761
    /**
11762
     * Performs a deep copy on <i>other</i>.
11763
     */
11764
    public getPermissionsForRoleName_result(getPermissionsForRoleName_result other) {
11765
      if (other.isSetSuccess()) {
11766
        List<String> __this__success = new ArrayList<String>();
11767
        for (String other_element : other.success) {
11768
          __this__success.add(other_element);
11769
        }
11770
        this.success = __this__success;
11771
      }
11772
    }
11773
 
11774
    public getPermissionsForRoleName_result deepCopy() {
11775
      return new getPermissionsForRoleName_result(this);
11776
    }
11777
 
11778
    @Deprecated
11779
    public getPermissionsForRoleName_result clone() {
11780
      return new getPermissionsForRoleName_result(this);
11781
    }
11782
 
11783
    public int getSuccessSize() {
11784
      return (this.success == null) ? 0 : this.success.size();
11785
    }
11786
 
11787
    public java.util.Iterator<String> getSuccessIterator() {
11788
      return (this.success == null) ? null : this.success.iterator();
11789
    }
11790
 
11791
    public void addToSuccess(String elem) {
11792
      if (this.success == null) {
11793
        this.success = new ArrayList<String>();
11794
      }
11795
      this.success.add(elem);
11796
    }
11797
 
11798
    public List<String> getSuccess() {
11799
      return this.success;
11800
    }
11801
 
11802
    public getPermissionsForRoleName_result setSuccess(List<String> success) {
11803
      this.success = success;
11804
      return this;
11805
    }
11806
 
11807
    public void unsetSuccess() {
11808
      this.success = null;
11809
    }
11810
 
11811
    /** Returns true if field success is set (has been asigned a value) and false otherwise */
11812
    public boolean isSetSuccess() {
11813
      return this.success != null;
11814
    }
11815
 
11816
    public void setSuccessIsSet(boolean value) {
11817
      if (!value) {
11818
        this.success = null;
11819
      }
11820
    }
11821
 
11822
    public void setFieldValue(_Fields field, Object value) {
11823
      switch (field) {
11824
      case SUCCESS:
11825
        if (value == null) {
11826
          unsetSuccess();
11827
        } else {
11828
          setSuccess((List<String>)value);
11829
        }
11830
        break;
11831
 
11832
      }
11833
    }
11834
 
11835
    public void setFieldValue(int fieldID, Object value) {
11836
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
11837
    }
11838
 
11839
    public Object getFieldValue(_Fields field) {
11840
      switch (field) {
11841
      case SUCCESS:
11842
        return getSuccess();
11843
 
11844
      }
11845
      throw new IllegalStateException();
11846
    }
11847
 
11848
    public Object getFieldValue(int fieldId) {
11849
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
11850
    }
11851
 
11852
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
11853
    public boolean isSet(_Fields field) {
11854
      switch (field) {
11855
      case SUCCESS:
11856
        return isSetSuccess();
11857
      }
11858
      throw new IllegalStateException();
11859
    }
11860
 
11861
    public boolean isSet(int fieldID) {
11862
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
11863
    }
11864
 
11865
    @Override
11866
    public boolean equals(Object that) {
11867
      if (that == null)
11868
        return false;
11869
      if (that instanceof getPermissionsForRoleName_result)
11870
        return this.equals((getPermissionsForRoleName_result)that);
11871
      return false;
11872
    }
11873
 
11874
    public boolean equals(getPermissionsForRoleName_result that) {
11875
      if (that == null)
11876
        return false;
11877
 
11878
      boolean this_present_success = true && this.isSetSuccess();
11879
      boolean that_present_success = true && that.isSetSuccess();
11880
      if (this_present_success || that_present_success) {
11881
        if (!(this_present_success && that_present_success))
11882
          return false;
11883
        if (!this.success.equals(that.success))
11884
          return false;
11885
      }
11886
 
11887
      return true;
11888
    }
11889
 
11890
    @Override
11891
    public int hashCode() {
11892
      return 0;
11893
    }
11894
 
11895
    public int compareTo(getPermissionsForRoleName_result other) {
11896
      if (!getClass().equals(other.getClass())) {
11897
        return getClass().getName().compareTo(other.getClass().getName());
11898
      }
11899
 
11900
      int lastComparison = 0;
11901
      getPermissionsForRoleName_result typedOther = (getPermissionsForRoleName_result)other;
11902
 
11903
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(isSetSuccess());
11904
      if (lastComparison != 0) {
11905
        return lastComparison;
11906
      }
11907
      lastComparison = TBaseHelper.compareTo(success, typedOther.success);
11908
      if (lastComparison != 0) {
11909
        return lastComparison;
11910
      }
11911
      return 0;
11912
    }
11913
 
11914
    public void read(TProtocol iprot) throws TException {
11915
      TField field;
11916
      iprot.readStructBegin();
11917
      while (true)
11918
      {
11919
        field = iprot.readFieldBegin();
11920
        if (field.type == TType.STOP) { 
11921
          break;
11922
        }
11923
        _Fields fieldId = _Fields.findByThriftId(field.id);
11924
        if (fieldId == null) {
11925
          TProtocolUtil.skip(iprot, field.type);
11926
        } else {
11927
          switch (fieldId) {
11928
            case SUCCESS:
11929
              if (field.type == TType.LIST) {
11930
                {
3339 mandeep.dh 11931
                  TList _list36 = iprot.readListBegin();
11932
                  this.success = new ArrayList<String>(_list36.size);
11933
                  for (int _i37 = 0; _i37 < _list36.size; ++_i37)
3087 mandeep.dh 11934
                  {
3339 mandeep.dh 11935
                    String _elem38;
11936
                    _elem38 = iprot.readString();
11937
                    this.success.add(_elem38);
3087 mandeep.dh 11938
                  }
11939
                  iprot.readListEnd();
11940
                }
11941
              } else { 
11942
                TProtocolUtil.skip(iprot, field.type);
11943
              }
11944
              break;
11945
          }
11946
          iprot.readFieldEnd();
11947
        }
11948
      }
11949
      iprot.readStructEnd();
11950
      validate();
11951
    }
11952
 
11953
    public void write(TProtocol oprot) throws TException {
11954
      oprot.writeStructBegin(STRUCT_DESC);
11955
 
11956
      if (this.isSetSuccess()) {
11957
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
11958
        {
11959
          oprot.writeListBegin(new TList(TType.STRING, this.success.size()));
3339 mandeep.dh 11960
          for (String _iter39 : this.success)
3087 mandeep.dh 11961
          {
3339 mandeep.dh 11962
            oprot.writeString(_iter39);
3087 mandeep.dh 11963
          }
11964
          oprot.writeListEnd();
11965
        }
11966
        oprot.writeFieldEnd();
11967
      }
11968
      oprot.writeFieldStop();
11969
      oprot.writeStructEnd();
11970
    }
11971
 
11972
    @Override
11973
    public String toString() {
11974
      StringBuilder sb = new StringBuilder("getPermissionsForRoleName_result(");
11975
      boolean first = true;
11976
 
11977
      sb.append("success:");
11978
      if (this.success == null) {
11979
        sb.append("null");
11980
      } else {
11981
        sb.append(this.success);
11982
      }
11983
      first = false;
11984
      sb.append(")");
11985
      return sb.toString();
11986
    }
11987
 
11988
    public void validate() throws TException {
11989
      // check for required fields
11990
    }
11991
 
11992
  }
11993
 
3339 mandeep.dh 11994
  public static class getLastEmailProcessedTimestamp_args implements TBase<getLastEmailProcessedTimestamp_args._Fields>, java.io.Serializable, Cloneable, Comparable<getLastEmailProcessedTimestamp_args>   {
11995
    private static final TStruct STRUCT_DESC = new TStruct("getLastEmailProcessedTimestamp_args");
11996
 
11997
 
11998
 
11999
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
12000
    public enum _Fields implements TFieldIdEnum {
12001
;
12002
 
12003
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
12004
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12005
 
12006
      static {
12007
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12008
          byId.put((int)field._thriftId, field);
12009
          byName.put(field.getFieldName(), field);
12010
        }
12011
      }
12012
 
12013
      /**
12014
       * Find the _Fields constant that matches fieldId, or null if its not found.
12015
       */
12016
      public static _Fields findByThriftId(int fieldId) {
12017
        return byId.get(fieldId);
12018
      }
12019
 
12020
      /**
12021
       * Find the _Fields constant that matches fieldId, throwing an exception
12022
       * if it is not found.
12023
       */
12024
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12025
        _Fields fields = findByThriftId(fieldId);
12026
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12027
        return fields;
12028
      }
12029
 
12030
      /**
12031
       * Find the _Fields constant that matches name, or null if its not found.
12032
       */
12033
      public static _Fields findByName(String name) {
12034
        return byName.get(name);
12035
      }
12036
 
12037
      private final short _thriftId;
12038
      private final String _fieldName;
12039
 
12040
      _Fields(short thriftId, String fieldName) {
12041
        _thriftId = thriftId;
12042
        _fieldName = fieldName;
12043
      }
12044
 
12045
      public short getThriftFieldId() {
12046
        return _thriftId;
12047
      }
12048
 
12049
      public String getFieldName() {
12050
        return _fieldName;
12051
      }
12052
    }
12053
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
12054
    }});
12055
 
12056
    static {
12057
      FieldMetaData.addStructMetaDataMap(getLastEmailProcessedTimestamp_args.class, metaDataMap);
12058
    }
12059
 
12060
    public getLastEmailProcessedTimestamp_args() {
12061
    }
12062
 
12063
    /**
12064
     * Performs a deep copy on <i>other</i>.
12065
     */
12066
    public getLastEmailProcessedTimestamp_args(getLastEmailProcessedTimestamp_args other) {
12067
    }
12068
 
12069
    public getLastEmailProcessedTimestamp_args deepCopy() {
12070
      return new getLastEmailProcessedTimestamp_args(this);
12071
    }
12072
 
12073
    @Deprecated
12074
    public getLastEmailProcessedTimestamp_args clone() {
12075
      return new getLastEmailProcessedTimestamp_args(this);
12076
    }
12077
 
12078
    public void setFieldValue(_Fields field, Object value) {
12079
      switch (field) {
12080
      }
12081
    }
12082
 
12083
    public void setFieldValue(int fieldID, Object value) {
12084
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
12085
    }
12086
 
12087
    public Object getFieldValue(_Fields field) {
12088
      switch (field) {
12089
      }
12090
      throw new IllegalStateException();
12091
    }
12092
 
12093
    public Object getFieldValue(int fieldId) {
12094
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
12095
    }
12096
 
12097
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
12098
    public boolean isSet(_Fields field) {
12099
      switch (field) {
12100
      }
12101
      throw new IllegalStateException();
12102
    }
12103
 
12104
    public boolean isSet(int fieldID) {
12105
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
12106
    }
12107
 
12108
    @Override
12109
    public boolean equals(Object that) {
12110
      if (that == null)
12111
        return false;
12112
      if (that instanceof getLastEmailProcessedTimestamp_args)
12113
        return this.equals((getLastEmailProcessedTimestamp_args)that);
12114
      return false;
12115
    }
12116
 
12117
    public boolean equals(getLastEmailProcessedTimestamp_args that) {
12118
      if (that == null)
12119
        return false;
12120
 
12121
      return true;
12122
    }
12123
 
12124
    @Override
12125
    public int hashCode() {
12126
      return 0;
12127
    }
12128
 
12129
    public int compareTo(getLastEmailProcessedTimestamp_args other) {
12130
      if (!getClass().equals(other.getClass())) {
12131
        return getClass().getName().compareTo(other.getClass().getName());
12132
      }
12133
 
12134
      int lastComparison = 0;
12135
      getLastEmailProcessedTimestamp_args typedOther = (getLastEmailProcessedTimestamp_args)other;
12136
 
12137
      return 0;
12138
    }
12139
 
12140
    public void read(TProtocol iprot) throws TException {
12141
      TField field;
12142
      iprot.readStructBegin();
12143
      while (true)
12144
      {
12145
        field = iprot.readFieldBegin();
12146
        if (field.type == TType.STOP) { 
12147
          break;
12148
        }
12149
        _Fields fieldId = _Fields.findByThriftId(field.id);
12150
        if (fieldId == null) {
12151
          TProtocolUtil.skip(iprot, field.type);
12152
        } else {
12153
          switch (fieldId) {
12154
          }
12155
          iprot.readFieldEnd();
12156
        }
12157
      }
12158
      iprot.readStructEnd();
12159
      validate();
12160
    }
12161
 
12162
    public void write(TProtocol oprot) throws TException {
12163
      validate();
12164
 
12165
      oprot.writeStructBegin(STRUCT_DESC);
12166
      oprot.writeFieldStop();
12167
      oprot.writeStructEnd();
12168
    }
12169
 
12170
    @Override
12171
    public String toString() {
12172
      StringBuilder sb = new StringBuilder("getLastEmailProcessedTimestamp_args(");
12173
      boolean first = true;
12174
 
12175
      sb.append(")");
12176
      return sb.toString();
12177
    }
12178
 
12179
    public void validate() throws TException {
12180
      // check for required fields
12181
    }
12182
 
12183
  }
12184
 
12185
  public static class getLastEmailProcessedTimestamp_result implements TBase<getLastEmailProcessedTimestamp_result._Fields>, java.io.Serializable, Cloneable, Comparable<getLastEmailProcessedTimestamp_result>   {
12186
    private static final TStruct STRUCT_DESC = new TStruct("getLastEmailProcessedTimestamp_result");
12187
 
12188
    private static final TField SUCCESS_FIELD_DESC = new TField("success", TType.I64, (short)0);
12189
 
12190
    private long success;
12191
 
12192
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
12193
    public enum _Fields implements TFieldIdEnum {
12194
      SUCCESS((short)0, "success");
12195
 
12196
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
12197
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12198
 
12199
      static {
12200
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12201
          byId.put((int)field._thriftId, field);
12202
          byName.put(field.getFieldName(), field);
12203
        }
12204
      }
12205
 
12206
      /**
12207
       * Find the _Fields constant that matches fieldId, or null if its not found.
12208
       */
12209
      public static _Fields findByThriftId(int fieldId) {
12210
        return byId.get(fieldId);
12211
      }
12212
 
12213
      /**
12214
       * Find the _Fields constant that matches fieldId, throwing an exception
12215
       * if it is not found.
12216
       */
12217
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12218
        _Fields fields = findByThriftId(fieldId);
12219
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12220
        return fields;
12221
      }
12222
 
12223
      /**
12224
       * Find the _Fields constant that matches name, or null if its not found.
12225
       */
12226
      public static _Fields findByName(String name) {
12227
        return byName.get(name);
12228
      }
12229
 
12230
      private final short _thriftId;
12231
      private final String _fieldName;
12232
 
12233
      _Fields(short thriftId, String fieldName) {
12234
        _thriftId = thriftId;
12235
        _fieldName = fieldName;
12236
      }
12237
 
12238
      public short getThriftFieldId() {
12239
        return _thriftId;
12240
      }
12241
 
12242
      public String getFieldName() {
12243
        return _fieldName;
12244
      }
12245
    }
12246
 
12247
    // isset id assignments
12248
    private static final int __SUCCESS_ISSET_ID = 0;
12249
    private BitSet __isset_bit_vector = new BitSet(1);
12250
 
12251
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
12252
      put(_Fields.SUCCESS, new FieldMetaData("success", TFieldRequirementType.DEFAULT, 
12253
          new FieldValueMetaData(TType.I64)));
12254
    }});
12255
 
12256
    static {
12257
      FieldMetaData.addStructMetaDataMap(getLastEmailProcessedTimestamp_result.class, metaDataMap);
12258
    }
12259
 
12260
    public getLastEmailProcessedTimestamp_result() {
12261
    }
12262
 
12263
    public getLastEmailProcessedTimestamp_result(
12264
      long success)
12265
    {
12266
      this();
12267
      this.success = success;
12268
      setSuccessIsSet(true);
12269
    }
12270
 
12271
    /**
12272
     * Performs a deep copy on <i>other</i>.
12273
     */
12274
    public getLastEmailProcessedTimestamp_result(getLastEmailProcessedTimestamp_result other) {
12275
      __isset_bit_vector.clear();
12276
      __isset_bit_vector.or(other.__isset_bit_vector);
12277
      this.success = other.success;
12278
    }
12279
 
12280
    public getLastEmailProcessedTimestamp_result deepCopy() {
12281
      return new getLastEmailProcessedTimestamp_result(this);
12282
    }
12283
 
12284
    @Deprecated
12285
    public getLastEmailProcessedTimestamp_result clone() {
12286
      return new getLastEmailProcessedTimestamp_result(this);
12287
    }
12288
 
12289
    public long getSuccess() {
12290
      return this.success;
12291
    }
12292
 
12293
    public getLastEmailProcessedTimestamp_result setSuccess(long success) {
12294
      this.success = success;
12295
      setSuccessIsSet(true);
12296
      return this;
12297
    }
12298
 
12299
    public void unsetSuccess() {
12300
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
12301
    }
12302
 
12303
    /** Returns true if field success is set (has been asigned a value) and false otherwise */
12304
    public boolean isSetSuccess() {
12305
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
12306
    }
12307
 
12308
    public void setSuccessIsSet(boolean value) {
12309
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
12310
    }
12311
 
12312
    public void setFieldValue(_Fields field, Object value) {
12313
      switch (field) {
12314
      case SUCCESS:
12315
        if (value == null) {
12316
          unsetSuccess();
12317
        } else {
12318
          setSuccess((Long)value);
12319
        }
12320
        break;
12321
 
12322
      }
12323
    }
12324
 
12325
    public void setFieldValue(int fieldID, Object value) {
12326
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
12327
    }
12328
 
12329
    public Object getFieldValue(_Fields field) {
12330
      switch (field) {
12331
      case SUCCESS:
12332
        return new Long(getSuccess());
12333
 
12334
      }
12335
      throw new IllegalStateException();
12336
    }
12337
 
12338
    public Object getFieldValue(int fieldId) {
12339
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
12340
    }
12341
 
12342
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
12343
    public boolean isSet(_Fields field) {
12344
      switch (field) {
12345
      case SUCCESS:
12346
        return isSetSuccess();
12347
      }
12348
      throw new IllegalStateException();
12349
    }
12350
 
12351
    public boolean isSet(int fieldID) {
12352
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
12353
    }
12354
 
12355
    @Override
12356
    public boolean equals(Object that) {
12357
      if (that == null)
12358
        return false;
12359
      if (that instanceof getLastEmailProcessedTimestamp_result)
12360
        return this.equals((getLastEmailProcessedTimestamp_result)that);
12361
      return false;
12362
    }
12363
 
12364
    public boolean equals(getLastEmailProcessedTimestamp_result that) {
12365
      if (that == null)
12366
        return false;
12367
 
12368
      boolean this_present_success = true;
12369
      boolean that_present_success = true;
12370
      if (this_present_success || that_present_success) {
12371
        if (!(this_present_success && that_present_success))
12372
          return false;
12373
        if (this.success != that.success)
12374
          return false;
12375
      }
12376
 
12377
      return true;
12378
    }
12379
 
12380
    @Override
12381
    public int hashCode() {
12382
      return 0;
12383
    }
12384
 
12385
    public int compareTo(getLastEmailProcessedTimestamp_result other) {
12386
      if (!getClass().equals(other.getClass())) {
12387
        return getClass().getName().compareTo(other.getClass().getName());
12388
      }
12389
 
12390
      int lastComparison = 0;
12391
      getLastEmailProcessedTimestamp_result typedOther = (getLastEmailProcessedTimestamp_result)other;
12392
 
12393
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(isSetSuccess());
12394
      if (lastComparison != 0) {
12395
        return lastComparison;
12396
      }
12397
      lastComparison = TBaseHelper.compareTo(success, typedOther.success);
12398
      if (lastComparison != 0) {
12399
        return lastComparison;
12400
      }
12401
      return 0;
12402
    }
12403
 
12404
    public void read(TProtocol iprot) throws TException {
12405
      TField field;
12406
      iprot.readStructBegin();
12407
      while (true)
12408
      {
12409
        field = iprot.readFieldBegin();
12410
        if (field.type == TType.STOP) { 
12411
          break;
12412
        }
12413
        _Fields fieldId = _Fields.findByThriftId(field.id);
12414
        if (fieldId == null) {
12415
          TProtocolUtil.skip(iprot, field.type);
12416
        } else {
12417
          switch (fieldId) {
12418
            case SUCCESS:
12419
              if (field.type == TType.I64) {
12420
                this.success = iprot.readI64();
12421
                setSuccessIsSet(true);
12422
              } else { 
12423
                TProtocolUtil.skip(iprot, field.type);
12424
              }
12425
              break;
12426
          }
12427
          iprot.readFieldEnd();
12428
        }
12429
      }
12430
      iprot.readStructEnd();
12431
      validate();
12432
    }
12433
 
12434
    public void write(TProtocol oprot) throws TException {
12435
      oprot.writeStructBegin(STRUCT_DESC);
12436
 
12437
      if (this.isSetSuccess()) {
12438
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
12439
        oprot.writeI64(this.success);
12440
        oprot.writeFieldEnd();
12441
      }
12442
      oprot.writeFieldStop();
12443
      oprot.writeStructEnd();
12444
    }
12445
 
12446
    @Override
12447
    public String toString() {
12448
      StringBuilder sb = new StringBuilder("getLastEmailProcessedTimestamp_result(");
12449
      boolean first = true;
12450
 
12451
      sb.append("success:");
12452
      sb.append(this.success);
12453
      first = false;
12454
      sb.append(")");
12455
      return sb.toString();
12456
    }
12457
 
12458
    public void validate() throws TException {
12459
      // check for required fields
12460
    }
12461
 
12462
  }
12463
 
12464
  public static class updateLastEmailProcessedTimestamp_args implements TBase<updateLastEmailProcessedTimestamp_args._Fields>, java.io.Serializable, Cloneable, Comparable<updateLastEmailProcessedTimestamp_args>   {
12465
    private static final TStruct STRUCT_DESC = new TStruct("updateLastEmailProcessedTimestamp_args");
12466
 
12467
    private static final TField TIMESTAMP_FIELD_DESC = new TField("timestamp", TType.I64, (short)1);
12468
 
12469
    private long timestamp;
12470
 
12471
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
12472
    public enum _Fields implements TFieldIdEnum {
12473
      TIMESTAMP((short)1, "timestamp");
12474
 
12475
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
12476
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12477
 
12478
      static {
12479
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12480
          byId.put((int)field._thriftId, field);
12481
          byName.put(field.getFieldName(), field);
12482
        }
12483
      }
12484
 
12485
      /**
12486
       * Find the _Fields constant that matches fieldId, or null if its not found.
12487
       */
12488
      public static _Fields findByThriftId(int fieldId) {
12489
        return byId.get(fieldId);
12490
      }
12491
 
12492
      /**
12493
       * Find the _Fields constant that matches fieldId, throwing an exception
12494
       * if it is not found.
12495
       */
12496
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12497
        _Fields fields = findByThriftId(fieldId);
12498
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12499
        return fields;
12500
      }
12501
 
12502
      /**
12503
       * Find the _Fields constant that matches name, or null if its not found.
12504
       */
12505
      public static _Fields findByName(String name) {
12506
        return byName.get(name);
12507
      }
12508
 
12509
      private final short _thriftId;
12510
      private final String _fieldName;
12511
 
12512
      _Fields(short thriftId, String fieldName) {
12513
        _thriftId = thriftId;
12514
        _fieldName = fieldName;
12515
      }
12516
 
12517
      public short getThriftFieldId() {
12518
        return _thriftId;
12519
      }
12520
 
12521
      public String getFieldName() {
12522
        return _fieldName;
12523
      }
12524
    }
12525
 
12526
    // isset id assignments
12527
    private static final int __TIMESTAMP_ISSET_ID = 0;
12528
    private BitSet __isset_bit_vector = new BitSet(1);
12529
 
12530
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
12531
      put(_Fields.TIMESTAMP, new FieldMetaData("timestamp", TFieldRequirementType.DEFAULT, 
12532
          new FieldValueMetaData(TType.I64)));
12533
    }});
12534
 
12535
    static {
12536
      FieldMetaData.addStructMetaDataMap(updateLastEmailProcessedTimestamp_args.class, metaDataMap);
12537
    }
12538
 
12539
    public updateLastEmailProcessedTimestamp_args() {
12540
    }
12541
 
12542
    public updateLastEmailProcessedTimestamp_args(
12543
      long timestamp)
12544
    {
12545
      this();
12546
      this.timestamp = timestamp;
12547
      setTimestampIsSet(true);
12548
    }
12549
 
12550
    /**
12551
     * Performs a deep copy on <i>other</i>.
12552
     */
12553
    public updateLastEmailProcessedTimestamp_args(updateLastEmailProcessedTimestamp_args other) {
12554
      __isset_bit_vector.clear();
12555
      __isset_bit_vector.or(other.__isset_bit_vector);
12556
      this.timestamp = other.timestamp;
12557
    }
12558
 
12559
    public updateLastEmailProcessedTimestamp_args deepCopy() {
12560
      return new updateLastEmailProcessedTimestamp_args(this);
12561
    }
12562
 
12563
    @Deprecated
12564
    public updateLastEmailProcessedTimestamp_args clone() {
12565
      return new updateLastEmailProcessedTimestamp_args(this);
12566
    }
12567
 
12568
    public long getTimestamp() {
12569
      return this.timestamp;
12570
    }
12571
 
12572
    public updateLastEmailProcessedTimestamp_args setTimestamp(long timestamp) {
12573
      this.timestamp = timestamp;
12574
      setTimestampIsSet(true);
12575
      return this;
12576
    }
12577
 
12578
    public void unsetTimestamp() {
12579
      __isset_bit_vector.clear(__TIMESTAMP_ISSET_ID);
12580
    }
12581
 
12582
    /** Returns true if field timestamp is set (has been asigned a value) and false otherwise */
12583
    public boolean isSetTimestamp() {
12584
      return __isset_bit_vector.get(__TIMESTAMP_ISSET_ID);
12585
    }
12586
 
12587
    public void setTimestampIsSet(boolean value) {
12588
      __isset_bit_vector.set(__TIMESTAMP_ISSET_ID, value);
12589
    }
12590
 
12591
    public void setFieldValue(_Fields field, Object value) {
12592
      switch (field) {
12593
      case TIMESTAMP:
12594
        if (value == null) {
12595
          unsetTimestamp();
12596
        } else {
12597
          setTimestamp((Long)value);
12598
        }
12599
        break;
12600
 
12601
      }
12602
    }
12603
 
12604
    public void setFieldValue(int fieldID, Object value) {
12605
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
12606
    }
12607
 
12608
    public Object getFieldValue(_Fields field) {
12609
      switch (field) {
12610
      case TIMESTAMP:
12611
        return new Long(getTimestamp());
12612
 
12613
      }
12614
      throw new IllegalStateException();
12615
    }
12616
 
12617
    public Object getFieldValue(int fieldId) {
12618
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
12619
    }
12620
 
12621
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
12622
    public boolean isSet(_Fields field) {
12623
      switch (field) {
12624
      case TIMESTAMP:
12625
        return isSetTimestamp();
12626
      }
12627
      throw new IllegalStateException();
12628
    }
12629
 
12630
    public boolean isSet(int fieldID) {
12631
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
12632
    }
12633
 
12634
    @Override
12635
    public boolean equals(Object that) {
12636
      if (that == null)
12637
        return false;
12638
      if (that instanceof updateLastEmailProcessedTimestamp_args)
12639
        return this.equals((updateLastEmailProcessedTimestamp_args)that);
12640
      return false;
12641
    }
12642
 
12643
    public boolean equals(updateLastEmailProcessedTimestamp_args that) {
12644
      if (that == null)
12645
        return false;
12646
 
12647
      boolean this_present_timestamp = true;
12648
      boolean that_present_timestamp = true;
12649
      if (this_present_timestamp || that_present_timestamp) {
12650
        if (!(this_present_timestamp && that_present_timestamp))
12651
          return false;
12652
        if (this.timestamp != that.timestamp)
12653
          return false;
12654
      }
12655
 
12656
      return true;
12657
    }
12658
 
12659
    @Override
12660
    public int hashCode() {
12661
      return 0;
12662
    }
12663
 
12664
    public int compareTo(updateLastEmailProcessedTimestamp_args other) {
12665
      if (!getClass().equals(other.getClass())) {
12666
        return getClass().getName().compareTo(other.getClass().getName());
12667
      }
12668
 
12669
      int lastComparison = 0;
12670
      updateLastEmailProcessedTimestamp_args typedOther = (updateLastEmailProcessedTimestamp_args)other;
12671
 
12672
      lastComparison = Boolean.valueOf(isSetTimestamp()).compareTo(isSetTimestamp());
12673
      if (lastComparison != 0) {
12674
        return lastComparison;
12675
      }
12676
      lastComparison = TBaseHelper.compareTo(timestamp, typedOther.timestamp);
12677
      if (lastComparison != 0) {
12678
        return lastComparison;
12679
      }
12680
      return 0;
12681
    }
12682
 
12683
    public void read(TProtocol iprot) throws TException {
12684
      TField field;
12685
      iprot.readStructBegin();
12686
      while (true)
12687
      {
12688
        field = iprot.readFieldBegin();
12689
        if (field.type == TType.STOP) { 
12690
          break;
12691
        }
12692
        _Fields fieldId = _Fields.findByThriftId(field.id);
12693
        if (fieldId == null) {
12694
          TProtocolUtil.skip(iprot, field.type);
12695
        } else {
12696
          switch (fieldId) {
12697
            case TIMESTAMP:
12698
              if (field.type == TType.I64) {
12699
                this.timestamp = iprot.readI64();
12700
                setTimestampIsSet(true);
12701
              } else { 
12702
                TProtocolUtil.skip(iprot, field.type);
12703
              }
12704
              break;
12705
          }
12706
          iprot.readFieldEnd();
12707
        }
12708
      }
12709
      iprot.readStructEnd();
12710
      validate();
12711
    }
12712
 
12713
    public void write(TProtocol oprot) throws TException {
12714
      validate();
12715
 
12716
      oprot.writeStructBegin(STRUCT_DESC);
12717
      oprot.writeFieldBegin(TIMESTAMP_FIELD_DESC);
12718
      oprot.writeI64(this.timestamp);
12719
      oprot.writeFieldEnd();
12720
      oprot.writeFieldStop();
12721
      oprot.writeStructEnd();
12722
    }
12723
 
12724
    @Override
12725
    public String toString() {
12726
      StringBuilder sb = new StringBuilder("updateLastEmailProcessedTimestamp_args(");
12727
      boolean first = true;
12728
 
12729
      sb.append("timestamp:");
12730
      sb.append(this.timestamp);
12731
      first = false;
12732
      sb.append(")");
12733
      return sb.toString();
12734
    }
12735
 
12736
    public void validate() throws TException {
12737
      // check for required fields
12738
    }
12739
 
12740
  }
12741
 
12742
  public static class updateLastEmailProcessedTimestamp_result implements TBase<updateLastEmailProcessedTimestamp_result._Fields>, java.io.Serializable, Cloneable, Comparable<updateLastEmailProcessedTimestamp_result>   {
12743
    private static final TStruct STRUCT_DESC = new TStruct("updateLastEmailProcessedTimestamp_result");
12744
 
12745
 
12746
 
12747
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
12748
    public enum _Fields implements TFieldIdEnum {
12749
;
12750
 
12751
      private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
12752
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12753
 
12754
      static {
12755
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12756
          byId.put((int)field._thriftId, field);
12757
          byName.put(field.getFieldName(), field);
12758
        }
12759
      }
12760
 
12761
      /**
12762
       * Find the _Fields constant that matches fieldId, or null if its not found.
12763
       */
12764
      public static _Fields findByThriftId(int fieldId) {
12765
        return byId.get(fieldId);
12766
      }
12767
 
12768
      /**
12769
       * Find the _Fields constant that matches fieldId, throwing an exception
12770
       * if it is not found.
12771
       */
12772
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12773
        _Fields fields = findByThriftId(fieldId);
12774
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12775
        return fields;
12776
      }
12777
 
12778
      /**
12779
       * Find the _Fields constant that matches name, or null if its not found.
12780
       */
12781
      public static _Fields findByName(String name) {
12782
        return byName.get(name);
12783
      }
12784
 
12785
      private final short _thriftId;
12786
      private final String _fieldName;
12787
 
12788
      _Fields(short thriftId, String fieldName) {
12789
        _thriftId = thriftId;
12790
        _fieldName = fieldName;
12791
      }
12792
 
12793
      public short getThriftFieldId() {
12794
        return _thriftId;
12795
      }
12796
 
12797
      public String getFieldName() {
12798
        return _fieldName;
12799
      }
12800
    }
12801
    public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
12802
    }});
12803
 
12804
    static {
12805
      FieldMetaData.addStructMetaDataMap(updateLastEmailProcessedTimestamp_result.class, metaDataMap);
12806
    }
12807
 
12808
    public updateLastEmailProcessedTimestamp_result() {
12809
    }
12810
 
12811
    /**
12812
     * Performs a deep copy on <i>other</i>.
12813
     */
12814
    public updateLastEmailProcessedTimestamp_result(updateLastEmailProcessedTimestamp_result other) {
12815
    }
12816
 
12817
    public updateLastEmailProcessedTimestamp_result deepCopy() {
12818
      return new updateLastEmailProcessedTimestamp_result(this);
12819
    }
12820
 
12821
    @Deprecated
12822
    public updateLastEmailProcessedTimestamp_result clone() {
12823
      return new updateLastEmailProcessedTimestamp_result(this);
12824
    }
12825
 
12826
    public void setFieldValue(_Fields field, Object value) {
12827
      switch (field) {
12828
      }
12829
    }
12830
 
12831
    public void setFieldValue(int fieldID, Object value) {
12832
      setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
12833
    }
12834
 
12835
    public Object getFieldValue(_Fields field) {
12836
      switch (field) {
12837
      }
12838
      throw new IllegalStateException();
12839
    }
12840
 
12841
    public Object getFieldValue(int fieldId) {
12842
      return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
12843
    }
12844
 
12845
    /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
12846
    public boolean isSet(_Fields field) {
12847
      switch (field) {
12848
      }
12849
      throw new IllegalStateException();
12850
    }
12851
 
12852
    public boolean isSet(int fieldID) {
12853
      return isSet(_Fields.findByThriftIdOrThrow(fieldID));
12854
    }
12855
 
12856
    @Override
12857
    public boolean equals(Object that) {
12858
      if (that == null)
12859
        return false;
12860
      if (that instanceof updateLastEmailProcessedTimestamp_result)
12861
        return this.equals((updateLastEmailProcessedTimestamp_result)that);
12862
      return false;
12863
    }
12864
 
12865
    public boolean equals(updateLastEmailProcessedTimestamp_result that) {
12866
      if (that == null)
12867
        return false;
12868
 
12869
      return true;
12870
    }
12871
 
12872
    @Override
12873
    public int hashCode() {
12874
      return 0;
12875
    }
12876
 
12877
    public int compareTo(updateLastEmailProcessedTimestamp_result other) {
12878
      if (!getClass().equals(other.getClass())) {
12879
        return getClass().getName().compareTo(other.getClass().getName());
12880
      }
12881
 
12882
      int lastComparison = 0;
12883
      updateLastEmailProcessedTimestamp_result typedOther = (updateLastEmailProcessedTimestamp_result)other;
12884
 
12885
      return 0;
12886
    }
12887
 
12888
    public void read(TProtocol iprot) throws TException {
12889
      TField field;
12890
      iprot.readStructBegin();
12891
      while (true)
12892
      {
12893
        field = iprot.readFieldBegin();
12894
        if (field.type == TType.STOP) { 
12895
          break;
12896
        }
12897
        _Fields fieldId = _Fields.findByThriftId(field.id);
12898
        if (fieldId == null) {
12899
          TProtocolUtil.skip(iprot, field.type);
12900
        } else {
12901
          switch (fieldId) {
12902
          }
12903
          iprot.readFieldEnd();
12904
        }
12905
      }
12906
      iprot.readStructEnd();
12907
      validate();
12908
    }
12909
 
12910
    public void write(TProtocol oprot) throws TException {
12911
      oprot.writeStructBegin(STRUCT_DESC);
12912
 
12913
      oprot.writeFieldStop();
12914
      oprot.writeStructEnd();
12915
    }
12916
 
12917
    @Override
12918
    public String toString() {
12919
      StringBuilder sb = new StringBuilder("updateLastEmailProcessedTimestamp_result(");
12920
      boolean first = true;
12921
 
12922
      sb.append(")");
12923
      return sb.toString();
12924
    }
12925
 
12926
    public void validate() throws TException {
12927
      // check for required fields
12928
    }
12929
 
12930
  }
12931
 
3028 mandeep.dh 12932
}