| 412 |
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:
|
| 669 |
chandransh |
19 |
def getProvider(self, providerId):
|
|
|
20 |
"""
|
|
|
21 |
Returns a provider for a given provider ID. Throws an exception if none found.
|
|
|
22 |
|
|
|
23 |
Parameters:
|
|
|
24 |
- providerId
|
|
|
25 |
"""
|
|
|
26 |
pass
|
|
|
27 |
|
| 647 |
chandransh |
28 |
def getLogisticsEstimation(self, itemId, destination_pin):
|
| 483 |
rajveer |
29 |
"""
|
| 647 |
chandransh |
30 |
Returns a LogisticsInfo structure w/o an airway bill number. Use this method during the estimation phase.
|
|
|
31 |
Raises an exception if this pincode is not allocated to any warehouse zone or provider. Also, if the pincode
|
|
|
32 |
is allocated to a warehouse zone but there are no actual warehouses in that zone, an exception is raised.
|
|
|
33 |
|
| 483 |
rajveer |
34 |
Parameters:
|
| 647 |
chandransh |
35 |
- itemId
|
|
|
36 |
- destination_pin
|
| 483 |
rajveer |
37 |
"""
|
|
|
38 |
pass
|
|
|
39 |
|
| 647 |
chandransh |
40 |
def getLogisticsInfo(self, destination_pincode, item_id):
|
| 472 |
rajveer |
41 |
"""
|
| 647 |
chandransh |
42 |
Same as above excpet that an airway bill number is also allocated and returned.
|
|
|
43 |
|
| 472 |
rajveer |
44 |
Parameters:
|
| 647 |
chandransh |
45 |
- destination_pincode
|
|
|
46 |
- item_id
|
| 472 |
rajveer |
47 |
"""
|
|
|
48 |
pass
|
|
|
49 |
|
| 647 |
chandransh |
50 |
def getEmptyAWB(self, providerId):
|
| 412 |
ashish |
51 |
"""
|
| 647 |
chandransh |
52 |
Returns an unused AWB number for the given provider.
|
|
|
53 |
|
| 412 |
ashish |
54 |
Parameters:
|
| 647 |
chandransh |
55 |
- providerId
|
| 412 |
ashish |
56 |
"""
|
|
|
57 |
pass
|
|
|
58 |
|
| 647 |
chandransh |
59 |
def getShipmentInfo(self, awb, providerId):
|
| 412 |
ashish |
60 |
"""
|
| 647 |
chandransh |
61 |
Returns the list of updates for the given AWB number and provider id. The list is empty if there are no updates yet.
|
|
|
62 |
|
| 412 |
ashish |
63 |
Parameters:
|
|
|
64 |
- awb
|
| 647 |
chandransh |
65 |
- providerId
|
| 412 |
ashish |
66 |
"""
|
|
|
67 |
pass
|
|
|
68 |
|
|
|
69 |
|
|
|
70 |
class Client(Iface):
|
|
|
71 |
def __init__(self, iprot, oprot=None):
|
|
|
72 |
self._iprot = self._oprot = iprot
|
|
|
73 |
if oprot != None:
|
|
|
74 |
self._oprot = oprot
|
|
|
75 |
self._seqid = 0
|
|
|
76 |
|
| 669 |
chandransh |
77 |
def getProvider(self, providerId):
|
|
|
78 |
"""
|
|
|
79 |
Returns a provider for a given provider ID. Throws an exception if none found.
|
|
|
80 |
|
|
|
81 |
Parameters:
|
|
|
82 |
- providerId
|
|
|
83 |
"""
|
|
|
84 |
self.send_getProvider(providerId)
|
|
|
85 |
return self.recv_getProvider()
|
|
|
86 |
|
|
|
87 |
def send_getProvider(self, providerId):
|
|
|
88 |
self._oprot.writeMessageBegin('getProvider', TMessageType.CALL, self._seqid)
|
|
|
89 |
args = getProvider_args()
|
|
|
90 |
args.providerId = providerId
|
|
|
91 |
args.write(self._oprot)
|
|
|
92 |
self._oprot.writeMessageEnd()
|
|
|
93 |
self._oprot.trans.flush()
|
|
|
94 |
|
|
|
95 |
def recv_getProvider(self, ):
|
|
|
96 |
(fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
97 |
if mtype == TMessageType.EXCEPTION:
|
|
|
98 |
x = TApplicationException()
|
|
|
99 |
x.read(self._iprot)
|
|
|
100 |
self._iprot.readMessageEnd()
|
|
|
101 |
raise x
|
|
|
102 |
result = getProvider_result()
|
|
|
103 |
result.read(self._iprot)
|
|
|
104 |
self._iprot.readMessageEnd()
|
|
|
105 |
if result.success != None:
|
|
|
106 |
return result.success
|
|
|
107 |
if result.lse != None:
|
|
|
108 |
raise result.lse
|
|
|
109 |
raise TApplicationException(TApplicationException.MISSING_RESULT, "getProvider failed: unknown result");
|
|
|
110 |
|
| 647 |
chandransh |
111 |
def getLogisticsEstimation(self, itemId, destination_pin):
|
| 483 |
rajveer |
112 |
"""
|
| 647 |
chandransh |
113 |
Returns a LogisticsInfo structure w/o an airway bill number. Use this method during the estimation phase.
|
|
|
114 |
Raises an exception if this pincode is not allocated to any warehouse zone or provider. Also, if the pincode
|
|
|
115 |
is allocated to a warehouse zone but there are no actual warehouses in that zone, an exception is raised.
|
|
|
116 |
|
| 483 |
rajveer |
117 |
Parameters:
|
| 647 |
chandransh |
118 |
- itemId
|
|
|
119 |
- destination_pin
|
| 483 |
rajveer |
120 |
"""
|
| 647 |
chandransh |
121 |
self.send_getLogisticsEstimation(itemId, destination_pin)
|
|
|
122 |
return self.recv_getLogisticsEstimation()
|
| 483 |
rajveer |
123 |
|
| 647 |
chandransh |
124 |
def send_getLogisticsEstimation(self, itemId, destination_pin):
|
|
|
125 |
self._oprot.writeMessageBegin('getLogisticsEstimation', TMessageType.CALL, self._seqid)
|
|
|
126 |
args = getLogisticsEstimation_args()
|
|
|
127 |
args.itemId = itemId
|
|
|
128 |
args.destination_pin = destination_pin
|
| 483 |
rajveer |
129 |
args.write(self._oprot)
|
|
|
130 |
self._oprot.writeMessageEnd()
|
|
|
131 |
self._oprot.trans.flush()
|
|
|
132 |
|
| 647 |
chandransh |
133 |
def recv_getLogisticsEstimation(self, ):
|
| 483 |
rajveer |
134 |
(fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
135 |
if mtype == TMessageType.EXCEPTION:
|
|
|
136 |
x = TApplicationException()
|
|
|
137 |
x.read(self._iprot)
|
|
|
138 |
self._iprot.readMessageEnd()
|
|
|
139 |
raise x
|
| 647 |
chandransh |
140 |
result = getLogisticsEstimation_result()
|
| 483 |
rajveer |
141 |
result.read(self._iprot)
|
|
|
142 |
self._iprot.readMessageEnd()
|
|
|
143 |
if result.success != None:
|
|
|
144 |
return result.success
|
|
|
145 |
if result.se != None:
|
|
|
146 |
raise result.se
|
| 647 |
chandransh |
147 |
raise TApplicationException(TApplicationException.MISSING_RESULT, "getLogisticsEstimation failed: unknown result");
|
| 483 |
rajveer |
148 |
|
| 647 |
chandransh |
149 |
def getLogisticsInfo(self, destination_pincode, item_id):
|
| 472 |
rajveer |
150 |
"""
|
| 647 |
chandransh |
151 |
Same as above excpet that an airway bill number is also allocated and returned.
|
|
|
152 |
|
| 472 |
rajveer |
153 |
Parameters:
|
| 647 |
chandransh |
154 |
- destination_pincode
|
|
|
155 |
- item_id
|
| 472 |
rajveer |
156 |
"""
|
| 647 |
chandransh |
157 |
self.send_getLogisticsInfo(destination_pincode, item_id)
|
|
|
158 |
return self.recv_getLogisticsInfo()
|
| 472 |
rajveer |
159 |
|
| 647 |
chandransh |
160 |
def send_getLogisticsInfo(self, destination_pincode, item_id):
|
|
|
161 |
self._oprot.writeMessageBegin('getLogisticsInfo', TMessageType.CALL, self._seqid)
|
|
|
162 |
args = getLogisticsInfo_args()
|
|
|
163 |
args.destination_pincode = destination_pincode
|
|
|
164 |
args.item_id = item_id
|
| 472 |
rajveer |
165 |
args.write(self._oprot)
|
|
|
166 |
self._oprot.writeMessageEnd()
|
|
|
167 |
self._oprot.trans.flush()
|
|
|
168 |
|
| 647 |
chandransh |
169 |
def recv_getLogisticsInfo(self, ):
|
| 472 |
rajveer |
170 |
(fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
171 |
if mtype == TMessageType.EXCEPTION:
|
|
|
172 |
x = TApplicationException()
|
|
|
173 |
x.read(self._iprot)
|
|
|
174 |
self._iprot.readMessageEnd()
|
|
|
175 |
raise x
|
| 647 |
chandransh |
176 |
result = getLogisticsInfo_result()
|
| 472 |
rajveer |
177 |
result.read(self._iprot)
|
|
|
178 |
self._iprot.readMessageEnd()
|
|
|
179 |
if result.success != None:
|
|
|
180 |
return result.success
|
|
|
181 |
if result.se != None:
|
|
|
182 |
raise result.se
|
| 647 |
chandransh |
183 |
raise TApplicationException(TApplicationException.MISSING_RESULT, "getLogisticsInfo failed: unknown result");
|
| 472 |
rajveer |
184 |
|
| 647 |
chandransh |
185 |
def getEmptyAWB(self, providerId):
|
| 412 |
ashish |
186 |
"""
|
| 647 |
chandransh |
187 |
Returns an unused AWB number for the given provider.
|
|
|
188 |
|
| 412 |
ashish |
189 |
Parameters:
|
| 647 |
chandransh |
190 |
- providerId
|
| 412 |
ashish |
191 |
"""
|
| 647 |
chandransh |
192 |
self.send_getEmptyAWB(providerId)
|
| 412 |
ashish |
193 |
return self.recv_getEmptyAWB()
|
|
|
194 |
|
| 647 |
chandransh |
195 |
def send_getEmptyAWB(self, providerId):
|
| 412 |
ashish |
196 |
self._oprot.writeMessageBegin('getEmptyAWB', TMessageType.CALL, self._seqid)
|
|
|
197 |
args = getEmptyAWB_args()
|
| 647 |
chandransh |
198 |
args.providerId = providerId
|
| 412 |
ashish |
199 |
args.write(self._oprot)
|
|
|
200 |
self._oprot.writeMessageEnd()
|
|
|
201 |
self._oprot.trans.flush()
|
|
|
202 |
|
|
|
203 |
def recv_getEmptyAWB(self, ):
|
|
|
204 |
(fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
205 |
if mtype == TMessageType.EXCEPTION:
|
|
|
206 |
x = TApplicationException()
|
|
|
207 |
x.read(self._iprot)
|
|
|
208 |
self._iprot.readMessageEnd()
|
|
|
209 |
raise x
|
|
|
210 |
result = getEmptyAWB_result()
|
|
|
211 |
result.read(self._iprot)
|
|
|
212 |
self._iprot.readMessageEnd()
|
|
|
213 |
if result.success != None:
|
|
|
214 |
return result.success
|
| 647 |
chandransh |
215 |
if result.se != None:
|
|
|
216 |
raise result.se
|
| 412 |
ashish |
217 |
raise TApplicationException(TApplicationException.MISSING_RESULT, "getEmptyAWB failed: unknown result");
|
|
|
218 |
|
| 647 |
chandransh |
219 |
def getShipmentInfo(self, awb, providerId):
|
| 412 |
ashish |
220 |
"""
|
| 647 |
chandransh |
221 |
Returns the list of updates for the given AWB number and provider id. The list is empty if there are no updates yet.
|
|
|
222 |
|
| 412 |
ashish |
223 |
Parameters:
|
|
|
224 |
- awb
|
| 647 |
chandransh |
225 |
- providerId
|
| 412 |
ashish |
226 |
"""
|
| 647 |
chandransh |
227 |
self.send_getShipmentInfo(awb, providerId)
|
| 412 |
ashish |
228 |
return self.recv_getShipmentInfo()
|
|
|
229 |
|
| 647 |
chandransh |
230 |
def send_getShipmentInfo(self, awb, providerId):
|
| 412 |
ashish |
231 |
self._oprot.writeMessageBegin('getShipmentInfo', TMessageType.CALL, self._seqid)
|
|
|
232 |
args = getShipmentInfo_args()
|
|
|
233 |
args.awb = awb
|
| 647 |
chandransh |
234 |
args.providerId = providerId
|
| 412 |
ashish |
235 |
args.write(self._oprot)
|
|
|
236 |
self._oprot.writeMessageEnd()
|
|
|
237 |
self._oprot.trans.flush()
|
|
|
238 |
|
|
|
239 |
def recv_getShipmentInfo(self, ):
|
|
|
240 |
(fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
241 |
if mtype == TMessageType.EXCEPTION:
|
|
|
242 |
x = TApplicationException()
|
|
|
243 |
x.read(self._iprot)
|
|
|
244 |
self._iprot.readMessageEnd()
|
|
|
245 |
raise x
|
|
|
246 |
result = getShipmentInfo_result()
|
|
|
247 |
result.read(self._iprot)
|
|
|
248 |
self._iprot.readMessageEnd()
|
|
|
249 |
if result.success != None:
|
|
|
250 |
return result.success
|
| 647 |
chandransh |
251 |
if result.se != None:
|
|
|
252 |
raise result.se
|
| 412 |
ashish |
253 |
raise TApplicationException(TApplicationException.MISSING_RESULT, "getShipmentInfo failed: unknown result");
|
|
|
254 |
|
|
|
255 |
|
|
|
256 |
class Processor(Iface, TProcessor):
|
|
|
257 |
def __init__(self, handler):
|
|
|
258 |
self._handler = handler
|
|
|
259 |
self._processMap = {}
|
| 669 |
chandransh |
260 |
self._processMap["getProvider"] = Processor.process_getProvider
|
| 647 |
chandransh |
261 |
self._processMap["getLogisticsEstimation"] = Processor.process_getLogisticsEstimation
|
| 483 |
rajveer |
262 |
self._processMap["getLogisticsInfo"] = Processor.process_getLogisticsInfo
|
| 412 |
ashish |
263 |
self._processMap["getEmptyAWB"] = Processor.process_getEmptyAWB
|
|
|
264 |
self._processMap["getShipmentInfo"] = Processor.process_getShipmentInfo
|
|
|
265 |
|
|
|
266 |
def process(self, iprot, oprot):
|
|
|
267 |
(name, type, seqid) = iprot.readMessageBegin()
|
|
|
268 |
if name not in self._processMap:
|
|
|
269 |
iprot.skip(TType.STRUCT)
|
|
|
270 |
iprot.readMessageEnd()
|
|
|
271 |
x = TApplicationException(TApplicationException.UNKNOWN_METHOD, 'Unknown function %s' % (name))
|
|
|
272 |
oprot.writeMessageBegin(name, TMessageType.EXCEPTION, seqid)
|
|
|
273 |
x.write(oprot)
|
|
|
274 |
oprot.writeMessageEnd()
|
|
|
275 |
oprot.trans.flush()
|
|
|
276 |
return
|
|
|
277 |
else:
|
|
|
278 |
self._processMap[name](self, seqid, iprot, oprot)
|
|
|
279 |
return True
|
|
|
280 |
|
| 669 |
chandransh |
281 |
def process_getProvider(self, seqid, iprot, oprot):
|
|
|
282 |
args = getProvider_args()
|
|
|
283 |
args.read(iprot)
|
|
|
284 |
iprot.readMessageEnd()
|
|
|
285 |
result = getProvider_result()
|
|
|
286 |
try:
|
|
|
287 |
result.success = self._handler.getProvider(args.providerId)
|
|
|
288 |
except LogisticsServiceException, lse:
|
|
|
289 |
result.lse = lse
|
|
|
290 |
oprot.writeMessageBegin("getProvider", TMessageType.REPLY, seqid)
|
|
|
291 |
result.write(oprot)
|
|
|
292 |
oprot.writeMessageEnd()
|
|
|
293 |
oprot.trans.flush()
|
|
|
294 |
|
| 647 |
chandransh |
295 |
def process_getLogisticsEstimation(self, seqid, iprot, oprot):
|
|
|
296 |
args = getLogisticsEstimation_args()
|
| 483 |
rajveer |
297 |
args.read(iprot)
|
|
|
298 |
iprot.readMessageEnd()
|
| 647 |
chandransh |
299 |
result = getLogisticsEstimation_result()
|
| 483 |
rajveer |
300 |
try:
|
| 647 |
chandransh |
301 |
result.success = self._handler.getLogisticsEstimation(args.itemId, args.destination_pin)
|
| 483 |
rajveer |
302 |
except LogisticsServiceException, se:
|
|
|
303 |
result.se = se
|
| 647 |
chandransh |
304 |
oprot.writeMessageBegin("getLogisticsEstimation", TMessageType.REPLY, seqid)
|
| 483 |
rajveer |
305 |
result.write(oprot)
|
|
|
306 |
oprot.writeMessageEnd()
|
|
|
307 |
oprot.trans.flush()
|
|
|
308 |
|
| 647 |
chandransh |
309 |
def process_getLogisticsInfo(self, seqid, iprot, oprot):
|
|
|
310 |
args = getLogisticsInfo_args()
|
| 472 |
rajveer |
311 |
args.read(iprot)
|
|
|
312 |
iprot.readMessageEnd()
|
| 647 |
chandransh |
313 |
result = getLogisticsInfo_result()
|
| 472 |
rajveer |
314 |
try:
|
| 647 |
chandransh |
315 |
result.success = self._handler.getLogisticsInfo(args.destination_pincode, args.item_id)
|
| 472 |
rajveer |
316 |
except LogisticsServiceException, se:
|
|
|
317 |
result.se = se
|
| 647 |
chandransh |
318 |
oprot.writeMessageBegin("getLogisticsInfo", TMessageType.REPLY, seqid)
|
| 472 |
rajveer |
319 |
result.write(oprot)
|
|
|
320 |
oprot.writeMessageEnd()
|
|
|
321 |
oprot.trans.flush()
|
|
|
322 |
|
| 412 |
ashish |
323 |
def process_getEmptyAWB(self, seqid, iprot, oprot):
|
|
|
324 |
args = getEmptyAWB_args()
|
|
|
325 |
args.read(iprot)
|
|
|
326 |
iprot.readMessageEnd()
|
|
|
327 |
result = getEmptyAWB_result()
|
| 647 |
chandransh |
328 |
try:
|
|
|
329 |
result.success = self._handler.getEmptyAWB(args.providerId)
|
|
|
330 |
except LogisticsServiceException, se:
|
|
|
331 |
result.se = se
|
| 412 |
ashish |
332 |
oprot.writeMessageBegin("getEmptyAWB", TMessageType.REPLY, seqid)
|
|
|
333 |
result.write(oprot)
|
|
|
334 |
oprot.writeMessageEnd()
|
|
|
335 |
oprot.trans.flush()
|
|
|
336 |
|
|
|
337 |
def process_getShipmentInfo(self, seqid, iprot, oprot):
|
|
|
338 |
args = getShipmentInfo_args()
|
|
|
339 |
args.read(iprot)
|
|
|
340 |
iprot.readMessageEnd()
|
|
|
341 |
result = getShipmentInfo_result()
|
| 647 |
chandransh |
342 |
try:
|
|
|
343 |
result.success = self._handler.getShipmentInfo(args.awb, args.providerId)
|
|
|
344 |
except LogisticsServiceException, se:
|
|
|
345 |
result.se = se
|
| 412 |
ashish |
346 |
oprot.writeMessageBegin("getShipmentInfo", TMessageType.REPLY, seqid)
|
|
|
347 |
result.write(oprot)
|
|
|
348 |
oprot.writeMessageEnd()
|
|
|
349 |
oprot.trans.flush()
|
|
|
350 |
|
|
|
351 |
|
|
|
352 |
# HELPER FUNCTIONS AND STRUCTURES
|
|
|
353 |
|
| 669 |
chandransh |
354 |
class getProvider_args:
|
|
|
355 |
"""
|
|
|
356 |
Attributes:
|
|
|
357 |
- providerId
|
|
|
358 |
"""
|
|
|
359 |
|
|
|
360 |
thrift_spec = (
|
|
|
361 |
None, # 0
|
|
|
362 |
(1, TType.I64, 'providerId', None, None, ), # 1
|
|
|
363 |
)
|
|
|
364 |
|
|
|
365 |
def __init__(self, providerId=None,):
|
|
|
366 |
self.providerId = providerId
|
|
|
367 |
|
|
|
368 |
def read(self, iprot):
|
|
|
369 |
if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
370 |
fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
371 |
return
|
|
|
372 |
iprot.readStructBegin()
|
|
|
373 |
while True:
|
|
|
374 |
(fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
375 |
if ftype == TType.STOP:
|
|
|
376 |
break
|
|
|
377 |
if fid == 1:
|
|
|
378 |
if ftype == TType.I64:
|
|
|
379 |
self.providerId = iprot.readI64();
|
|
|
380 |
else:
|
|
|
381 |
iprot.skip(ftype)
|
|
|
382 |
else:
|
|
|
383 |
iprot.skip(ftype)
|
|
|
384 |
iprot.readFieldEnd()
|
|
|
385 |
iprot.readStructEnd()
|
|
|
386 |
|
|
|
387 |
def write(self, oprot):
|
|
|
388 |
if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
389 |
oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
390 |
return
|
|
|
391 |
oprot.writeStructBegin('getProvider_args')
|
|
|
392 |
if self.providerId != None:
|
|
|
393 |
oprot.writeFieldBegin('providerId', TType.I64, 1)
|
|
|
394 |
oprot.writeI64(self.providerId)
|
|
|
395 |
oprot.writeFieldEnd()
|
|
|
396 |
oprot.writeFieldStop()
|
|
|
397 |
oprot.writeStructEnd()
|
|
|
398 |
|
|
|
399 |
def __repr__(self):
|
|
|
400 |
L = ['%s=%r' % (key, value)
|
|
|
401 |
for key, value in self.__dict__.iteritems()]
|
|
|
402 |
return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
|
|
|
403 |
|
|
|
404 |
def __eq__(self, other):
|
|
|
405 |
return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
406 |
|
|
|
407 |
def __ne__(self, other):
|
|
|
408 |
return not (self == other)
|
|
|
409 |
|
|
|
410 |
class getProvider_result:
|
|
|
411 |
"""
|
|
|
412 |
Attributes:
|
|
|
413 |
- success
|
|
|
414 |
- lse
|
|
|
415 |
"""
|
|
|
416 |
|
|
|
417 |
thrift_spec = (
|
|
|
418 |
(0, TType.STRUCT, 'success', (Provider, Provider.thrift_spec), None, ), # 0
|
|
|
419 |
(1, TType.STRUCT, 'lse', (LogisticsServiceException, LogisticsServiceException.thrift_spec), None, ), # 1
|
|
|
420 |
)
|
|
|
421 |
|
|
|
422 |
def __init__(self, success=None, lse=None,):
|
|
|
423 |
self.success = success
|
|
|
424 |
self.lse = lse
|
|
|
425 |
|
|
|
426 |
def read(self, iprot):
|
|
|
427 |
if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
428 |
fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
429 |
return
|
|
|
430 |
iprot.readStructBegin()
|
|
|
431 |
while True:
|
|
|
432 |
(fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
433 |
if ftype == TType.STOP:
|
|
|
434 |
break
|
|
|
435 |
if fid == 0:
|
|
|
436 |
if ftype == TType.STRUCT:
|
|
|
437 |
self.success = Provider()
|
|
|
438 |
self.success.read(iprot)
|
|
|
439 |
else:
|
|
|
440 |
iprot.skip(ftype)
|
|
|
441 |
elif fid == 1:
|
|
|
442 |
if ftype == TType.STRUCT:
|
|
|
443 |
self.lse = LogisticsServiceException()
|
|
|
444 |
self.lse.read(iprot)
|
|
|
445 |
else:
|
|
|
446 |
iprot.skip(ftype)
|
|
|
447 |
else:
|
|
|
448 |
iprot.skip(ftype)
|
|
|
449 |
iprot.readFieldEnd()
|
|
|
450 |
iprot.readStructEnd()
|
|
|
451 |
|
|
|
452 |
def write(self, oprot):
|
|
|
453 |
if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
454 |
oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
455 |
return
|
|
|
456 |
oprot.writeStructBegin('getProvider_result')
|
|
|
457 |
if self.success != None:
|
|
|
458 |
oprot.writeFieldBegin('success', TType.STRUCT, 0)
|
|
|
459 |
self.success.write(oprot)
|
|
|
460 |
oprot.writeFieldEnd()
|
|
|
461 |
if self.lse != None:
|
|
|
462 |
oprot.writeFieldBegin('lse', TType.STRUCT, 1)
|
|
|
463 |
self.lse.write(oprot)
|
|
|
464 |
oprot.writeFieldEnd()
|
|
|
465 |
oprot.writeFieldStop()
|
|
|
466 |
oprot.writeStructEnd()
|
|
|
467 |
|
|
|
468 |
def __repr__(self):
|
|
|
469 |
L = ['%s=%r' % (key, value)
|
|
|
470 |
for key, value in self.__dict__.iteritems()]
|
|
|
471 |
return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
|
|
|
472 |
|
|
|
473 |
def __eq__(self, other):
|
|
|
474 |
return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
475 |
|
|
|
476 |
def __ne__(self, other):
|
|
|
477 |
return not (self == other)
|
|
|
478 |
|
| 647 |
chandransh |
479 |
class getLogisticsEstimation_args:
|
| 483 |
rajveer |
480 |
"""
|
|
|
481 |
Attributes:
|
| 647 |
chandransh |
482 |
- itemId
|
|
|
483 |
- destination_pin
|
| 483 |
rajveer |
484 |
"""
|
|
|
485 |
|
|
|
486 |
thrift_spec = (
|
|
|
487 |
None, # 0
|
| 647 |
chandransh |
488 |
(1, TType.I64, 'itemId', None, None, ), # 1
|
|
|
489 |
(2, TType.STRING, 'destination_pin', None, None, ), # 2
|
| 483 |
rajveer |
490 |
)
|
|
|
491 |
|
| 647 |
chandransh |
492 |
def __init__(self, itemId=None, destination_pin=None,):
|
|
|
493 |
self.itemId = itemId
|
|
|
494 |
self.destination_pin = destination_pin
|
| 483 |
rajveer |
495 |
|
|
|
496 |
def read(self, iprot):
|
|
|
497 |
if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
498 |
fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
499 |
return
|
|
|
500 |
iprot.readStructBegin()
|
|
|
501 |
while True:
|
|
|
502 |
(fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
503 |
if ftype == TType.STOP:
|
|
|
504 |
break
|
|
|
505 |
if fid == 1:
|
| 647 |
chandransh |
506 |
if ftype == TType.I64:
|
|
|
507 |
self.itemId = iprot.readI64();
|
| 483 |
rajveer |
508 |
else:
|
|
|
509 |
iprot.skip(ftype)
|
|
|
510 |
elif fid == 2:
|
|
|
511 |
if ftype == TType.STRING:
|
| 647 |
chandransh |
512 |
self.destination_pin = iprot.readString();
|
| 483 |
rajveer |
513 |
else:
|
|
|
514 |
iprot.skip(ftype)
|
|
|
515 |
else:
|
|
|
516 |
iprot.skip(ftype)
|
|
|
517 |
iprot.readFieldEnd()
|
|
|
518 |
iprot.readStructEnd()
|
|
|
519 |
|
|
|
520 |
def write(self, oprot):
|
|
|
521 |
if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
522 |
oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
523 |
return
|
| 647 |
chandransh |
524 |
oprot.writeStructBegin('getLogisticsEstimation_args')
|
|
|
525 |
if self.itemId != None:
|
|
|
526 |
oprot.writeFieldBegin('itemId', TType.I64, 1)
|
|
|
527 |
oprot.writeI64(self.itemId)
|
| 483 |
rajveer |
528 |
oprot.writeFieldEnd()
|
| 647 |
chandransh |
529 |
if self.destination_pin != None:
|
|
|
530 |
oprot.writeFieldBegin('destination_pin', TType.STRING, 2)
|
|
|
531 |
oprot.writeString(self.destination_pin)
|
| 483 |
rajveer |
532 |
oprot.writeFieldEnd()
|
|
|
533 |
oprot.writeFieldStop()
|
|
|
534 |
oprot.writeStructEnd()
|
|
|
535 |
|
|
|
536 |
def __repr__(self):
|
|
|
537 |
L = ['%s=%r' % (key, value)
|
|
|
538 |
for key, value in self.__dict__.iteritems()]
|
|
|
539 |
return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
|
|
|
540 |
|
|
|
541 |
def __eq__(self, other):
|
|
|
542 |
return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
543 |
|
|
|
544 |
def __ne__(self, other):
|
|
|
545 |
return not (self == other)
|
|
|
546 |
|
| 647 |
chandransh |
547 |
class getLogisticsEstimation_result:
|
| 483 |
rajveer |
548 |
"""
|
|
|
549 |
Attributes:
|
|
|
550 |
- success
|
|
|
551 |
- se
|
|
|
552 |
"""
|
|
|
553 |
|
|
|
554 |
thrift_spec = (
|
|
|
555 |
(0, TType.STRUCT, 'success', (LogisticsInfo, LogisticsInfo.thrift_spec), None, ), # 0
|
|
|
556 |
(1, TType.STRUCT, 'se', (LogisticsServiceException, LogisticsServiceException.thrift_spec), None, ), # 1
|
|
|
557 |
)
|
|
|
558 |
|
|
|
559 |
def __init__(self, success=None, se=None,):
|
|
|
560 |
self.success = success
|
|
|
561 |
self.se = se
|
|
|
562 |
|
|
|
563 |
def read(self, iprot):
|
|
|
564 |
if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
565 |
fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
566 |
return
|
|
|
567 |
iprot.readStructBegin()
|
|
|
568 |
while True:
|
|
|
569 |
(fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
570 |
if ftype == TType.STOP:
|
|
|
571 |
break
|
|
|
572 |
if fid == 0:
|
|
|
573 |
if ftype == TType.STRUCT:
|
|
|
574 |
self.success = LogisticsInfo()
|
|
|
575 |
self.success.read(iprot)
|
|
|
576 |
else:
|
|
|
577 |
iprot.skip(ftype)
|
|
|
578 |
elif fid == 1:
|
|
|
579 |
if ftype == TType.STRUCT:
|
|
|
580 |
self.se = LogisticsServiceException()
|
|
|
581 |
self.se.read(iprot)
|
|
|
582 |
else:
|
|
|
583 |
iprot.skip(ftype)
|
|
|
584 |
else:
|
|
|
585 |
iprot.skip(ftype)
|
|
|
586 |
iprot.readFieldEnd()
|
|
|
587 |
iprot.readStructEnd()
|
|
|
588 |
|
|
|
589 |
def write(self, oprot):
|
|
|
590 |
if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
591 |
oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
592 |
return
|
| 647 |
chandransh |
593 |
oprot.writeStructBegin('getLogisticsEstimation_result')
|
| 483 |
rajveer |
594 |
if self.success != None:
|
|
|
595 |
oprot.writeFieldBegin('success', TType.STRUCT, 0)
|
|
|
596 |
self.success.write(oprot)
|
|
|
597 |
oprot.writeFieldEnd()
|
|
|
598 |
if self.se != None:
|
|
|
599 |
oprot.writeFieldBegin('se', TType.STRUCT, 1)
|
|
|
600 |
self.se.write(oprot)
|
|
|
601 |
oprot.writeFieldEnd()
|
|
|
602 |
oprot.writeFieldStop()
|
|
|
603 |
oprot.writeStructEnd()
|
|
|
604 |
|
|
|
605 |
def __repr__(self):
|
|
|
606 |
L = ['%s=%r' % (key, value)
|
|
|
607 |
for key, value in self.__dict__.iteritems()]
|
|
|
608 |
return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
|
|
|
609 |
|
|
|
610 |
def __eq__(self, other):
|
|
|
611 |
return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
612 |
|
|
|
613 |
def __ne__(self, other):
|
|
|
614 |
return not (self == other)
|
|
|
615 |
|
| 647 |
chandransh |
616 |
class getLogisticsInfo_args:
|
| 472 |
rajveer |
617 |
"""
|
|
|
618 |
Attributes:
|
| 647 |
chandransh |
619 |
- destination_pincode
|
|
|
620 |
- item_id
|
| 472 |
rajveer |
621 |
"""
|
|
|
622 |
|
|
|
623 |
thrift_spec = (
|
|
|
624 |
None, # 0
|
| 647 |
chandransh |
625 |
(1, TType.STRING, 'destination_pincode', None, None, ), # 1
|
|
|
626 |
(2, TType.STRING, 'item_id', None, None, ), # 2
|
| 472 |
rajveer |
627 |
)
|
|
|
628 |
|
| 647 |
chandransh |
629 |
def __init__(self, destination_pincode=None, item_id=None,):
|
|
|
630 |
self.destination_pincode = destination_pincode
|
|
|
631 |
self.item_id = item_id
|
| 472 |
rajveer |
632 |
|
|
|
633 |
def read(self, iprot):
|
|
|
634 |
if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
635 |
fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
636 |
return
|
|
|
637 |
iprot.readStructBegin()
|
|
|
638 |
while True:
|
|
|
639 |
(fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
640 |
if ftype == TType.STOP:
|
|
|
641 |
break
|
|
|
642 |
if fid == 1:
|
| 647 |
chandransh |
643 |
if ftype == TType.STRING:
|
|
|
644 |
self.destination_pincode = iprot.readString();
|
| 472 |
rajveer |
645 |
else:
|
|
|
646 |
iprot.skip(ftype)
|
|
|
647 |
elif fid == 2:
|
|
|
648 |
if ftype == TType.STRING:
|
| 647 |
chandransh |
649 |
self.item_id = iprot.readString();
|
| 472 |
rajveer |
650 |
else:
|
|
|
651 |
iprot.skip(ftype)
|
|
|
652 |
else:
|
|
|
653 |
iprot.skip(ftype)
|
|
|
654 |
iprot.readFieldEnd()
|
|
|
655 |
iprot.readStructEnd()
|
|
|
656 |
|
|
|
657 |
def write(self, oprot):
|
|
|
658 |
if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
659 |
oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
660 |
return
|
| 647 |
chandransh |
661 |
oprot.writeStructBegin('getLogisticsInfo_args')
|
|
|
662 |
if self.destination_pincode != None:
|
|
|
663 |
oprot.writeFieldBegin('destination_pincode', TType.STRING, 1)
|
|
|
664 |
oprot.writeString(self.destination_pincode)
|
| 472 |
rajveer |
665 |
oprot.writeFieldEnd()
|
| 647 |
chandransh |
666 |
if self.item_id != None:
|
|
|
667 |
oprot.writeFieldBegin('item_id', TType.STRING, 2)
|
|
|
668 |
oprot.writeString(self.item_id)
|
| 472 |
rajveer |
669 |
oprot.writeFieldEnd()
|
|
|
670 |
oprot.writeFieldStop()
|
|
|
671 |
oprot.writeStructEnd()
|
|
|
672 |
|
|
|
673 |
def __repr__(self):
|
|
|
674 |
L = ['%s=%r' % (key, value)
|
|
|
675 |
for key, value in self.__dict__.iteritems()]
|
|
|
676 |
return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
|
|
|
677 |
|
|
|
678 |
def __eq__(self, other):
|
|
|
679 |
return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
680 |
|
|
|
681 |
def __ne__(self, other):
|
|
|
682 |
return not (self == other)
|
|
|
683 |
|
| 647 |
chandransh |
684 |
class getLogisticsInfo_result:
|
| 472 |
rajveer |
685 |
"""
|
|
|
686 |
Attributes:
|
|
|
687 |
- success
|
|
|
688 |
- se
|
|
|
689 |
"""
|
|
|
690 |
|
|
|
691 |
thrift_spec = (
|
| 644 |
chandransh |
692 |
(0, TType.STRUCT, 'success', (LogisticsInfo, LogisticsInfo.thrift_spec), None, ), # 0
|
| 472 |
rajveer |
693 |
(1, TType.STRUCT, 'se', (LogisticsServiceException, LogisticsServiceException.thrift_spec), None, ), # 1
|
|
|
694 |
)
|
|
|
695 |
|
|
|
696 |
def __init__(self, success=None, se=None,):
|
|
|
697 |
self.success = success
|
|
|
698 |
self.se = se
|
|
|
699 |
|
|
|
700 |
def read(self, iprot):
|
|
|
701 |
if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
702 |
fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
703 |
return
|
|
|
704 |
iprot.readStructBegin()
|
|
|
705 |
while True:
|
|
|
706 |
(fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
707 |
if ftype == TType.STOP:
|
|
|
708 |
break
|
|
|
709 |
if fid == 0:
|
|
|
710 |
if ftype == TType.STRUCT:
|
| 644 |
chandransh |
711 |
self.success = LogisticsInfo()
|
| 472 |
rajveer |
712 |
self.success.read(iprot)
|
|
|
713 |
else:
|
|
|
714 |
iprot.skip(ftype)
|
|
|
715 |
elif fid == 1:
|
|
|
716 |
if ftype == TType.STRUCT:
|
|
|
717 |
self.se = LogisticsServiceException()
|
|
|
718 |
self.se.read(iprot)
|
|
|
719 |
else:
|
|
|
720 |
iprot.skip(ftype)
|
|
|
721 |
else:
|
|
|
722 |
iprot.skip(ftype)
|
|
|
723 |
iprot.readFieldEnd()
|
|
|
724 |
iprot.readStructEnd()
|
|
|
725 |
|
|
|
726 |
def write(self, oprot):
|
|
|
727 |
if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
728 |
oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
729 |
return
|
| 647 |
chandransh |
730 |
oprot.writeStructBegin('getLogisticsInfo_result')
|
| 472 |
rajveer |
731 |
if self.success != None:
|
|
|
732 |
oprot.writeFieldBegin('success', TType.STRUCT, 0)
|
|
|
733 |
self.success.write(oprot)
|
|
|
734 |
oprot.writeFieldEnd()
|
|
|
735 |
if self.se != None:
|
|
|
736 |
oprot.writeFieldBegin('se', TType.STRUCT, 1)
|
|
|
737 |
self.se.write(oprot)
|
|
|
738 |
oprot.writeFieldEnd()
|
|
|
739 |
oprot.writeFieldStop()
|
|
|
740 |
oprot.writeStructEnd()
|
|
|
741 |
|
|
|
742 |
def __repr__(self):
|
|
|
743 |
L = ['%s=%r' % (key, value)
|
|
|
744 |
for key, value in self.__dict__.iteritems()]
|
|
|
745 |
return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
|
|
|
746 |
|
|
|
747 |
def __eq__(self, other):
|
|
|
748 |
return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
749 |
|
|
|
750 |
def __ne__(self, other):
|
|
|
751 |
return not (self == other)
|
|
|
752 |
|
| 412 |
ashish |
753 |
class getEmptyAWB_args:
|
|
|
754 |
"""
|
|
|
755 |
Attributes:
|
| 647 |
chandransh |
756 |
- providerId
|
| 412 |
ashish |
757 |
"""
|
|
|
758 |
|
|
|
759 |
thrift_spec = (
|
|
|
760 |
None, # 0
|
| 647 |
chandransh |
761 |
(1, TType.I64, 'providerId', None, None, ), # 1
|
| 412 |
ashish |
762 |
)
|
|
|
763 |
|
| 647 |
chandransh |
764 |
def __init__(self, providerId=None,):
|
|
|
765 |
self.providerId = providerId
|
| 412 |
ashish |
766 |
|
|
|
767 |
def read(self, iprot):
|
|
|
768 |
if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
769 |
fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
770 |
return
|
|
|
771 |
iprot.readStructBegin()
|
|
|
772 |
while True:
|
|
|
773 |
(fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
774 |
if ftype == TType.STOP:
|
|
|
775 |
break
|
|
|
776 |
if fid == 1:
|
|
|
777 |
if ftype == TType.I64:
|
| 647 |
chandransh |
778 |
self.providerId = iprot.readI64();
|
| 412 |
ashish |
779 |
else:
|
|
|
780 |
iprot.skip(ftype)
|
|
|
781 |
else:
|
|
|
782 |
iprot.skip(ftype)
|
|
|
783 |
iprot.readFieldEnd()
|
|
|
784 |
iprot.readStructEnd()
|
|
|
785 |
|
|
|
786 |
def write(self, oprot):
|
|
|
787 |
if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
788 |
oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
789 |
return
|
|
|
790 |
oprot.writeStructBegin('getEmptyAWB_args')
|
| 647 |
chandransh |
791 |
if self.providerId != None:
|
|
|
792 |
oprot.writeFieldBegin('providerId', TType.I64, 1)
|
|
|
793 |
oprot.writeI64(self.providerId)
|
| 412 |
ashish |
794 |
oprot.writeFieldEnd()
|
|
|
795 |
oprot.writeFieldStop()
|
|
|
796 |
oprot.writeStructEnd()
|
|
|
797 |
|
|
|
798 |
def __repr__(self):
|
|
|
799 |
L = ['%s=%r' % (key, value)
|
|
|
800 |
for key, value in self.__dict__.iteritems()]
|
|
|
801 |
return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
|
|
|
802 |
|
|
|
803 |
def __eq__(self, other):
|
|
|
804 |
return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
805 |
|
|
|
806 |
def __ne__(self, other):
|
|
|
807 |
return not (self == other)
|
|
|
808 |
|
|
|
809 |
class getEmptyAWB_result:
|
|
|
810 |
"""
|
|
|
811 |
Attributes:
|
|
|
812 |
- success
|
| 647 |
chandransh |
813 |
- se
|
| 412 |
ashish |
814 |
"""
|
|
|
815 |
|
|
|
816 |
thrift_spec = (
|
|
|
817 |
(0, TType.STRING, 'success', None, None, ), # 0
|
| 647 |
chandransh |
818 |
(1, TType.STRUCT, 'se', (LogisticsServiceException, LogisticsServiceException.thrift_spec), None, ), # 1
|
| 412 |
ashish |
819 |
)
|
|
|
820 |
|
| 647 |
chandransh |
821 |
def __init__(self, success=None, se=None,):
|
| 412 |
ashish |
822 |
self.success = success
|
| 647 |
chandransh |
823 |
self.se = se
|
| 412 |
ashish |
824 |
|
|
|
825 |
def read(self, iprot):
|
|
|
826 |
if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
827 |
fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
828 |
return
|
|
|
829 |
iprot.readStructBegin()
|
|
|
830 |
while True:
|
|
|
831 |
(fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
832 |
if ftype == TType.STOP:
|
|
|
833 |
break
|
|
|
834 |
if fid == 0:
|
|
|
835 |
if ftype == TType.STRING:
|
|
|
836 |
self.success = iprot.readString();
|
|
|
837 |
else:
|
|
|
838 |
iprot.skip(ftype)
|
| 647 |
chandransh |
839 |
elif fid == 1:
|
|
|
840 |
if ftype == TType.STRUCT:
|
|
|
841 |
self.se = LogisticsServiceException()
|
|
|
842 |
self.se.read(iprot)
|
|
|
843 |
else:
|
|
|
844 |
iprot.skip(ftype)
|
| 412 |
ashish |
845 |
else:
|
|
|
846 |
iprot.skip(ftype)
|
|
|
847 |
iprot.readFieldEnd()
|
|
|
848 |
iprot.readStructEnd()
|
|
|
849 |
|
|
|
850 |
def write(self, oprot):
|
|
|
851 |
if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
852 |
oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
853 |
return
|
|
|
854 |
oprot.writeStructBegin('getEmptyAWB_result')
|
|
|
855 |
if self.success != None:
|
|
|
856 |
oprot.writeFieldBegin('success', TType.STRING, 0)
|
|
|
857 |
oprot.writeString(self.success)
|
|
|
858 |
oprot.writeFieldEnd()
|
| 647 |
chandransh |
859 |
if self.se != None:
|
|
|
860 |
oprot.writeFieldBegin('se', TType.STRUCT, 1)
|
|
|
861 |
self.se.write(oprot)
|
|
|
862 |
oprot.writeFieldEnd()
|
| 412 |
ashish |
863 |
oprot.writeFieldStop()
|
|
|
864 |
oprot.writeStructEnd()
|
|
|
865 |
|
|
|
866 |
def __repr__(self):
|
|
|
867 |
L = ['%s=%r' % (key, value)
|
|
|
868 |
for key, value in self.__dict__.iteritems()]
|
|
|
869 |
return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
|
|
|
870 |
|
|
|
871 |
def __eq__(self, other):
|
|
|
872 |
return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
873 |
|
|
|
874 |
def __ne__(self, other):
|
|
|
875 |
return not (self == other)
|
|
|
876 |
|
|
|
877 |
class getShipmentInfo_args:
|
|
|
878 |
"""
|
|
|
879 |
Attributes:
|
|
|
880 |
- awb
|
| 647 |
chandransh |
881 |
- providerId
|
| 412 |
ashish |
882 |
"""
|
|
|
883 |
|
|
|
884 |
thrift_spec = (
|
|
|
885 |
None, # 0
|
|
|
886 |
(1, TType.STRING, 'awb', None, None, ), # 1
|
| 647 |
chandransh |
887 |
(2, TType.I64, 'providerId', None, None, ), # 2
|
| 412 |
ashish |
888 |
)
|
|
|
889 |
|
| 647 |
chandransh |
890 |
def __init__(self, awb=None, providerId=None,):
|
| 412 |
ashish |
891 |
self.awb = awb
|
| 647 |
chandransh |
892 |
self.providerId = providerId
|
| 412 |
ashish |
893 |
|
|
|
894 |
def read(self, iprot):
|
|
|
895 |
if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
896 |
fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
897 |
return
|
|
|
898 |
iprot.readStructBegin()
|
|
|
899 |
while True:
|
|
|
900 |
(fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
901 |
if ftype == TType.STOP:
|
|
|
902 |
break
|
|
|
903 |
if fid == 1:
|
|
|
904 |
if ftype == TType.STRING:
|
|
|
905 |
self.awb = iprot.readString();
|
|
|
906 |
else:
|
|
|
907 |
iprot.skip(ftype)
|
| 647 |
chandransh |
908 |
elif fid == 2:
|
|
|
909 |
if ftype == TType.I64:
|
|
|
910 |
self.providerId = iprot.readI64();
|
|
|
911 |
else:
|
|
|
912 |
iprot.skip(ftype)
|
| 412 |
ashish |
913 |
else:
|
|
|
914 |
iprot.skip(ftype)
|
|
|
915 |
iprot.readFieldEnd()
|
|
|
916 |
iprot.readStructEnd()
|
|
|
917 |
|
|
|
918 |
def write(self, oprot):
|
|
|
919 |
if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
920 |
oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
921 |
return
|
|
|
922 |
oprot.writeStructBegin('getShipmentInfo_args')
|
|
|
923 |
if self.awb != None:
|
|
|
924 |
oprot.writeFieldBegin('awb', TType.STRING, 1)
|
|
|
925 |
oprot.writeString(self.awb)
|
|
|
926 |
oprot.writeFieldEnd()
|
| 647 |
chandransh |
927 |
if self.providerId != None:
|
|
|
928 |
oprot.writeFieldBegin('providerId', TType.I64, 2)
|
|
|
929 |
oprot.writeI64(self.providerId)
|
|
|
930 |
oprot.writeFieldEnd()
|
| 412 |
ashish |
931 |
oprot.writeFieldStop()
|
|
|
932 |
oprot.writeStructEnd()
|
|
|
933 |
|
|
|
934 |
def __repr__(self):
|
|
|
935 |
L = ['%s=%r' % (key, value)
|
|
|
936 |
for key, value in self.__dict__.iteritems()]
|
|
|
937 |
return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
|
|
|
938 |
|
|
|
939 |
def __eq__(self, other):
|
|
|
940 |
return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
941 |
|
|
|
942 |
def __ne__(self, other):
|
|
|
943 |
return not (self == other)
|
|
|
944 |
|
|
|
945 |
class getShipmentInfo_result:
|
|
|
946 |
"""
|
|
|
947 |
Attributes:
|
|
|
948 |
- success
|
| 647 |
chandransh |
949 |
- se
|
| 412 |
ashish |
950 |
"""
|
|
|
951 |
|
|
|
952 |
thrift_spec = (
|
| 644 |
chandransh |
953 |
(0, TType.LIST, 'success', (TType.STRUCT,(AwbUpdate, AwbUpdate.thrift_spec)), None, ), # 0
|
| 647 |
chandransh |
954 |
(1, TType.STRUCT, 'se', (LogisticsServiceException, LogisticsServiceException.thrift_spec), None, ), # 1
|
| 412 |
ashish |
955 |
)
|
|
|
956 |
|
| 647 |
chandransh |
957 |
def __init__(self, success=None, se=None,):
|
| 412 |
ashish |
958 |
self.success = success
|
| 647 |
chandransh |
959 |
self.se = se
|
| 412 |
ashish |
960 |
|
|
|
961 |
def read(self, iprot):
|
|
|
962 |
if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
963 |
fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
964 |
return
|
|
|
965 |
iprot.readStructBegin()
|
|
|
966 |
while True:
|
|
|
967 |
(fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
968 |
if ftype == TType.STOP:
|
|
|
969 |
break
|
|
|
970 |
if fid == 0:
|
|
|
971 |
if ftype == TType.LIST:
|
|
|
972 |
self.success = []
|
| 644 |
chandransh |
973 |
(_etype3, _size0) = iprot.readListBegin()
|
|
|
974 |
for _i4 in xrange(_size0):
|
|
|
975 |
_elem5 = AwbUpdate()
|
|
|
976 |
_elem5.read(iprot)
|
|
|
977 |
self.success.append(_elem5)
|
| 412 |
ashish |
978 |
iprot.readListEnd()
|
|
|
979 |
else:
|
|
|
980 |
iprot.skip(ftype)
|
| 647 |
chandransh |
981 |
elif fid == 1:
|
|
|
982 |
if ftype == TType.STRUCT:
|
|
|
983 |
self.se = LogisticsServiceException()
|
|
|
984 |
self.se.read(iprot)
|
|
|
985 |
else:
|
|
|
986 |
iprot.skip(ftype)
|
| 412 |
ashish |
987 |
else:
|
|
|
988 |
iprot.skip(ftype)
|
|
|
989 |
iprot.readFieldEnd()
|
|
|
990 |
iprot.readStructEnd()
|
|
|
991 |
|
|
|
992 |
def write(self, oprot):
|
|
|
993 |
if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
994 |
oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
995 |
return
|
| 644 |
chandransh |
996 |
oprot.writeStructBegin('getShipmentInfo_result')
|
| 412 |
ashish |
997 |
if self.success != None:
|
|
|
998 |
oprot.writeFieldBegin('success', TType.LIST, 0)
|
|
|
999 |
oprot.writeListBegin(TType.STRUCT, len(self.success))
|
| 644 |
chandransh |
1000 |
for iter6 in self.success:
|
|
|
1001 |
iter6.write(oprot)
|
| 412 |
ashish |
1002 |
oprot.writeListEnd()
|
|
|
1003 |
oprot.writeFieldEnd()
|
| 647 |
chandransh |
1004 |
if self.se != None:
|
|
|
1005 |
oprot.writeFieldBegin('se', TType.STRUCT, 1)
|
|
|
1006 |
self.se.write(oprot)
|
|
|
1007 |
oprot.writeFieldEnd()
|
| 412 |
ashish |
1008 |
oprot.writeFieldStop()
|
|
|
1009 |
oprot.writeStructEnd()
|
|
|
1010 |
|
|
|
1011 |
def __repr__(self):
|
|
|
1012 |
L = ['%s=%r' % (key, value)
|
|
|
1013 |
for key, value in self.__dict__.iteritems()]
|
|
|
1014 |
return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
|
|
|
1015 |
|
|
|
1016 |
def __eq__(self, other):
|
|
|
1017 |
return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
1018 |
|
|
|
1019 |
def __ne__(self, other):
|
|
|
1020 |
return not (self == other)
|
|
|
1021 |
|
|
|
1022 |
|