Subversion Repositories SmartDukaan

Rev

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

Rev Author Line No. Line
349 ashish 1
#
2
# Autogenerated by Thrift
3
#
4
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
5
#
6
 
7
from thrift.Thrift import *
8
from ttypes import *
9
from thrift.Thrift import TProcessor
10
from thrift.transport import TTransport
11
from thrift.protocol import TBinaryProtocol
12
try:
13
  from thrift.protocol import fastbinary
14
except:
15
  fastbinary = None
16
 
17
 
18
class Iface:
765 rajveer 19
  def closeSession(self, ):
20
    """
21
    For closing the open session in sqlalchemy
22
    """
23
    pass
24
 
1395 varun.gupt 25
  def saveUserEmailForSending(self, emailTo, emailFrom, subject, body, source, emailType):
26
    """
27
    Parameters:
28
     - emailTo
29
     - emailFrom
30
     - subject
31
     - body
32
     - source
33
     - emailType
34
    """
35
    pass
36
 
349 ashish 37
  def sendMail(self, mail):
38
    """
39
    Parameters:
40
     - mail
41
    """
42
    pass
43
 
44
  def sendText(self, message):
45
    """
46
    Parameters:
47
     - message
48
    """
49
    pass
50
 
51
  def addMessage(self, message):
52
    """
53
    Parameters:
54
     - message
55
    """
56
    pass
57
 
58
  def updateMessage(self, id, message):
59
    """
60
    Parameters:
61
     - id
62
     - message
63
    """
64
    pass
65
 
66
  def getMessage(self, id):
67
    """
68
    Parameters:
69
     - id
70
    """
71
    pass
72
 
73
  def getSubstitutedMessage(self, id, params):
74
    """
75
    Parameters:
76
     - id
77
     - params
78
    """
79
    pass
80
 
494 rajveer 81
  def addUser(self, username, password, warehouseId):
82
    """
83
    Parameters:
84
     - username
85
     - password
86
     - warehouseId
87
    """
88
    pass
349 ashish 89
 
494 rajveer 90
  def deleteUser(self, username):
91
    """
92
    Parameters:
93
     - username
94
    """
95
    pass
96
 
97
  def authenticateUser(self, username, password):
98
    """
759 chandransh 99
    Returns the warehouseId for the given user if the password matches. Returns -1 otherwise.
100
    The loggedOn timestamp for the dashboard user is updated as a timestamp.
101
    It's unclear to me when an exception is thrown : Chandranshu
102
 
494 rajveer 103
    Parameters:
104
     - username
105
     - password
106
    """
107
    pass
108
 
109
  def updatePassword(self, username, oldPassword, newPassword):
110
    """
111
    Parameters:
112
     - username
113
     - oldPassword
114
     - newPassword
115
    """
116
    pass
117
 
759 chandransh 118
  def authenticateLogisticsUser(self, username, password):
119
    """
120
    Returns the LogisticsUser struct associated with the given username and password if they match.
121
    Throws an exception otherwise.
122
 
123
    Parameters:
124
     - username
125
     - password
126
    """
127
    pass
494 rajveer 128
 
759 chandransh 129
 
349 ashish 130
class Client(Iface):
131
  def __init__(self, iprot, oprot=None):
132
    self._iprot = self._oprot = iprot
133
    if oprot != None:
134
      self._oprot = oprot
135
    self._seqid = 0
136
 
765 rajveer 137
  def closeSession(self, ):
138
    """
139
    For closing the open session in sqlalchemy
140
    """
141
    self.send_closeSession()
142
    self.recv_closeSession()
143
 
144
  def send_closeSession(self, ):
145
    self._oprot.writeMessageBegin('closeSession', TMessageType.CALL, self._seqid)
146
    args = closeSession_args()
147
    args.write(self._oprot)
148
    self._oprot.writeMessageEnd()
149
    self._oprot.trans.flush()
150
 
151
  def recv_closeSession(self, ):
152
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
153
    if mtype == TMessageType.EXCEPTION:
154
      x = TApplicationException()
155
      x.read(self._iprot)
156
      self._iprot.readMessageEnd()
157
      raise x
158
    result = closeSession_result()
159
    result.read(self._iprot)
160
    self._iprot.readMessageEnd()
161
    return
162
 
1395 varun.gupt 163
  def saveUserEmailForSending(self, emailTo, emailFrom, subject, body, source, emailType):
164
    """
165
    Parameters:
166
     - emailTo
167
     - emailFrom
168
     - subject
169
     - body
170
     - source
171
     - emailType
172
    """
173
    self.send_saveUserEmailForSending(emailTo, emailFrom, subject, body, source, emailType)
174
    self.recv_saveUserEmailForSending()
175
 
176
  def send_saveUserEmailForSending(self, emailTo, emailFrom, subject, body, source, emailType):
177
    self._oprot.writeMessageBegin('saveUserEmailForSending', TMessageType.CALL, self._seqid)
178
    args = saveUserEmailForSending_args()
179
    args.emailTo = emailTo
180
    args.emailFrom = emailFrom
181
    args.subject = subject
182
    args.body = body
183
    args.source = source
184
    args.emailType = emailType
185
    args.write(self._oprot)
186
    self._oprot.writeMessageEnd()
187
    self._oprot.trans.flush()
188
 
189
  def recv_saveUserEmailForSending(self, ):
190
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
191
    if mtype == TMessageType.EXCEPTION:
192
      x = TApplicationException()
193
      x.read(self._iprot)
194
      self._iprot.readMessageEnd()
195
      raise x
196
    result = saveUserEmailForSending_result()
197
    result.read(self._iprot)
198
    self._iprot.readMessageEnd()
199
    if result.se != None:
200
      raise result.se
201
    return
202
 
349 ashish 203
  def sendMail(self, mail):
204
    """
205
    Parameters:
206
     - mail
207
    """
208
    self.send_sendMail(mail)
209
    self.recv_sendMail()
210
 
211
  def send_sendMail(self, mail):
212
    self._oprot.writeMessageBegin('sendMail', TMessageType.CALL, self._seqid)
213
    args = sendMail_args()
214
    args.mail = mail
215
    args.write(self._oprot)
216
    self._oprot.writeMessageEnd()
217
    self._oprot.trans.flush()
218
 
219
  def recv_sendMail(self, ):
220
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
221
    if mtype == TMessageType.EXCEPTION:
222
      x = TApplicationException()
223
      x.read(self._iprot)
224
      self._iprot.readMessageEnd()
225
      raise x
226
    result = sendMail_result()
227
    result.read(self._iprot)
228
    self._iprot.readMessageEnd()
229
    if result.se != None:
230
      raise result.se
231
    return
232
 
233
  def sendText(self, message):
234
    """
235
    Parameters:
236
     - message
237
    """
238
    self.send_sendText(message)
239
    self.recv_sendText()
240
 
241
  def send_sendText(self, message):
242
    self._oprot.writeMessageBegin('sendText', TMessageType.CALL, self._seqid)
243
    args = sendText_args()
244
    args.message = message
245
    args.write(self._oprot)
246
    self._oprot.writeMessageEnd()
247
    self._oprot.trans.flush()
248
 
249
  def recv_sendText(self, ):
250
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
251
    if mtype == TMessageType.EXCEPTION:
252
      x = TApplicationException()
253
      x.read(self._iprot)
254
      self._iprot.readMessageEnd()
255
      raise x
256
    result = sendText_result()
257
    result.read(self._iprot)
258
    self._iprot.readMessageEnd()
259
    if result.se != None:
260
      raise result.se
261
    return
262
 
263
  def addMessage(self, message):
264
    """
265
    Parameters:
266
     - message
267
    """
268
    self.send_addMessage(message)
269
    self.recv_addMessage()
270
 
271
  def send_addMessage(self, message):
272
    self._oprot.writeMessageBegin('addMessage', TMessageType.CALL, self._seqid)
273
    args = addMessage_args()
274
    args.message = message
275
    args.write(self._oprot)
276
    self._oprot.writeMessageEnd()
277
    self._oprot.trans.flush()
278
 
279
  def recv_addMessage(self, ):
280
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
281
    if mtype == TMessageType.EXCEPTION:
282
      x = TApplicationException()
283
      x.read(self._iprot)
284
      self._iprot.readMessageEnd()
285
      raise x
286
    result = addMessage_result()
287
    result.read(self._iprot)
288
    self._iprot.readMessageEnd()
289
    if result.se != None:
290
      raise result.se
291
    return
292
 
293
  def updateMessage(self, id, message):
294
    """
295
    Parameters:
296
     - id
297
     - message
298
    """
299
    self.send_updateMessage(id, message)
300
    self.recv_updateMessage()
301
 
302
  def send_updateMessage(self, id, message):
303
    self._oprot.writeMessageBegin('updateMessage', TMessageType.CALL, self._seqid)
304
    args = updateMessage_args()
305
    args.id = id
306
    args.message = message
307
    args.write(self._oprot)
308
    self._oprot.writeMessageEnd()
309
    self._oprot.trans.flush()
310
 
311
  def recv_updateMessage(self, ):
312
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
313
    if mtype == TMessageType.EXCEPTION:
314
      x = TApplicationException()
315
      x.read(self._iprot)
316
      self._iprot.readMessageEnd()
317
      raise x
318
    result = updateMessage_result()
319
    result.read(self._iprot)
320
    self._iprot.readMessageEnd()
321
    if result.se != None:
322
      raise result.se
323
    return
324
 
325
  def getMessage(self, id):
326
    """
327
    Parameters:
328
     - id
329
    """
330
    self.send_getMessage(id)
353 ashish 331
    return self.recv_getMessage()
349 ashish 332
 
333
  def send_getMessage(self, id):
334
    self._oprot.writeMessageBegin('getMessage', TMessageType.CALL, self._seqid)
335
    args = getMessage_args()
336
    args.id = id
337
    args.write(self._oprot)
338
    self._oprot.writeMessageEnd()
339
    self._oprot.trans.flush()
340
 
341
  def recv_getMessage(self, ):
342
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
343
    if mtype == TMessageType.EXCEPTION:
344
      x = TApplicationException()
345
      x.read(self._iprot)
346
      self._iprot.readMessageEnd()
347
      raise x
