Subversion Repositories SmartDukaan

Rev

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