348
    result = getMessage_result()
349
    result.read(self._iprot)
350
    self._iprot.readMessageEnd()
353 ashish 351
    if result.success != None:
352
      return result.success
349 ashish 353
    if result.se != None:
354
      raise result.se
353 ashish 355
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getMessage failed: unknown result");
349 ashish 356
 
357
  def getSubstitutedMessage(self, id, params):
358
    """
359
    Parameters:
360
     - id
361
     - params
362
    """
363
    self.send_getSubstitutedMessage(id, params)
353 ashish 364
    return self.recv_getSubstitutedMessage()
349 ashish 365
 
366
  def send_getSubstitutedMessage(self, id, params):
367
    self._oprot.writeMessageBegin('getSubstitutedMessage', TMessageType.CALL, self._seqid)
368
    args = getSubstitutedMessage_args()
369
    args.id = id
370
    args.params = params
371
    args.write(self._oprot)
372
    self._oprot.writeMessageEnd()
373
    self._oprot.trans.flush()
374
 
375
  def recv_getSubstitutedMessage(self, ):
376
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
377
    if mtype == TMessageType.EXCEPTION:
378
      x = TApplicationException()
379
      x.read(self._iprot)
380
      self._iprot.readMessageEnd()
381
      raise x
382
    result = getSubstitutedMessage_result()
383
    result.read(self._iprot)
384
    self._iprot.readMessageEnd()
353 ashish 385
    if result.success != None:
386
      return result.success
349 ashish 387
    if result.se != None:
388
      raise result.se
353 ashish 389
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getSubstitutedMessage failed: unknown result");
349 ashish 390
 
494 rajveer 391
  def addUser(self, username, password, warehouseId):
392
    """
393
    Parameters:
394
     - username
395
     - password
396
     - warehouseId
397
    """
398
    self.send_addUser(username, password, warehouseId)
399
    return self.recv_addUser()
349 ashish 400
 
494 rajveer 401
  def send_addUser(self, username, password, warehouseId):
402
    self._oprot.writeMessageBegin('addUser', TMessageType.CALL, self._seqid)
403
    args = addUser_args()
404
    args.username = username
405
    args.password = password
406
    args.warehouseId = warehouseId
407
    args.write(self._oprot)
408
    self._oprot.writeMessageEnd()
409
    self._oprot.trans.flush()
410
 
411
  def recv_addUser(self, ):
412
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
413
    if mtype == TMessageType.EXCEPTION:
414
      x = TApplicationException()
415
      x.read(self._iprot)
416
      self._iprot.readMessageEnd()
417
      raise x
418
    result = addUser_result()
419
    result.read(self._iprot)
420
    self._iprot.readMessageEnd()
421
    if result.success != None:
422
      return result.success
423
    if result.se != None:
424
      raise result.se
425
    raise TApplicationException(TApplicationException.MISSING_RESULT, "addUser failed: unknown result");
426
 
427
  def deleteUser(self, username):
428
    """
429
    Parameters:
430
     - username
431
    """
432
    self.send_deleteUser(username)
433
    return self.recv_deleteUser()
434
 
435
  def send_deleteUser(self, username):
436
    self._oprot.writeMessageBegin('deleteUser', TMessageType.CALL, self._seqid)
437
    args = deleteUser_args()
438
    args.username = username
439
    args.write(self._oprot)
440
    self._oprot.writeMessageEnd()
441
    self._oprot.trans.flush()
442
 
443
  def recv_deleteUser(self, ):
444
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
445
    if mtype == TMessageType.EXCEPTION:
446
      x = TApplicationException()
447
      x.read(self._iprot)
448
      self._iprot.readMessageEnd()
449
      raise x
450
    result = deleteUser_result()
451
    result.read(self._iprot)
452
    self._iprot.readMessageEnd()
453
    if result.success != None:
454
      return result.success
455
    if result.se != None:
456
      raise result.se
457
    raise TApplicationException(TApplicationException.MISSING_RESULT, "deleteUser failed: unknown result");
458
 
459
  def authenticateUser(self, username, password):
460
    """
759 chandransh 461
    Returns the warehouseId for the given user if the password matches. Returns -1 otherwise.
462
    The loggedOn timestamp for the dashboard user is updated as a timestamp.
463
    It's unclear to me when an exception is thrown : Chandranshu
464
 
494 rajveer 465
    Parameters:
466
     - username
467
     - password
468
    """
469
    self.send_authenticateUser(username, password)
470
    return self.recv_authenticateUser()
471
 
472
  def send_authenticateUser(self, username, password):
473
    self._oprot.writeMessageBegin('authenticateUser', TMessageType.CALL, self._seqid)
474
    args = authenticateUser_args()
475
    args.username = username
476
    args.password = password
477
    args.write(self._oprot)
478
    self._oprot.writeMessageEnd()
479
    self._oprot.trans.flush()
480
 
481
  def recv_authenticateUser(self, ):
482
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
483
    if mtype == TMessageType.EXCEPTION:
484
      x = TApplicationException()
485
      x.read(self._iprot)
486
      self._iprot.readMessageEnd()
487
      raise x
488
    result = authenticateUser_result()
489
    result.read(self._iprot)
490
    self._iprot.readMessageEnd()
491
    if result.success != None:
492
      return result.success
493
    if result.se != None:
494
      raise result.se
495
    raise TApplicationException(TApplicationException.MISSING_RESULT, "authenticateUser failed: unknown result");
496
 
497
  def updatePassword(self, username, oldPassword, newPassword):
498
    """
499
    Parameters:
500
     - username
501
     - oldPassword
502
     - newPassword
503
    """
504
    self.send_updatePassword(username, oldPassword, newPassword)
505
    return self.recv_updatePassword()
506
 
507
  def send_updatePassword(self, username, oldPassword, newPassword):
508
    self._oprot.writeMessageBegin('updatePassword', TMessageType.CALL, self._seqid)
509
    args = updatePassword_args()
510
    args.username = username
511
    args.oldPassword = oldPassword
512
    args.newPassword = newPassword
513
    args.write(self._oprot)
514
    self._oprot.writeMessageEnd()
515
    self._oprot.trans.flush()
516
 
517
  def recv_updatePassword(self, ):
518
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
519
    if mtype == TMessageType.EXCEPTION:
520
      x = TApplicationException()
521
      x.read(self._iprot)
522
      self._iprot.readMessageEnd()
523
      raise x
524
    result = updatePassword_result()
525
    result.read(self._iprot)
526
    self._iprot.readMessageEnd()
527
    if result.success != None:
528
      return result.success
529
    if result.se != None:
530
      raise result.se
531
    raise TApplicationException(TApplicationException.MISSING_RESULT, "updatePassword failed: unknown result");
532
 
759 chandransh 533
  def authenticateLogisticsUser(self, username, password):
534
    """
535
    Returns the LogisticsUser struct associated with the given username and password if they match.
536
    Throws an exception otherwise.
537
 
538
    Parameters:
539
     - username
540
     - password
541
    """
542
    self.send_authenticateLogisticsUser(username, password)
543
    return self.recv_authenticateLogisticsUser()
494 rajveer 544
 
759 chandransh 545
  def send_authenticateLogisticsUser(self, username, password):
546
    self._oprot.writeMessageBegin('authenticateLogisticsUser', TMessageType.CALL, self._seqid)
547
    args = authenticateLogisticsUser_args()
548
    args.username = username
549
    args.password = password
550
    args.write(self._oprot)
551
    self._oprot.writeMessageEnd()
552
    self._oprot.trans.flush()
553
 
554
  def recv_authenticateLogisticsUser(self, ):
555
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
556
    if mtype == TMessageType.EXCEPTION:
557
      x = TApplicationException()
558
      x.read(self._iprot)
559
      self._iprot.readMessageEnd()
560
      raise x
561
    result = authenticateLogisticsUser_result()
562
    result.read(self._iprot)
563
    self._iprot.readMessageEnd()
564
    if result.success != None:
565
      return result.success
566
    if result.hse != None:
567
      raise result.hse
568
    raise TApplicationException(TApplicationException.MISSING_RESULT, "authenticateLogisticsUser failed: unknown result");
569
 
570
 
349 ashish 571
class Processor(Iface, TProcessor):
572
  def __init__(self, handler):
573
    self._handler = handler
574
    self._processMap = {}
765 rajveer 575
    self._processMap["closeSession"] = Processor.process_closeSession
1395 varun.gupt 576
    self._processMap["saveUserEmailForSending"] = Processor.process_saveUserEmailForSending
349 ashish 577
    self._processMap["sendMail"] = Processor.process_sendMail
578
    self._processMap["sendText"] = Processor.process_sendText
579
    self._processMap["addMessage"] = Processor.process_addMessage
580
    self._processMap["updateMessage"] = Processor.process_updateMessage
581
    self._processMap["getMessage"] = Processor.process_getMessage
582
    self._processMap["getSubstitutedMessage"] = Processor.process_getSubstitutedMessage
494 rajveer 583
    self._processMap["addUser"] = Processor.process_addUser
584
    self._processMap["deleteUser"] = Processor.process_deleteUser
585
    self._processMap["authenticateUser"] = Processor.process_authenticateUser
586
    self._processMap["updatePassword"] = Processor.process_updatePassword
759 chandransh 587
    self._processMap["authenticateLogisticsUser"] = Processor.process_authenticateLogisticsUser
349 ashish 588
 
589
  def process(self, iprot, oprot):
590
    (name, type, seqid) = iprot.readMessageBegin()
591
    if name not in self._processMap:
592
      iprot.skip(TType.STRUCT)
593
      iprot.readMessageEnd()
594
      x = TApplicationException(TApplicationException.UNKNOWN_METHOD, 'Unknown function %s' % (name))
595
      oprot.writeMessageBegin(name, TMessageType.EXCEPTION, seqid)
596
      x.write(oprot)
597
      oprot.writeMessageEnd()
598
      oprot.trans.flush()
599
      return
600
    else:
601
      self._processMap[name](self, seqid, iprot, oprot)
602
    return True
603
 
765 rajveer 604
  def process_closeSession(self, seqid, iprot, oprot):
605
    args = closeSession_args()
606
    args.read(iprot)
607
    iprot.readMessageEnd()
608
    result = closeSession_result()
609
    self._handler.closeSession()
610
    oprot.writeMessageBegin("closeSession", TMessageType.REPLY, seqid)
611
    result.write(oprot)
612
    oprot.writeMessageEnd()
613
    oprot.trans.flush()
614
 
1395 varun.gupt 615
  def process_saveUserEmailForSending(self, seqid, iprot, oprot):
616
    args = saveUserEmailForSending_args()
617
    args.read(iprot)
618
    iprot.readMessageEnd()
619
    result = saveUserEmailForSending_result()
620
    try:
621
      self._handler.saveUserEmailForSending(args.emailTo, args.emailFrom, args.subject, args.body, args.source, args.emailType)
622
    except HelperServiceException, se:
623
      result.se = se
624
    oprot.writeMessageBegin("saveUserEmailForSending", TMessageType.REPLY, seqid)
625
    result.write(oprot)
626
    oprot.writeMessageEnd()
627
    oprot.trans.flush()
628
 
349 ashish 629
  def process_sendMail(self, seqid, iprot, oprot):
630
    args = sendMail_args()
631
    args.read(iprot)
632
    iprot.readMessageEnd()
633
    result = sendMail_result()
634
    try:
635
      self._handler.sendMail(args.mail)
636
    except HelperServiceException, se:
637
      result.se = se
638
    oprot.writeMessageBegin("sendMail", TMessageType.REPLY, seqid)
639
    result.write(oprot)
640
    oprot.writeMessageEnd()
641
    oprot.trans.flush()
642
 
643
  def process_sendText(self, seqid, iprot, oprot):
644
    args = sendText_args()
645
    args.read(iprot)
646
    iprot.readMessageEnd()
647
    result = sendText_result()
648
    try:
649
      self._handler.sendText(args.message)
650
    except HelperServiceException, se:
651
      result.se = se
652
    oprot.writeMessageBegin("sendText", TMessageType.REPLY, seqid)
653
    result.write(oprot)
654
    oprot.writeMessageEnd()
655
    oprot.trans.flush()
656
 
657
  def process_addMessage(self, seqid, iprot, oprot):
658
    args = addMessage_args()
659
    args.read(iprot)
660
    iprot.readMessageEnd()
661
    result = addMessage_result()
662
    try:
663
      self._handler.addMessage(args.message)
664
    except HelperServiceException, se:
665
      result.se = se
666
    oprot.writeMessageBegin("addMessage", TMessageType.REPLY, seqid)
667
    result.write(oprot)
668
    oprot.writeMessageEnd()
669
    oprot.trans.flush()
670
 
671
  def process_updateMessage(self, seqid, iprot, oprot):
672
    args = updateMessage_args()
673
    args.read(iprot)
674
    iprot.readMessageEnd()
675
    result = updateMessage_result()
676
    try:
677
      self._handler.updateMessage(args.id, args.message)
678
    except HelperServiceException, se:
679
      result.se = se
680
    oprot.writeMessageBegin("updateMessage", TMessageType.REPLY, seqid)
681
    result.write(oprot)
682
    oprot.writeMessageEnd()
683
    oprot.trans.flush()
684
 
685
  def process_getMessage(self, seqid, iprot, oprot):
686
    args = getMessage_args()
687
    args.read(iprot)
688
    iprot.readMessageEnd()
689
    result = getMessage_result()
690
    try:
353 ashish 691
      result.success = self._handler.getMessage(args.id)
349 ashish 692
    except HelperServiceException, se:
693
      result.se = se
694
    oprot.writeMessageBegin("getMessage", TMessageType.REPLY, seqid)
695
    result.write(oprot)
696
    oprot.writeMessageEnd()
697
    oprot.trans.flush()
698
 
699
  def process_getSubstitutedMessage(self, seqid, iprot, oprot):
700
    args = getSubstitutedMessage_args()
701
    args.read(iprot)
702
    iprot.readMessageEnd()
703
    result = getSubstitutedMessage_result()
704
    try:
353 ashish 705
      result.success = self._handler.getSubstitutedMessage(args.id, args.params)
349 ashish 706
    except HelperServiceException, se:
707
      result.se = se
708
    oprot.writeMessageBegin("getSubstitutedMessage", TMessageType.REPLY, seqid)
709
    result.write(oprot)
710
    oprot.writeMessageEnd()
711
    oprot.trans.flush()
712
 
494 rajveer 713
  def process_addUser(self, seqid, iprot, oprot):
714
    args = addUser_args()
715
    args.read(iprot)
716
    iprot.readMessageEnd()
717
    result = addUser_result()
718
    try:
719
      result.success = self._handler.addUser(args.username, args.password, args.warehouseId)
720
    except HelperServiceException, se:
721
      result.se = se
722
    oprot.writeMessageBegin("addUser", TMessageType.REPLY, seqid)
723
    result.write(oprot)
724
    oprot.writeMessageEnd()
725
    oprot.trans.flush()
349 ashish 726
 
494 rajveer 727
  def process_deleteUser(self, seqid, iprot, oprot):
728
    args = deleteUser_args()
729
    args.read(iprot)
730
    iprot.readMessageEnd()
731
    result = deleteUser_result()
732
    try:
733
      result.success = self._handler.deleteUser(args.username)
734
    except HelperServiceException, se:
735
      result.se = se
736
    oprot.writeMessageBegin("deleteUser", TMessageType.REPLY, seqid)
737
    result.write(oprot)
738
    oprot.writeMessageEnd()
739
    oprot.trans.flush()
740
 
741
  def process_authenticateUser(self, seqid, iprot, oprot):
742
    args = authenticateUser_args()
743
    args.read(iprot)
744
    iprot.readMessageEnd()
745
    result = authenticateUser_result()
746
    try:
747
      result.success = self._handler.authenticateUser(args.username, args.password)
748
    except HelperServiceException, se:
749
      result.se = se
750
    oprot.writeMessageBegin("authenticateUser", TMessageType.REPLY, seqid)
751
    result.write(oprot)
752
    oprot.writeMessageEnd()
753
    oprot.trans.flush()
754
 
755
  def process_updatePassword(self, seqid, iprot, oprot):
756
    args = updatePassword_args()
757
    args.read(iprot)
758
    iprot.readMessageEnd()
759
    result = updatePassword_result()
760
    try:
761
      result.success = self._handler.updatePassword(args.username, args.oldPassword, args.newPassword)
762
    except HelperServiceException, se:
763
      result.se = se
764
    oprot.writeMessageBegin("updatePassword", TMessageType.REPLY, seqid)
765
    result.write(oprot)
766
    oprot.writeMessageEnd()
767
    oprot.trans.flush()
768
 
759 chandransh 769
  def process_authenticateLogisticsUser(self, seqid, iprot, oprot):
770
    args = authenticateLogisticsUser_args()
771
    args.read(iprot)
772
    iprot.readMessageEnd()
773
    result = authenticateLogisticsUser_result()
774
    try:
775
      result.success = self._handler.authenticateLogisticsUser(args.username, args.password)
776
    except HelperServiceException, hse:
777
      result.hse = hse
778
    oprot.writeMessageBegin("authenticateLogisticsUser", TMessageType.REPLY, seqid)
779
    result.write(oprot)
780
    oprot.writeMessageEnd()
781
    oprot.trans.flush()
494 rajveer 782
 
759 chandransh 783
 
349 ashish 784
# HELPER FUNCTIONS AND STRUCTURES
785
 
765 rajveer 786
class closeSession_args:
787
 
788
  thrift_spec = (
789
  )
790
 
791
  def read(self, iprot):
792
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
793
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
794
      return
795
    iprot.readStructBegin()
796
    while True:
797
      (fname, ftype, fid) = iprot.readFieldBegin()
798
      if ftype == TType.STOP:
799
        break
800
      else:
801
        iprot.skip(ftype)
802
      iprot.readFieldEnd()
803
    iprot.readStructEnd()
804
 
805
  def write(self, oprot):
806
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
807
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
808
      return
809
    oprot.writeStructBegin('closeSession_args')
810
    oprot.writeFieldStop()
811
    oprot.writeStructEnd()
812
 
813
  def __repr__(self):
814
    L = ['%s=%r' % (key, value)
815
      for key, value in self.__dict__.iteritems()]
816
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
817
 
818
  def __eq__(self, other):
819
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
820
 
821
  def __ne__(self, other):
822
    return not (self == other)
823
 
824
class closeSession_result:
825
 
826
  thrift_spec = (
827
  )
828
 
829
  def read(self, iprot):
830
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
831
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
832
      return
833
    iprot.readStructBegin()
834
    while True:
835
      (fname, ftype, fid) = iprot.readFieldBegin()
836
      if ftype == TType.STOP:
837
        break
838
      else:
839
        iprot.skip(ftype)
840
      iprot.readFieldEnd()
841
    iprot.readStructEnd()
842
 
843
  def write(self, oprot):
844
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
845
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
846
      return
847
    oprot.writeStructBegin('closeSession_result')
848
    oprot.writeFieldStop()
849
    oprot.writeStructEnd()
850
 
851
  def __repr__(self):
852
    L = ['%s=%r' % (key, value)
853
      for key, value in self.__dict__.iteritems()]
854
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
855
 
856
  def __eq__(self, other):
857
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
858
 
859
  def __ne__(self, other):
860
    return not (self == other)
861
 
1395 varun.gupt 862
class saveUserEmailForSending_args:
863
  """
864
  Attributes:
865
   - emailTo
866
   - emailFrom
867
   - subject
868
   - body
869
   - source
870
   - emailType
871
  """
872
 
873
  thrift_spec = (
874
    None, # 0
875
    (1, TType.STRING, 'emailTo', None, None, ), # 1
876
    (2, TType.STRING, 'emailFrom', None, None, ), # 2
877
    (3, TType.STRING, 'subject', None, None, ), # 3
878
    (4, TType.STRING, 'body', None, None, ), # 4
879
    (5, TType.STRING, 'source', None, None, ), # 5
880
    (6, TType.STRING, 'emailType', None, None, ), # 6
881
  )
882
 
883
  def __init__(self, emailTo=None, emailFrom=None, subject=None, body=None, source=None, emailType=None,):
884
    self.emailTo = emailTo
885
    self.emailFrom = emailFrom
886
    self.subject = subject
887
    self.body = body
888
    self.source = source
889
    self.emailType = emailType
890
 
891
  def read(self, iprot):
892
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
893
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
894
      return
895
    iprot.readStructBegin()
896
    while True:
897
      (fname, ftype, fid) = iprot.readFieldBegin()
898
      if ftype == TType.STOP:
899
        break
900
      if fid == 1:
901
        if ftype == TType.STRING:
902
          self.emailTo = iprot.readString();
903
        else:
904
          iprot.skip(ftype)
905
      elif fid == 2:
906
        if ftype == TType.STRING:
907
          self.emailFrom = iprot.readString();
908
        else:
909
          iprot.skip(ftype)
910
      elif fid == 3:
911
        if ftype == TType.STRING:
912
          self.subject = iprot.readString();
913
        else:
914
          iprot.skip(ftype)
915
      elif fid == 4:
916
        if ftype == TType.STRING:
917
          self.body = iprot.readString();
918
        else:
919
          iprot.skip(ftype)
920
      elif fid == 5:
921
        if ftype == TType.STRING:
922
          self.source = iprot.readString();
923
        else:
924
          iprot.skip(ftype)
925
      elif fid == 6:
926
        if ftype == TType.STRING:
927
          self.emailType = iprot.readString();
928
        else:
929
          iprot.skip(ftype)
930
      else:
931
        iprot.skip(ftype)
932
      iprot.readFieldEnd()
933
    iprot.readStructEnd()
934
 
935
  def write(self, oprot):
936
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
937
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
938
      return
939
    oprot.writeStructBegin('saveUserEmailForSending_args')
940
    if self.emailTo != None:
941
      oprot.writeFieldBegin('emailTo', TType.STRING, 1)
942
      oprot.writeString(self.emailTo)
943
      oprot.writeFieldEnd()
944
    if self.emailFrom != None:
945
      oprot.writeFieldBegin('emailFrom', TType.STRING, 2)
946
      oprot.writeString(self.emailFrom)
947
      oprot.writeFieldEnd()
948
    if self.subject != None:
949
      oprot.writeFieldBegin('subject', TType.STRING, 3)
950
      oprot.writeString(self.subject)
951
      oprot.writeFieldEnd()
952
    if self.body != None:
953
      oprot.writeFieldBegin('body', TType.STRING, 4)
954
      oprot.writeString(self.body)
955
      oprot.writeFieldEnd()
956
    if self.source != None:
957
      oprot.writeFieldBegin('source', TType.STRING, 5)
958
      oprot.writeString(self.source)
959
      oprot.writeFieldEnd()
960
    if self.emailType != None:
961
      oprot.writeFieldBegin('emailType', TType.STRING, 6)
962
      oprot.writeString(self.emailType)
963
      oprot.writeFieldEnd()
964
    oprot.writeFieldStop()
965
    oprot.writeStructEnd()
966
 
967
  def __repr__(self):
968
    L = ['%s=%r' % (key, value)
969
      for key, value in self.__dict__.iteritems()]
970
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
971
 
972
  def __eq__(self, other):
973
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
974
 
975
  def __ne__(self, other):
976
    return not (self == other)
977
 
978
class saveUserEmailForSending_result:
979
  """
980
  Attributes:
981
   - se
982
  """
983
 
984
  thrift_spec = (
985
    None, # 0
986
    (1, TType.STRUCT, 'se', (HelperServiceException, HelperServiceException.thrift_spec), None, ), # 1
987
  )
988
 
989
  def __init__(self, se=None,):
990
    self.se = se
991
 
992
  def read(self, iprot):
993
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
994
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
995
      return
996
    iprot.readStructBegin()
997
    while True:
998
      (fname, ftype, fid) = iprot.readFieldBegin()
999
      if ftype == TType.STOP:
1000
        break
1001
      if fid == 1:
1002
        if ftype == TType.STRUCT:
1003
          self.se = HelperServiceException()
1004
          self.se.read(iprot)
1005
        else:
1006
          iprot.skip(ftype)
1007
      else:
1008
        iprot.skip(ftype)
1009
      iprot.readFieldEnd()
1010
    iprot.readStructEnd()
1011
 
1012
  def write(self, oprot):
1013
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1014
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1015
      return
1016
    oprot.writeStructBegin('saveUserEmailForSending_result')
1017
    if self.se != None:
1018
      oprot.writeFieldBegin('se', TType.STRUCT, 1)
1019
      self.se.write(oprot)
1020
      oprot.writeFieldEnd()
1021
    oprot.writeFieldStop()
1022
    oprot.writeStructEnd()
1023
 
1024
  def __repr__(self):
1025
    L = ['%s=%r' % (key, value)
1026
      for key, value in self.__dict__.iteritems()]
1027
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1028
 
1029
  def __eq__(self, other):
1030
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1031
 
1032
  def __ne__(self, other):
1033
    return not (self == other)
1034
 
349 ashish 1035
class sendMail_args:
1036
  """
1037
  Attributes:
1038
   - mail
1039
  """
1040
 
1041
  thrift_spec = (
1042
    None, # 0
1043
    (1, TType.STRUCT, 'mail', (Mail, Mail.thrift_spec), None, ), # 1
1044
  )
1045
 
1046
  def __init__(self, mail=None,):
1047
    self.mail = mail
1048
 
1049
  def read(self, iprot):
1050
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1051
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1052
      return
1053
    iprot.readStructBegin()
1054
    while True:
1055
      (fname, ftype, fid) = iprot.readFieldBegin()
1056
      if ftype == TType.STOP:
1057
        break
1058
      if fid == 1:
1059
        if ftype == TType.STRUCT:
1060
          self.mail = Mail()
1061
          self.mail.read(iprot)
1062
        else:
1063
          iprot.skip(ftype)
1064
      else:
1065
        iprot.skip(ftype)
1066
      iprot.readFieldEnd()
1067
    iprot.readStructEnd()
1068
 
1069
  def write(self, oprot):
1070
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1071
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1072
      return
1073
    oprot.writeStructBegin('sendMail_args')
1074
    if self.mail != None:
1075
      oprot.writeFieldBegin('mail', TType.STRUCT, 1)
1076
      self.mail.write(oprot)
1077
      oprot.writeFieldEnd()
1078
    oprot.writeFieldStop()
1079
    oprot.writeStructEnd()
1080
 
1081
  def __repr__(self):
1082
    L = ['%s=%r' % (key, value)
1083
      for key, value in self.__dict__.iteritems()]
1084
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1085
 
1086
  def __eq__(self, other):
1087
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1088
 
1089
  def __ne__(self, other):
1090
    return not (self == other)
1091
 
1092
class sendMail_result:
1093
  """
1094
  Attributes:
1095
   - se
1096
  """
1097
 
1098
  thrift_spec = (
1099
    None, # 0
1100
    (1, TType.STRUCT, 'se', (HelperServiceException, HelperServiceException.thrift_spec), None, ), # 1
1101
  )
1102
 
1103
  def __init__(self, se=None,):
1104
    self.se = se
1105
 
1106
  def read(self, iprot):
1107
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1108
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1109
      return
1110
    iprot.readStructBegin()
1111
    while True:
1112
      (fname, ftype, fid) = iprot.readFieldBegin()
1113
      if ftype == TType.STOP:
1114
        break
1115
      if fid == 1:
1116
        if ftype == TType.STRUCT:
1117
          self.se = HelperServiceException()
1118
          self.se.read(iprot)
1119
        else:
1120
          iprot.skip(ftype)
1121
      else:
1122
        iprot.skip(ftype)
1123
      iprot.readFieldEnd()
1124
    iprot.readStructEnd()
1125
 
1126
  def write(self, oprot):
1127
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1128
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1129
      return
1130
    oprot.writeStructBegin('sendMail_result')
1131
    if self.se != None:
1132
      oprot.writeFieldBegin('se', TType.STRUCT, 1)
1133
      self.se.write(oprot)
1134
      oprot.writeFieldEnd()
1135
    oprot.writeFieldStop()
1136
    oprot.writeStructEnd()
1137
 
1138
  def __repr__(self):
1139
    L = ['%s=%r' % (key, value)
1140
      for key, value in self.__dict__.iteritems()]
1141
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1142
 
1143
  def __eq__(self, other):
1144
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1145
 
1146
  def __ne__(self, other):
1147
    return not (self == other)
1148
 
1149
class sendText_args:
1150
  """
1151
  Attributes:
1152
   - message
1153
  """
1154
 
1155
  thrift_spec = (
1156
    None, # 0
1157
    (1, TType.STRUCT, 'message', (TextMessage, TextMessage.thrift_spec), None, ), # 1
1158
  )
1159
 
1160
  def __init__(self, message=None,):
1161
    self.message = message
1162
 
1163
  def read(self, iprot):
1164
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1165
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1166
      return
1167
    iprot.readStructBegin()
1168
    while True:
1169
      (fname, ftype, fid) = iprot.readFieldBegin()
1170
      if ftype == TType.STOP:
1171
        break
1172
      if fid == 1:
1173
        if ftype == TType.STRUCT:
1174
          self.message = TextMessage()
1175
          self.message.read(iprot)
1176
        else:
1177
          iprot.skip(ftype)
1178
      else:
1179
        iprot.skip(ftype)
1180
      iprot.readFieldEnd()
1181
    iprot.readStructEnd()
1182
 
1183
  def write(self, oprot):
1184
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1185
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1186
      return
1187
    oprot.writeStructBegin('sendText_args')
1188
    if self.message != None:
1189
      oprot.writeFieldBegin('message', TType.STRUCT, 1)
1190
      self.message.write(oprot)
1191
      oprot.writeFieldEnd()
1192
    oprot.writeFieldStop()
1193
    oprot.writeStructEnd()
1194
 
1195
  def __repr__(self):
1196
    L = ['%s=%r' % (key, value)
1197
      for key, value in self.__dict__.iteritems()]
1198
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1199
 
1200
  def __eq__(self, other):
1201
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1202
 
1203
  def __ne__(self, other):
1204
    return not (self == other)
1205
 
1206
class sendText_result:
1207
  """
1208
  Attributes:
1209
   - se
1210
  """
1211
 
1212
  thrift_spec = (
1213
    None, # 0
1214
    (1, TType.STRUCT, 'se', (HelperServiceException, HelperServiceException.thrift_spec), None, ), # 1
1215
  )
1216
 
1217
  def __init__(self, se=None,):
1218
    self.se = se
1219
 
1220
  def read(self, iprot):
1221
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1222
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1223
      return
1224
    iprot.readStructBegin()
1225
    while True:
1226
      (fname, ftype, fid) = iprot.readFieldBegin()
1227
      if ftype == TType.STOP:
1228
        break
1229
      if fid == 1:
1230
        if ftype == TType.STRUCT:
1231
          self.se = HelperServiceException()
1232
          self.se.read(iprot)
1233
        else:
1234
          iprot.skip(ftype)
1235
      else:
1236
        iprot.skip(ftype)
1237
      iprot.readFieldEnd()
1238
    iprot.readStructEnd()
1239
 
1240
  def write(self, oprot):
1241
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1242
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1243
      return
1244
    oprot.writeStructBegin('sendText_result')
1245
    if self.se != None:
1246
      oprot.writeFieldBegin('se', TType.STRUCT, 1)
1247
      self.se.write(oprot)
1248
      oprot.writeFieldEnd()
1249
    oprot.writeFieldStop()
1250
    oprot.writeStructEnd()
1251
 
1252
  def __repr__(self):
1253
    L = ['%s=%r' % (key, value)
1254
      for key, value in self.__dict__.iteritems()]
1255
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1256
 
1257
  def __eq__(self, other):
1258
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1259
 
1260
  def __ne__(self, other):
1261
    return not (self == other)
1262
 
1263
class addMessage_args:
1264
  """
1265
  Attributes:
1266
   - message
1267
  """
1268
 
1269
  thrift_spec = (
1270
    None, # 0
1271
    (1, TType.STRUCT, 'message', (Message, Message.thrift_spec), None, ), # 1
1272
  )
1273
 
1274
  def __init__(self, message=None,):
1275
    self.message = message
1276
 
1277
  def read(self, iprot):
1278
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1279
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1280
      return
1281
    iprot.readStructBegin()
1282
    while True:
1283
      (fname, ftype, fid) = iprot.readFieldBegin()
1284
      if ftype == TType.STOP:
1285
        break
1286
      if fid == 1:
1287
        if ftype == TType.STRUCT:
1288
          self.message = Message()
1289
          self.message.read(iprot)
1290
        else:
1291
          iprot.skip(ftype)
1292
      else:
1293
        iprot.skip(ftype)
1294
      iprot.readFieldEnd()
1295
    iprot.readStructEnd()
1296
 
1297
  def write(self, oprot):
1298
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1299
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1300
      return
1301
    oprot.writeStructBegin('addMessage_args')
1302
    if self.message != None:
1303
      oprot.writeFieldBegin('message', TType.STRUCT, 1)
1304
      self.message.write(oprot)
1305
      oprot.writeFieldEnd()
1306
    oprot.writeFieldStop()
1307
    oprot.writeStructEnd()
1308
 
1309
  def __repr__(self):
1310
    L = ['%s=%r' % (key, value)
1311
      for key, value in self.__dict__.iteritems()]
1312
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1313
 
1314
  def __eq__(self, other):
1315
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1316
 
1317
  def __ne__(self, other):
1318
    return not (self == other)
1319
 
1320
class addMessage_result:
1321
  """
1322
  Attributes:
1323
   - se
1324
  """
1325
 
1326
  thrift_spec = (
1327
    None, # 0
1328
    (1, TType.STRUCT, 'se', (HelperServiceException, HelperServiceException.thrift_spec), None, ), # 1
1329
  )
1330
 
1331
  def __init__(self, se=None,):
1332
    self.se = se
1333
 
1334
  def read(self, iprot):
1335
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1336
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1337
      return
1338
    iprot.readStructBegin()
1339
    while True:
1340
      (fname, ftype, fid) = iprot.readFieldBegin()
1341
      if ftype == TType.STOP:
1342
        break
1343
      if fid == 1:
1344
        if ftype == TType.STRUCT:
1345
          self.se = HelperServiceException()
1346
          self.se.read(iprot)
1347
        else:
1348
          iprot.skip(ftype)
1349
      else:
1350
        iprot.skip(ftype)
1351
      iprot.readFieldEnd()
1352
    iprot.readStructEnd()
1353
 
1354
  def write(self, oprot):
1355
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1356
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1357
      return
1358
    oprot.writeStructBegin('addMessage_result')
1359
    if self.se != None:
1360
      oprot.writeFieldBegin('se', TType.STRUCT, 1)
1361
      self.se.write(oprot)
1362
      oprot.writeFieldEnd()
1363
    oprot.writeFieldStop()
1364
    oprot.writeStructEnd()
1365
 
1366
  def __repr__(self):
1367
    L = ['%s=%r' % (key, value)
1368
      for key, value in self.__dict__.iteritems()]
1369
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1370
 
1371
  def __eq__(self, other):
1372
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1373
 
1374
  def __ne__(self, other):
1375
    return not (self == other)
1376
 
1377
class updateMessage_args:
1378
  """
1379
  Attributes:
1380
   - id
1381
   - message
1382
  """
1383
 
1384
  thrift_spec = (
1385
    None, # 0
1386
    (1, TType.I64, 'id', None, None, ), # 1
1387
    (2, TType.STRING, 'message', None, None, ), # 2
1388
  )
1389
 
1390
  def __init__(self, id=None, message=None,):
1391
    self.id = id
1392
    self.message = message
1393
 
1394
  def read(self, iprot):
1395
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1396
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1397
      return
1398
    iprot.readStructBegin()
1399
    while True:
1400
      (fname, ftype, fid) = iprot.readFieldBegin()
1401
      if ftype == TType.STOP:
1402
        break
1403
      if fid == 1:
1404
        if ftype == TType.I64:
1405
          self.id = iprot.readI64();
1406
        else:
1407
          iprot.skip(ftype)
1408
      elif fid == 2:
1409
        if ftype == TType.STRING:
1410
          self.message = iprot.readString();
1411
        else:
1412
          iprot.skip(ftype)
1413
      else:
1414
        iprot.skip(ftype)
1415
      iprot.readFieldEnd()
1416
    iprot.readStructEnd()
1417
 
1418
  def write(self, oprot):
1419
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1420
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1421
      return
1422
    oprot.writeStructBegin('updateMessage_args')
1423
    if self.id != None:
1424
      oprot.writeFieldBegin('id', TType.I64, 1)
1425
      oprot.writeI64(self.id)
1426
      oprot.writeFieldEnd()
1427
    if self.message != None:
1428
      oprot.writeFieldBegin('message', TType.STRING, 2)
1429
      oprot.writeString(self.message)
1430
      oprot.writeFieldEnd()
1431
    oprot.writeFieldStop()
1432
    oprot.writeStructEnd()
1433
 
1434
  def __repr__(self):
1435
    L = ['%s=%r' % (key, value)
1436
      for key, value in self.__dict__.iteritems()]
1437
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1438
 
1439
  def __eq__(self, other):
1440
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1441
 
1442
  def __ne__(self, other):
1443
    return not (self == other)
1444
 
1445
class updateMessage_result:
1446
  """
1447
  Attributes:
1448
   - se
1449
  """
1450
 
1451
  thrift_spec = (
1452
    None, # 0
1453
    (1, TType.STRUCT, 'se', (HelperServiceException, HelperServiceException.thrift_spec), None, ), # 1
1454
  )
1455
 
1456
  def __init__(self, se=None,):
1457
    self.se = se
1458
 
1459
  def read(self, iprot):
1460
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1461
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1462
      return
1463
    iprot.readStructBegin()
1464
    while True:
1465
      (fname, ftype, fid) = iprot.readFieldBegin()
1466
      if ftype == TType.STOP:
1467
        break
1468
      if fid == 1:
1469
        if ftype == TType.STRUCT:
1470
          self.se = HelperServiceException()
1471
          self.se.read(iprot)
1472
        else:
1473
          iprot.skip(ftype)
1474
      else:
1475
        iprot.skip(ftype)
1476
      iprot.readFieldEnd()
1477
    iprot.readStructEnd()
1478
 
1479
  def write(self, oprot):
1480
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1481
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1482
      return
1483
    oprot.writeStructBegin('updateMessage_result')
1484
    if self.se != None:
1485
      oprot.writeFieldBegin('se', TType.STRUCT, 1)
1486
      self.se.write(oprot)
1487
      oprot.writeFieldEnd()
1488
    oprot.writeFieldStop()
1489
    oprot.writeStructEnd()
1490
 
1491
  def __repr__(self):
1492
    L = ['%s=%r' % (key, value)
1493
      for key, value in self.__dict__.iteritems()]
1494
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1495
 
1496
  def __eq__(self, other):
1497
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1498
 
1499
  def __ne__(self, other):
1500
    return not (self == other)
1501
 
1502
class getMessage_args:
1503
  """
1504
  Attributes:
1505
   - id
1506
  """
1507
 
1508
  thrift_spec = (
1509
    None, # 0
1510
    (1, TType.I64, 'id', None, None, ), # 1
1511
  )
1512
 
1513
  def __init__(self, id=None,):
1514
    self.id = id
1515
 
1516
  def read(self, iprot):
1517
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1518
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1519
      return
1520
    iprot.readStructBegin()
1521
    while True:
1522
      (fname, ftype, fid) = iprot.readFieldBegin()
1523
      if ftype == TType.STOP:
1524
        break
1525
      if fid == 1:
1526
        if ftype == TType.I64:
1527
          self.id = iprot.readI64();
1528
        else:
1529
          iprot.skip(ftype)
1530
      else:
1531
        iprot.skip(ftype)
1532
      iprot.readFieldEnd()
1533
    iprot.readStructEnd()
1534
 
1535
  def write(self, oprot):
1536
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1537
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1538
      return
1539
    oprot.writeStructBegin('getMessage_args')
1540
    if self.id != None:
1541
      oprot.writeFieldBegin('id', TType.I64, 1)
1542
      oprot.writeI64(self.id)
1543
      oprot.writeFieldEnd()
1544
    oprot.writeFieldStop()
1545
    oprot.writeStructEnd()
1546
 
1547
  def __repr__(self):
1548
    L = ['%s=%r' % (key, value)
1549
      for key, value in self.__dict__.iteritems()]
1550
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1551
 
1552
  def __eq__(self, other):
1553
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1554
 
1555
  def __ne__(self, other):
1556
    return not (self == other)
1557
 
1558
class getMessage_result:
1559
  """
1560
  Attributes:
353 ashish 1561
   - success
349 ashish 1562
   - se
1563
  """
1564
 
1565
  thrift_spec = (
353 ashish 1566
    (0, TType.STRUCT, 'success', (Message, Message.thrift_spec), None, ), # 0
349 ashish 1567
    (1, TType.STRUCT, 'se', (HelperServiceException, HelperServiceException.thrift_spec), None, ), # 1
1568
  )
1569
 
353 ashish 1570
  def __init__(self, success=None, se=None,):
1571
    self.success = success
349 ashish 1572
    self.se = se
1573
 
1574
  def read(self, iprot):
1575
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1576
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1577
      return
1578
    iprot.readStructBegin()
1579
    while True:
1580
      (fname, ftype, fid) = iprot.readFieldBegin()
1581
      if ftype == TType.STOP:
1582
        break
353 ashish 1583
      if fid == 0:
349 ashish 1584
        if ftype == TType.STRUCT:
353 ashish 1585
          self.success = Message()
1586
          self.success.read(iprot)
1587
        else:
1588
          iprot.skip(ftype)
1589
      elif fid == 1:
1590
        if ftype == TType.STRUCT:
349 ashish 1591
          self.se = HelperServiceException()
1592
          self.se.read(iprot)
1593
        else:
1594
          iprot.skip(ftype)
1595
      else:
1596
        iprot.skip(ftype)
1597
      iprot.readFieldEnd()
1598
    iprot.readStructEnd()
1599
 
1600
  def write(self, oprot):
1601
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1602
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1603
      return
1604
    oprot.writeStructBegin('getMessage_result')
353 ashish 1605
    if self.success != None:
1606
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
1607
      self.success.write(oprot)
1608
      oprot.writeFieldEnd()
349 ashish 1609
    if self.se != None:
1610
      oprot.writeFieldBegin('se', TType.STRUCT, 1)
1611
      self.se.write(oprot)
1612
      oprot.writeFieldEnd()
1613
    oprot.writeFieldStop()
1614
    oprot.writeStructEnd()
1615
 
1616
  def __repr__(self):
1617
    L = ['%s=%r' % (key, value)
1618
      for key, value in self.__dict__.iteritems()]
1619
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1620
 
1621
  def __eq__(self, other):
1622
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1623
 
1624
  def __ne__(self, other):
1625
    return not (self == other)
1626
 
1627
class getSubstitutedMessage_args:
1628
  """
1629
  Attributes:
1630
   - id
1631
   - params
1632
  """
1633
 
1634
  thrift_spec = (
1635
    None, # 0
1636
    (1, TType.I64, 'id', None, None, ), # 1
1637
    (2, TType.MAP, 'params', (TType.STRING,None,TType.STRING,None), None, ), # 2
1638
  )
1639
 
1640
  def __init__(self, id=None, params=None,):
1641
    self.id = id
1642
    self.params = params
1643
 
1644
  def read(self, iprot):
1645
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1646
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1647
      return
1648
    iprot.readStructBegin()
1649
    while True:
1650
      (fname, ftype, fid) = iprot.readFieldBegin()
1651
      if ftype == TType.STOP:
1652
        break
1653
      if fid == 1:
1654
        if ftype == TType.I64:
1655
          self.id = iprot.readI64();
1656
        else:
1657
          iprot.skip(ftype)
1658
      elif fid == 2:
1659
        if ftype == TType.MAP:
1660
          self.params = {}
472 rajveer 1661
          (_ktype15, _vtype16, _size14 ) = iprot.readMapBegin() 
1662
          for _i18 in xrange(_size14):
1663
            _key19 = iprot.readString();
1664
            _val20 = iprot.readString();
1665
            self.params[_key19] = _val20
349 ashish 1666
          iprot.readMapEnd()
1667
        else:
1668
          iprot.skip(ftype)
1669
      else:
1670
        iprot.skip(ftype)
1671
      iprot.readFieldEnd()
1672
    iprot.readStructEnd()
1673
 
1674
  def write(self, oprot):
1675
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1676
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1677
      return
1678
    oprot.writeStructBegin('getSubstitutedMessage_args')
1679
    if self.id != None:
1680
      oprot.writeFieldBegin('id', TType.I64, 1)
1681
      oprot.writeI64(self.id)
1682
      oprot.writeFieldEnd()
1683
    if self.params != None:
1684
      oprot.writeFieldBegin('params', TType.MAP, 2)
1685
      oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.params))
472 rajveer 1686
      for kiter21,viter22 in self.params.items():
1687
        oprot.writeString(kiter21)
1688
        oprot.writeString(viter22)
349 ashish 1689
      oprot.writeMapEnd()
1690
      oprot.writeFieldEnd()
1691
    oprot.writeFieldStop()
1692
    oprot.writeStructEnd()
1693
 
1694
  def __repr__(self):
1695
    L = ['%s=%r' % (key, value)
1696
      for key, value in self.__dict__.iteritems()]
1697
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1698
 
1699
  def __eq__(self, other):
1700
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1701
 
1702
  def __ne__(self, other):
1703
    return not (self == other)
1704
 
1705
class getSubstitutedMessage_result:
1706
  """
1707
  Attributes:
353 ashish 1708
   - success
349 ashish 1709
   - se
1710
  """
1711
 
1712
  thrift_spec = (
353 ashish 1713
    (0, TType.STRUCT, 'success', (Message, Message.thrift_spec), None, ), # 0
349 ashish 1714
    (1, TType.STRUCT, 'se', (HelperServiceException, HelperServiceException.thrift_spec), None, ), # 1
1715
  )
1716
 
353 ashish 1717
  def __init__(self, success=None, se=None,):
1718
    self.success = success
349 ashish 1719
    self.se = se
1720
 
1721
  def read(self, iprot):
1722
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1723
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1724
      return
1725
    iprot.readStructBegin()
1726
    while True:
1727
      (fname, ftype, fid) = iprot.readFieldBegin()
1728
      if ftype == TType.STOP:
1729
        break
353 ashish 1730
      if fid == 0:
349 ashish 1731
        if ftype == TType.STRUCT:
353 ashish 1732
          self.success = Message()
1733
          self.success.read(iprot)
1734
        else:
1735
          iprot.skip(ftype)
1736
      elif fid == 1:
1737
        if ftype == TType.STRUCT:
349 ashish 1738
          self.se = HelperServiceException()
1739
          self.se.read(iprot)
1740
        else:
1741
          iprot.skip(ftype)
1742
      else:
1743
        iprot.skip(ftype)
1744
      iprot.readFieldEnd()
1745
    iprot.readStructEnd()
1746
 
1747
  def write(self, oprot):
1748
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1749
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1750
      return
1751
    oprot.writeStructBegin('getSubstitutedMessage_result')
353 ashish 1752
    if self.success != None:
1753
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
1754
      self.success.write(oprot)
1755
      oprot.writeFieldEnd()
349 ashish 1756
    if self.se != None:
1757
      oprot.writeFieldBegin('se', TType.STRUCT, 1)
1758
      self.se.write(oprot)
1759
      oprot.writeFieldEnd()
1760
    oprot.writeFieldStop()
1761
    oprot.writeStructEnd()
1762
 
1763
  def __repr__(self):
1764
    L = ['%s=%r' % (key, value)
1765
      for key, value in self.__dict__.iteritems()]
1766
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1767
 
1768
  def __eq__(self, other):
1769
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1770
 
1771
  def __ne__(self, other):
1772
    return not (self == other)
1773
 
494 rajveer 1774
class addUser_args:
1775
  """
1776
  Attributes:
1777
   - username
1778
   - password
1779
   - warehouseId
1780
  """
349 ashish 1781
 
494 rajveer 1782
  thrift_spec = (
1783
    None, # 0
1784
    (1, TType.STRING, 'username', None, None, ), # 1
1785
    (2, TType.STRING, 'password', None, None, ), # 2
1786
    (3, TType.I64, 'warehouseId', None, None, ), # 3
1787
  )
1788
 
1789
  def __init__(self, username=None, password=None, warehouseId=None,):
1790
    self.username = username
1791
    self.password = password
1792
    self.warehouseId = warehouseId
1793
 
1794
  def read(self, iprot):
1795
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1796
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1797
      return
1798
    iprot.readStructBegin()
1799
    while True:
1800
      (fname, ftype, fid) = iprot.readFieldBegin()
1801
      if ftype == TType.STOP:
1802
        break
1803
      if fid == 1:
1804
        if ftype == TType.STRING:
1805
          self.username = iprot.readString();
1806
        else:
1807
          iprot.skip(ftype)
1808
      elif fid == 2:
1809
        if ftype == TType.STRING:
1810
          self.password = iprot.readString();
1811
        else:
1812
          iprot.skip(ftype)
1813
      elif fid == 3:
1814
        if ftype == TType.I64:
1815
          self.warehouseId = iprot.readI64();
1816
        else:
1817
          iprot.skip(ftype)
1818
      else:
1819
        iprot.skip(ftype)
1820
      iprot.readFieldEnd()
1821
    iprot.readStructEnd()
1822
 
1823
  def write(self, oprot):
1824
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1825
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1826
      return
1827
    oprot.writeStructBegin('addUser_args')
1828
    if self.username != None:
1829
      oprot.writeFieldBegin('username', TType.STRING, 1)
1830
      oprot.writeString(self.username)
1831
      oprot.writeFieldEnd()
1832
    if self.password != None:
1833
      oprot.writeFieldBegin('password', TType.STRING, 2)
1834
      oprot.writeString(self.password)
1835
      oprot.writeFieldEnd()
1836
    if self.warehouseId != None:
1837
      oprot.writeFieldBegin('warehouseId', TType.I64, 3)
1838
      oprot.writeI64(self.warehouseId)
1839
      oprot.writeFieldEnd()
1840
    oprot.writeFieldStop()
1841
    oprot.writeStructEnd()
1842
 
1843
  def __repr__(self):
1844
    L = ['%s=%r' % (key, value)
1845
      for key, value in self.__dict__.iteritems()]
1846
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1847
 
1848
  def __eq__(self, other):
1849
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1850
 
1851
  def __ne__(self, other):
1852
    return not (self == other)
1853
 
1854
class addUser_result:
1855
  """
1856
  Attributes:
1857
   - success
1858
   - se
1859
  """
1860
 
1861
  thrift_spec = (
1862
    (0, TType.BOOL, 'success', None, None, ), # 0
1863
    (1, TType.STRUCT, 'se', (HelperServiceException, HelperServiceException.thrift_spec), None, ), # 1
1864
  )
1865
 
1866
  def __init__(self, success=None, se=None,):
1867
    self.success = success
1868
    self.se = se
1869
 
1870
  def read(self, iprot):
1871
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1872
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1873
      return
1874
    iprot.readStructBegin()
1875
    while True:
1876
      (fname, ftype, fid) = iprot.readFieldBegin()
1877
      if ftype == TType.STOP:
1878
        break
1879
      if fid == 0:
1880
        if ftype == TType.BOOL:
1881
          self.success = iprot.readBool();
1882
        else:
1883
          iprot.skip(ftype)
1884
      elif fid == 1:
1885
        if ftype == TType.STRUCT:
1886
          self.se = HelperServiceException()
1887
          self.se.read(iprot)
1888
        else:
1889
          iprot.skip(ftype)
1890
      else:
1891
        iprot.skip(ftype)
1892
      iprot.readFieldEnd()
1893
    iprot.readStructEnd()
1894
 
1895
  def write(self, oprot):
1896
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1897
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1898
      return
1899
    oprot.writeStructBegin('addUser_result')
1900
    if self.success != None:
1901
      oprot.writeFieldBegin('success', TType.BOOL, 0)
1902
      oprot.writeBool(self.success)
1903
      oprot.writeFieldEnd()
1904
    if self.se != None:
1905
      oprot.writeFieldBegin('se', TType.STRUCT, 1)
1906
      self.se.write(oprot)
1907
      oprot.writeFieldEnd()
1908
    oprot.writeFieldStop()
1909
    oprot.writeStructEnd()
1910
 
1911
  def __repr__(self):
1912
    L = ['%s=%r' % (key, value)
1913
      for key, value in self.__dict__.iteritems()]
1914
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1915
 
1916
  def __eq__(self, other):
1917
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1918
 
1919
  def __ne__(self, other):
1920
    return not (self == other)
1921
 
1922
class deleteUser_args:
1923
  """
1924
  Attributes:
1925
   - username
1926
  """
1927
 
1928
  thrift_spec = (
1929
    None, # 0
1930
    (1, TType.STRING, 'username', None, None, ), # 1
1931
  )
1932
 
1933
  def __init__(self, username=None,):
1934
    self.username = username
1935
 
1936
  def read(self, iprot):
1937
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1938
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1939
      return
1940
    iprot.readStructBegin()
1941
    while True:
1942
      (fname, ftype, fid) = iprot.readFieldBegin()
1943
      if ftype == TType.STOP:
1944
        break
1945
      if fid == 1:
1946
        if ftype == TType.STRING:
1947
          self.username = iprot.readString();
1948
        else:
1949
          iprot.skip(ftype)
1950
      else:
1951
        iprot.skip(ftype)
1952
      iprot.readFieldEnd()
1953
    iprot.readStructEnd()
1954
 
1955
  def write(self, oprot):
1956
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1957
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1958
      return
1959
    oprot.writeStructBegin('deleteUser_args')
1960
    if self.username != None:
1961
      oprot.writeFieldBegin('username', TType.STRING, 1)
1962
      oprot.writeString(self.username)
1963
      oprot.writeFieldEnd()
1964
    oprot.writeFieldStop()
1965
    oprot.writeStructEnd()
1966
 
1967
  def __repr__(self):
1968
    L = ['%s=%r' % (key, value)
1969
      for key, value in self.__dict__.iteritems()]
1970
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1971
 
1972
  def __eq__(self, other):
1973
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1974
 
1975
  def __ne__(self, other):
1976
    return not (self == other)
1977
 
1978
class deleteUser_result:
1979
  """
1980
  Attributes:
1981
   - success
1982
   - se
1983
  """
1984
 
1985
  thrift_spec = (
1986
    (0, TType.BOOL, 'success', None, None, ), # 0
1987
    (1, TType.STRUCT, 'se', (HelperServiceException, HelperServiceException.thrift_spec), None, ), # 1
1988
  )
1989
 
1990
  def __init__(self, success=None, se=None,):
1991
    self.success = success
1992
    self.se = se
1993
 
1994
  def read(self, iprot):
1995
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1996
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1997
      return
1998
    iprot.readStructBegin()
1999
    while True:
2000
      (fname, ftype, fid) = iprot.readFieldBegin()
2001
      if ftype == TType.STOP:
2002
        break
2003
      if fid == 0:
2004
        if ftype == TType.BOOL:
2005
          self.success = iprot.readBool();
2006
        else:
2007
          iprot.skip(ftype)
2008
      elif fid == 1:
2009
        if ftype == TType.STRUCT:
2010
          self.se = HelperServiceException()
2011
          self.se.read(iprot)
2012
        else:
2013
          iprot.skip(ftype)
2014
      else:
2015
        iprot.skip(ftype)
2016
      iprot.readFieldEnd()
2017
    iprot.readStructEnd()
2018
 
2019
  def write(self, oprot):
2020
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2021
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2022
      return
2023
    oprot.writeStructBegin('deleteUser_result')
2024
    if self.success != None:
2025
      oprot.writeFieldBegin('success', TType.BOOL, 0)
2026
      oprot.writeBool(self.success)
2027
      oprot.writeFieldEnd()
2028
    if self.se != None:
2029
      oprot.writeFieldBegin('se', TType.STRUCT, 1)
2030
      self.se.write(oprot)
2031
      oprot.writeFieldEnd()
2032
    oprot.writeFieldStop()
2033
    oprot.writeStructEnd()
2034
 
2035
  def __repr__(self):
2036
    L = ['%s=%r' % (key, value)
2037
      for key, value in self.__dict__.iteritems()]
2038
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2039
 
2040
  def __eq__(self, other):
2041
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2042
 
2043
  def __ne__(self, other):
2044
    return not (self == other)
2045
 
2046
class authenticateUser_args:
2047
  """
2048
  Attributes:
2049
   - username
2050
   - password
2051
  """
2052
 
2053
  thrift_spec = (
2054
    None, # 0
2055
    (1, TType.STRING, 'username', None, None, ), # 1
2056
    (2, TType.STRING, 'password', None, None, ), # 2
2057
  )
2058
 
2059
  def __init__(self, username=None, password=None,):
2060
    self.username = username
2061
    self.password = password
2062
 
2063
  def read(self, iprot):
2064
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2065
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2066
      return
2067
    iprot.readStructBegin()
2068
    while True:
2069
      (fname, ftype, fid) = iprot.readFieldBegin()
2070
      if ftype == TType.STOP:
2071
        break
2072
      if fid == 1:
2073
        if ftype == TType.STRING:
2074
          self.username = iprot.readString();
2075
        else:
2076
          iprot.skip(ftype)
2077
      elif fid == 2:
2078
        if ftype == TType.STRING:
2079
          self.password = iprot.readString();
2080
        else:
2081
          iprot.skip(ftype)
2082
      else:
2083
        iprot.skip(ftype)
2084
      iprot.readFieldEnd()
2085
    iprot.readStructEnd()
2086
 
2087
  def write(self, oprot):
2088
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2089
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2090
      return
2091
    oprot.writeStructBegin('authenticateUser_args')
2092
    if self.username != None:
2093
      oprot.writeFieldBegin('username', TType.STRING, 1)
2094
      oprot.writeString(self.username)
2095
      oprot.writeFieldEnd()
2096
    if self.password != None:
2097
      oprot.writeFieldBegin('password', TType.STRING, 2)
2098
      oprot.writeString(self.password)
2099
      oprot.writeFieldEnd()
2100
    oprot.writeFieldStop()
2101
    oprot.writeStructEnd()
2102
 
2103
  def __repr__(self):
2104
    L = ['%s=%r' % (key, value)
2105
      for key, value in self.__dict__.iteritems()]
2106
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2107
 
2108
  def __eq__(self, other):
2109
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2110
 
2111
  def __ne__(self, other):
2112
    return not (self == other)
2113
 
2114
class authenticateUser_result:
2115
  """
2116
  Attributes:
2117
   - success
2118
   - se
2119
  """
2120
 
2121
  thrift_spec = (
2122
    (0, TType.I64, 'success', None, None, ), # 0
2123
    (1, TType.STRUCT, 'se', (HelperServiceException, HelperServiceException.thrift_spec), None, ), # 1
2124
  )
2125
 
2126
  def __init__(self, success=None, se=None,):
2127
    self.success = success
2128
    self.se = se
2129
 
2130
  def read(self, iprot):
2131
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2132
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2133
      return
2134
    iprot.readStructBegin()
2135
    while True:
2136
      (fname, ftype, fid) = iprot.readFieldBegin()
2137
      if ftype == TType.STOP:
2138
        break
2139
      if fid == 0:
2140
        if ftype == TType.I64:
2141
          self.success = iprot.readI64();
2142
        else:
2143
          iprot.skip(ftype)
2144
      elif fid == 1:
2145
        if ftype == TType.STRUCT:
2146
          self.se = HelperServiceException()
2147
          self.se.read(iprot)
2148
        else:
2149
          iprot.skip(ftype)
2150
      else:
2151
        iprot.skip(ftype)
2152
      iprot.readFieldEnd()
2153
    iprot.readStructEnd()
2154
 
2155
  def write(self, oprot):
2156
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2157
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2158
      return
2159
    oprot.writeStructBegin('authenticateUser_result')
2160
    if self.success != None:
2161
      oprot.writeFieldBegin('success', TType.I64, 0)
2162
      oprot.writeI64(self.success)
2163
      oprot.writeFieldEnd()
2164
    if self.se != None:
2165
      oprot.writeFieldBegin('se', TType.STRUCT, 1)
2166
      self.se.write(oprot)
2167
      oprot.writeFieldEnd()
2168
    oprot.writeFieldStop()
2169
    oprot.writeStructEnd()
2170
 
2171
  def __repr__(self):
2172
    L = ['%s=%r' % (key, value)
2173
      for key, value in self.__dict__.iteritems()]
2174
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2175
 
2176
  def __eq__(self, other):
2177
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2178
 
2179
  def __ne__(self, other):
2180
    return not (self == other)
2181
 
2182
class updatePassword_args:
2183
  """
2184
  Attributes:
2185
   - username
2186
   - oldPassword
2187
   - newPassword
2188
  """
2189
 
2190
  thrift_spec = (
2191
    None, # 0
2192
    (1, TType.STRING, 'username', None, None, ), # 1
2193
    (2, TType.STRING, 'oldPassword', None, None, ), # 2
2194
    (3, TType.STRING, 'newPassword', None, None, ), # 3
2195
  )
2196
 
2197
  def __init__(self, username=None, oldPassword=None, newPassword=None,):
2198
    self.username = username
2199
    self.oldPassword = oldPassword
2200
    self.newPassword = newPassword
2201
 
2202
  def read(self, iprot):
2203
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2204
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2205
      return
2206
    iprot.readStructBegin()
2207
    while True:
2208
      (fname, ftype, fid) = iprot.readFieldBegin()
2209
      if ftype == TType.STOP:
2210
        break
2211
      if fid == 1:
2212
        if ftype == TType.STRING:
2213
          self.username = iprot.readString();
2214
        else:
2215
          iprot.skip(ftype)
2216
      elif fid == 2:
2217
        if ftype == TType.STRING:
2218
          self.oldPassword = iprot.readString();
2219
        else:
2220
          iprot.skip(ftype)
2221
      elif fid == 3:
2222
        if ftype == TType.STRING:
2223
          self.newPassword = iprot.readString();
2224
        else:
2225
          iprot.skip(ftype)
2226
      else:
2227
        iprot.skip(ftype)
2228
      iprot.readFieldEnd()
2229
    iprot.readStructEnd()
2230
 
2231
  def write(self, oprot):
2232
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2233
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2234
      return
2235
    oprot.writeStructBegin('updatePassword_args')
2236
    if self.username != None:
2237
      oprot.writeFieldBegin('username', TType.STRING, 1)
2238
      oprot.writeString(self.username)
2239
      oprot.writeFieldEnd()
2240
    if self.oldPassword != None:
2241
      oprot.writeFieldBegin('oldPassword', TType.STRING, 2)
2242
      oprot.writeString(self.oldPassword)
2243
      oprot.writeFieldEnd()
2244
    if self.newPassword != None:
2245
      oprot.writeFieldBegin('newPassword', TType.STRING, 3)
2246
      oprot.writeString(self.newPassword)
2247
      oprot.writeFieldEnd()
2248
    oprot.writeFieldStop()
2249
    oprot.writeStructEnd()
2250
 
2251
  def __repr__(self):
2252
    L = ['%s=%r' % (key, value)
2253
      for key, value in self.__dict__.iteritems()]
2254
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2255
 
2256
  def __eq__(self, other):
2257
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2258
 
2259
  def __ne__(self, other):
2260
    return not (self == other)
2261
 
2262
class updatePassword_result:
2263
  """
2264
  Attributes:
2265
   - success
2266
   - se
2267
  """
2268
 
2269
  thrift_spec = (
2270
    (0, TType.BOOL, 'success', None, None, ), # 0
2271
    (1, TType.STRUCT, 'se', (HelperServiceException, HelperServiceException.thrift_spec), None, ), # 1
2272
  )
2273
 
2274
  def __init__(self, success=None, se=None,):
2275
    self.success = success
2276
    self.se = se
2277
 
2278
  def read(self, iprot):
2279
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2280
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2281
      return
2282
    iprot.readStructBegin()
2283
    while True:
2284
      (fname, ftype, fid) = iprot.readFieldBegin()
2285
      if ftype == TType.STOP:
2286
        break
2287
      if fid == 0:
2288
        if ftype == TType.BOOL:
2289
          self.success = iprot.readBool();
2290
        else:
2291
          iprot.skip(ftype)
2292
      elif fid == 1:
2293
        if ftype == TType.STRUCT:
2294
          self.se = HelperServiceException()
2295
          self.se.read(iprot)
2296
        else:
2297
          iprot.skip(ftype)
2298
      else:
2299
        iprot.skip(ftype)
2300
      iprot.readFieldEnd()
2301
    iprot.readStructEnd()
2302
 
2303
  def write(self, oprot):
2304
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2305
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2306
      return
2307
    oprot.writeStructBegin('updatePassword_result')
2308
    if self.success != None:
2309
      oprot.writeFieldBegin('success', TType.BOOL, 0)
2310
      oprot.writeBool(self.success)
2311
      oprot.writeFieldEnd()
2312
    if self.se != None:
2313
      oprot.writeFieldBegin('se', TType.STRUCT, 1)
2314
      self.se.write(oprot)
2315
      oprot.writeFieldEnd()
2316
    oprot.writeFieldStop()
2317
    oprot.writeStructEnd()
2318
 
2319
  def __repr__(self):
2320
    L = ['%s=%r' % (key, value)
2321
      for key, value in self.__dict__.iteritems()]
2322
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2323
 
2324
  def __eq__(self, other):
2325
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2326
 
2327
  def __ne__(self, other):
2328
    return not (self == other)
2329
 
759 chandransh 2330
class authenticateLogisticsUser_args:
2331
  """
2332
  Attributes:
2333
   - username
2334
   - password
2335
  """
494 rajveer 2336
 
759 chandransh 2337
  thrift_spec = (
2338
    None, # 0
2339
    (1, TType.STRING, 'username', None, None, ), # 1
2340
    (2, TType.STRING, 'password', None, None, ), # 2
2341
  )
2342
 
2343
  def __init__(self, username=None, password=None,):
2344
    self.username = username
2345
    self.password = password
2346
 
2347
  def read(self, iprot):
2348
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2349
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2350
      return
2351
    iprot.readStructBegin()
2352
    while True:
2353
      (fname, ftype, fid) = iprot.readFieldBegin()
2354
      if ftype == TType.STOP:
2355
        break
2356
      if fid == 1:
2357
        if ftype == TType.STRING:
2358
          self.username = iprot.readString();
2359
        else:
2360
          iprot.skip(ftype)
2361
      elif fid == 2:
2362
        if ftype == TType.STRING:
2363
          self.password = iprot.readString();
2364
        else:
2365
          iprot.skip(ftype)
2366
      else:
2367
        iprot.skip(ftype)
2368
      iprot.readFieldEnd()
2369
    iprot.readStructEnd()
2370
 
2371
  def write(self, oprot):
2372
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2373
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2374
      return
2375
    oprot.writeStructBegin('authenticateLogisticsUser_args')
2376
    if self.username != None:
2377
      oprot.writeFieldBegin('username', TType.STRING, 1)
2378
      oprot.writeString(self.username)
2379
      oprot.writeFieldEnd()
2380
    if self.password != None:
2381
      oprot.writeFieldBegin('password', TType.STRING, 2)
2382
      oprot.writeString(self.password)
2383
      oprot.writeFieldEnd()
2384
    oprot.writeFieldStop()
2385
    oprot.writeStructEnd()
2386
 
2387
  def __repr__(self):
2388
    L = ['%s=%r' % (key, value)
2389
      for key, value in self.__dict__.iteritems()]
2390
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2391
 
2392
  def __eq__(self, other):
2393
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2394
 
2395
  def __ne__(self, other):
2396
    return not (self == other)
2397
 
2398
class authenticateLogisticsUser_result:
2399
  """
2400
  Attributes:
2401
   - success
2402
   - hse
2403
  """
2404
 
2405
  thrift_spec = (
2406
    (0, TType.STRUCT, 'success', (LogisticsUser, LogisticsUser.thrift_spec), None, ), # 0
2407
    (1, TType.STRUCT, 'hse', (HelperServiceException, HelperServiceException.thrift_spec), None, ), # 1
2408
  )
2409
 
2410
  def __init__(self, success=None, hse=None,):
2411
    self.success = success
2412
    self.hse = hse
2413
 
2414
  def read(self, iprot):
2415
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2416
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2417
      return
2418
    iprot.readStructBegin()
2419
    while True:
2420
      (fname, ftype, fid) = iprot.readFieldBegin()
2421
      if ftype == TType.STOP:
2422
        break
2423
      if fid == 0:
2424
        if ftype == TType.STRUCT:
2425
          self.success = LogisticsUser()
2426
          self.success.read(iprot)
2427
        else:
2428
          iprot.skip(ftype)
2429
      elif fid == 1:
2430
        if ftype == TType.STRUCT:
2431
          self.hse = HelperServiceException()
2432
          self.hse.read(iprot)
2433
        else:
2434
          iprot.skip(ftype)
2435
      else:
2436
        iprot.skip(ftype)
2437
      iprot.readFieldEnd()
2438
    iprot.readStructEnd()
2439
 
2440
  def write(self, oprot):
2441
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2442
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2443
      return
2444
    oprot.writeStructBegin('authenticateLogisticsUser_result')
2445
    if self.success != None:
2446
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
2447
      self.success.write(oprot)
2448
      oprot.writeFieldEnd()
2449
    if self.hse != None:
2450
      oprot.writeFieldBegin('hse', TType.STRUCT, 1)
2451
      self.hse.write(oprot)
2452
      oprot.writeFieldEnd()
2453
    oprot.writeFieldStop()
2454
    oprot.writeStructEnd()
2455
 
2456
  def __repr__(self):
2457
    L = ['%s=%r' % (key, value)
2458
      for key, value in self.__dict__.iteritems()]
2459
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2460
 
2461
  def __eq__(self, other):
2462
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2463
 
2464
  def __ne__(self, other):
2465
    return not (self == other)
2466
 
2467