Subversion Repositories SmartDukaan

Rev

Rev 9724 | Rev 9779 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 9724 Rev 9776
Line 1008... Line 1008...
1008
    Parameters:
1008
    Parameters:
1009
     - marketPlaceItem
1009
     - marketPlaceItem
1010
    """
1010
    """
1011
    pass
1011
    pass
1012
 
1012
 
-
 
1013
  def getMarketPlaceItemsForPriceUpdate(self, source):
-
 
1014
    """
-
 
1015
    Parameters:
-
 
1016
     - source
-
 
1017
    """
-
 
1018
    pass
-
 
1019
 
-
 
1020
  def updateMarketPlacePriceUpdateStatus(self, skulist, timestamp):
-
 
1021
    """
-
 
1022
    Parameters:
-
 
1023
     - skulist
-
 
1024
     - timestamp
-
 
1025
    """
-
 
1026
    pass
-
 
1027
 
1013
 
1028
 
1014
class Client(shop2020.thriftpy.generic.GenericService.Client, Iface):
1029
class Client(shop2020.thriftpy.generic.GenericService.Client, Iface):
1015
  def __init__(self, iprot, oprot=None):
1030
  def __init__(self, iprot, oprot=None):
1016
    shop2020.thriftpy.generic.GenericService.Client.__init__(self, iprot, oprot)
1031
    shop2020.thriftpy.generic.GenericService.Client.__init__(self, iprot, oprot)
1017
 
1032
 
Line 5286... Line 5301...
5286
    self._iprot.readMessageEnd()
5301
    self._iprot.readMessageEnd()
5287
    if result.success is not None:
5302
    if result.success is not None:
5288
      return result.success
5303
      return result.success
5289
    raise TApplicationException(TApplicationException.MISSING_RESULT, "updateMarketplaceAttributesForItem failed: unknown result");
5304
    raise TApplicationException(TApplicationException.MISSING_RESULT, "updateMarketplaceAttributesForItem failed: unknown result");
5290
 
5305
 
-
 
5306
  def getMarketPlaceItemsForPriceUpdate(self, source):
-
 
5307
    """
-
 
5308
    Parameters:
-
 
5309
     - source
-
 
5310
    """
-
 
5311
    self.send_getMarketPlaceItemsForPriceUpdate(source)
-
 
5312
    return self.recv_getMarketPlaceItemsForPriceUpdate()
-
 
5313
 
-
 
5314
  def send_getMarketPlaceItemsForPriceUpdate(self, source):
-
 
5315
    self._oprot.writeMessageBegin('getMarketPlaceItemsForPriceUpdate', TMessageType.CALL, self._seqid)
-
 
5316
    args = getMarketPlaceItemsForPriceUpdate_args()
-
 
5317
    args.source = source
-
 
5318
    args.write(self._oprot)
-
 
5319
    self._oprot.writeMessageEnd()
-
 
5320
    self._oprot.trans.flush()
-
 
5321
 
-
 
5322
  def recv_getMarketPlaceItemsForPriceUpdate(self, ):
-
 
5323
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
-
 
5324
    if mtype == TMessageType.EXCEPTION:
-
 
5325
      x = TApplicationException()
-
 
5326
      x.read(self._iprot)
-
 
5327
      self._iprot.readMessageEnd()
-
 
5328
      raise x
-
 
5329
    result = getMarketPlaceItemsForPriceUpdate_result()
-
 
5330
    result.read(self._iprot)
-
 
5331
    self._iprot.readMessageEnd()
-
 
5332
    if result.success is not None:
-
 
5333
      return result.success
-
 
5334
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getMarketPlaceItemsForPriceUpdate failed: unknown result");
-
 
5335
 
-
 
5336
  def updateMarketPlacePriceUpdateStatus(self, skulist, timestamp):
-
 
5337
    """
-
 
5338
    Parameters:
-
 
5339
     - skulist
-
 
5340
     - timestamp
-
 
5341
    """
-
 
5342
    self.send_updateMarketPlacePriceUpdateStatus(skulist, timestamp)
-
 
5343
    self.recv_updateMarketPlacePriceUpdateStatus()
-
 
5344
 
-
 
5345
  def send_updateMarketPlacePriceUpdateStatus(self, skulist, timestamp):
-
 
5346
    self._oprot.writeMessageBegin('updateMarketPlacePriceUpdateStatus', TMessageType.CALL, self._seqid)
-
 
5347
    args = updateMarketPlacePriceUpdateStatus_args()
-
 
5348
    args.skulist = skulist
-
 
5349
    args.timestamp = timestamp
-
 
5350
    args.write(self._oprot)
-
 
5351
    self._oprot.writeMessageEnd()
-
 
5352
    self._oprot.trans.flush()
-
 
5353
 
-
 
5354
  def recv_updateMarketPlacePriceUpdateStatus(self, ):
-
 
5355
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
-
 
5356
    if mtype == TMessageType.EXCEPTION:
-
 
5357
      x = TApplicationException()
-
 
5358
      x.read(self._iprot)
-
 
5359
      self._iprot.readMessageEnd()
-
 
5360
      raise x
-
 
5361
    result = updateMarketPlacePriceUpdateStatus_result()
-
 
5362
    result.read(self._iprot)
-
 
5363
    self._iprot.readMessageEnd()
-
 
5364
    return
-
 
5365
 
5291
 
5366
 
5292
class Processor(shop2020.thriftpy.generic.GenericService.Processor, Iface, TProcessor):
5367
class Processor(shop2020.thriftpy.generic.GenericService.Processor, Iface, TProcessor):
5293
  def __init__(self, handler):
5368
  def __init__(self, handler):
5294
    shop2020.thriftpy.generic.GenericService.Processor.__init__(self, handler)
5369
    shop2020.thriftpy.generic.GenericService.Processor.__init__(self, handler)
5295
    self._processMap["addItem"] = Processor.process_addItem
5370
    self._processMap["addItem"] = Processor.process_addItem
Line 5429... Line 5504...
5429
    self._processMap["updateProductFeedSubmit"] = Processor.process_updateProductFeedSubmit
5504
    self._processMap["updateProductFeedSubmit"] = Processor.process_updateProductFeedSubmit
5430
    self._processMap["deleteProductFeedSubmit"] = Processor.process_deleteProductFeedSubmit
5505
    self._processMap["deleteProductFeedSubmit"] = Processor.process_deleteProductFeedSubmit
5431
    self._processMap["getAllProductFeedSubmit"] = Processor.process_getAllProductFeedSubmit
5506
    self._processMap["getAllProductFeedSubmit"] = Processor.process_getAllProductFeedSubmit
5432
    self._processMap["getMarketplacedetailsForItem"] = Processor.process_getMarketplacedetailsForItem
5507
    self._processMap["getMarketplacedetailsForItem"] = Processor.process_getMarketplacedetailsForItem
5433
    self._processMap["updateMarketplaceAttributesForItem"] = Processor.process_updateMarketplaceAttributesForItem
5508
    self._processMap["updateMarketplaceAttributesForItem"] = Processor.process_updateMarketplaceAttributesForItem
-
 
5509
    self._processMap["getMarketPlaceItemsForPriceUpdate"] = Processor.process_getMarketPlaceItemsForPriceUpdate
-
 
5510
    self._processMap["updateMarketPlacePriceUpdateStatus"] = Processor.process_updateMarketPlacePriceUpdateStatus
5434
 
5511
 
5435
  def process(self, iprot, oprot):
5512
  def process(self, iprot, oprot):
5436
    (name, type, seqid) = iprot.readMessageBegin()
5513
    (name, type, seqid) = iprot.readMessageBegin()
5437
    if name not in self._processMap:
5514
    if name not in self._processMap:
5438
      iprot.skip(TType.STRUCT)
5515
      iprot.skip(TType.STRUCT)
Line 7103... Line 7180...
7103
    oprot.writeMessageBegin("updateMarketplaceAttributesForItem", TMessageType.REPLY, seqid)
7180
    oprot.writeMessageBegin("updateMarketplaceAttributesForItem", TMessageType.REPLY, seqid)
7104
    result.write(oprot)
7181
    result.write(oprot)
7105
    oprot.writeMessageEnd()
7182
    oprot.writeMessageEnd()
7106
    oprot.trans.flush()
7183
    oprot.trans.flush()
7107
 
7184
 
-
 
7185
  def process_getMarketPlaceItemsForPriceUpdate(self, seqid, iprot, oprot):
-
 
7186
    args = getMarketPlaceItemsForPriceUpdate_args()
-
 
7187
    args.read(iprot)
-
 
7188
    iprot.readMessageEnd()
-
 
7189
    result = getMarketPlaceItemsForPriceUpdate_result()
-
 
7190
    result.success = self._handler.getMarketPlaceItemsForPriceUpdate(args.source)
-
 
7191
    oprot.writeMessageBegin("getMarketPlaceItemsForPriceUpdate", TMessageType.REPLY, seqid)
-
 
7192
    result.write(oprot)
-
 
7193
    oprot.writeMessageEnd()
-
 
7194
    oprot.trans.flush()
-
 
7195
 
-
 
7196
  def process_updateMarketPlacePriceUpdateStatus(self, seqid, iprot, oprot):
-
 
7197
    args = updateMarketPlacePriceUpdateStatus_args()
-
 
7198
    args.read(iprot)
-
 
7199
    iprot.readMessageEnd()
-
 
7200
    result = updateMarketPlacePriceUpdateStatus_result()
-
 
7201
    self._handler.updateMarketPlacePriceUpdateStatus(args.skulist, args.timestamp)
-
 
7202
    oprot.writeMessageBegin("updateMarketPlacePriceUpdateStatus", TMessageType.REPLY, seqid)
-
 
7203
    result.write(oprot)
-
 
7204
    oprot.writeMessageEnd()
-
 
7205
    oprot.trans.flush()
-
 
7206
 
7108
 
7207
 
7109
# HELPER FUNCTIONS AND STRUCTURES
7208
# HELPER FUNCTIONS AND STRUCTURES
7110
 
7209
 
7111
class addItem_args:
7210
class addItem_args:
7112
  """
7211
  """
Line 24794... Line 24893...
24794
    oprot.writeFieldStop()
24893
    oprot.writeFieldStop()
24795
    oprot.writeStructEnd()
24894
    oprot.writeStructEnd()
24796
 
24895
 
24797
  def validate(self):
24896
  def validate(self):
24798
    return
24897
    return
-
 
24898
 
-
 
24899
 
-
 
24900
  def __repr__(self):
-
 
24901
    L = ['%s=%r' % (key, value)
-
 
24902
      for key, value in self.__dict__.iteritems()]
-
 
24903
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
 
24904
 
-
 
24905
  def __eq__(self, other):
-
 
24906
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
 
24907
 
-
 
24908
  def __ne__(self, other):
-
 
24909
    return not (self == other)
-
 
24910
 
-
 
24911
class getMarketPlaceItemsForPriceUpdate_args:
-
 
24912
  """
-
 
24913
  Attributes:
-
 
24914
   - source
-
 
24915
  """
-
 
24916
 
-
 
24917
  thrift_spec = (
-
 
24918
    None, # 0
-
 
24919
    (1, TType.I64, 'source', None, None, ), # 1
-
 
24920
  )
-
 
24921
 
-
 
24922
  def __init__(self, source=None,):
-
 
24923
    self.source = source
-
 
24924
 
-
 
24925
  def read(self, iprot):
-
 
24926
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
-
 
24927
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
-
 
24928
      return
-
 
24929
    iprot.readStructBegin()
-
 
24930
    while True:
-
 
24931
      (fname, ftype, fid) = iprot.readFieldBegin()
-
 
24932
      if ftype == TType.STOP:
-
 
24933
        break
-
 
24934
      if fid == 1:
-
 
24935
        if ftype == TType.I64:
-
 
24936
          self.source = iprot.readI64();
-
 
24937
        else:
-
 
24938
          iprot.skip(ftype)
-
 
24939
      else:
-
 
24940
        iprot.skip(ftype)
-
 
24941
      iprot.readFieldEnd()
-
 
24942
    iprot.readStructEnd()
-
 
24943
 
-
 
24944
  def write(self, oprot):
-
 
24945
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
-
 
24946
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
-
 
24947
      return
-
 
24948
    oprot.writeStructBegin('getMarketPlaceItemsForPriceUpdate_args')
-
 
24949
    if self.source is not None:
-
 
24950
      oprot.writeFieldBegin('source', TType.I64, 1)
-
 
24951
      oprot.writeI64(self.source)
-
 
24952
      oprot.writeFieldEnd()
-
 
24953
    oprot.writeFieldStop()
-
 
24954
    oprot.writeStructEnd()
-
 
24955
 
-
 
24956
  def validate(self):
-
 
24957
    return
-
 
24958
 
-
 
24959
 
-
 
24960
  def __repr__(self):
-
 
24961
    L = ['%s=%r' % (key, value)
-
 
24962
      for key, value in self.__dict__.iteritems()]
-
 
24963
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
 
24964
 
-
 
24965
  def __eq__(self, other):
-
 
24966
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
 
24967
 
-
 
24968
  def __ne__(self, other):
-
 
24969
    return not (self == other)
-
 
24970
 
-
 
24971
class getMarketPlaceItemsForPriceUpdate_result:
-
 
24972
  """
-
 
24973
  Attributes:
-
 
24974
   - success
-
 
24975
  """
-
 
24976
 
-
 
24977
  thrift_spec = (
-
 
24978
    (0, TType.LIST, 'success', (TType.STRUCT,(MarketPlaceItemPrice, MarketPlaceItemPrice.thrift_spec)), None, ), # 0
-
 
24979
  )
-
 
24980
 
-
 
24981
  def __init__(self, success=None,):
-
 
24982
    self.success = success
-
 
24983
 
-
 
24984
  def read(self, iprot):
-
 
24985
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
-
 
24986
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
-
 
24987
      return
-
 
24988
    iprot.readStructBegin()
-
 
24989
    while True:
-
 
24990
      (fname, ftype, fid) = iprot.readFieldBegin()
-
 
24991
      if ftype == TType.STOP:
-
 
24992
        break
-
 
24993
      if fid == 0:
-
 
24994
        if ftype == TType.LIST:
-
 
24995
          self.success = []
-
 
24996
          (_etype558, _size555) = iprot.readListBegin()
-
 
24997
          for _i559 in xrange(_size555):
-
 
24998
            _elem560 = MarketPlaceItemPrice()
-
 
24999
            _elem560.read(iprot)
-
 
25000
            self.success.append(_elem560)
-
 
25001
          iprot.readListEnd()
-
 
25002
        else:
-
 
25003
          iprot.skip(ftype)
-
 
25004
      else:
-
 
25005
        iprot.skip(ftype)
-
 
25006
      iprot.readFieldEnd()
-
 
25007
    iprot.readStructEnd()
-
 
25008
 
-
 
25009
  def write(self, oprot):
-
 
25010
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
-
 
25011
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
-
 
25012
      return
-
 
25013
    oprot.writeStructBegin('getMarketPlaceItemsForPriceUpdate_result')
-
 
25014
    if self.success is not None:
-
 
25015
      oprot.writeFieldBegin('success', TType.LIST, 0)
-
 
25016
      oprot.writeListBegin(TType.STRUCT, len(self.success))
-
 
25017
      for iter561 in self.success:
-
 
25018
        iter561.write(oprot)
-
 
25019
      oprot.writeListEnd()
-
 
25020
      oprot.writeFieldEnd()
-
 
25021
    oprot.writeFieldStop()
-
 
25022
    oprot.writeStructEnd()
-
 
25023
 
-
 
25024
  def validate(self):
-
 
25025
    return
-
 
25026
 
-
 
25027
 
-
 
25028
  def __repr__(self):
-
 
25029
    L = ['%s=%r' % (key, value)
-
 
25030
      for key, value in self.__dict__.iteritems()]
-
 
25031
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
 
25032
 
-
 
25033
  def __eq__(self, other):
-
 
25034
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
 
25035
 
-
 
25036
  def __ne__(self, other):
-
 
25037
    return not (self == other)
-
 
25038
 
-
 
25039
class updateMarketPlacePriceUpdateStatus_args:
-
 
25040
  """
-
 
25041
  Attributes:
-
 
25042
   - skulist
-
 
25043
   - timestamp
-
 
25044
  """
-
 
25045
 
-
 
25046
  thrift_spec = (
-
 
25047
    None, # 0
-
 
25048
    (1, TType.LIST, 'skulist', (TType.I64,None), None, ), # 1
-
 
25049
    (2, TType.I64, 'timestamp', None, None, ), # 2
-
 
25050
  )
-
 
25051
 
-
 
25052
  def __init__(self, skulist=None, timestamp=None,):
-
 
25053
    self.skulist = skulist
-
 
25054
    self.timestamp = timestamp
-
 
25055
 
-
 
25056
  def read(self, iprot):
-
 
25057
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
-
 
25058
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
-
 
25059
      return
-
 
25060
    iprot.readStructBegin()
-
 
25061
    while True:
-
 
25062
      (fname, ftype, fid) = iprot.readFieldBegin()
-
 
25063
      if ftype == TType.STOP:
-
 
25064
        break
-
 
25065
      if fid == 1:
-
 
25066
        if ftype == TType.LIST:
-
 
25067
          self.skulist = []
-
 
25068
          (_etype565, _size562) = iprot.readListBegin()
-
 
25069
          for _i566 in xrange(_size562):
-
 
25070
            _elem567 = iprot.readI64();
-
 
25071
            self.skulist.append(_elem567)
-
 
25072
          iprot.readListEnd()
-
 
25073
        else:
-
 
25074
          iprot.skip(ftype)
-
 
25075
      elif fid == 2:
-
 
25076
        if ftype == TType.I64:
-
 
25077
          self.timestamp = iprot.readI64();
-
 
25078
        else:
-
 
25079
          iprot.skip(ftype)
-
 
25080
      else:
-
 
25081
        iprot.skip(ftype)
-
 
25082
      iprot.readFieldEnd()
-
 
25083
    iprot.readStructEnd()
-
 
25084
 
-
 
25085
  def write(self, oprot):
-
 
25086
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
-
 
25087
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
-
 
25088
      return
-
 
25089
    oprot.writeStructBegin('updateMarketPlacePriceUpdateStatus_args')
-
 
25090
    if self.skulist is not None:
-
 
25091
      oprot.writeFieldBegin('skulist', TType.LIST, 1)
-
 
25092
      oprot.writeListBegin(TType.I64, len(self.skulist))
-
 
25093
      for iter568 in self.skulist:
-
 
25094
        oprot.writeI64(iter568)
-
 
25095
      oprot.writeListEnd()
-
 
25096
      oprot.writeFieldEnd()
-
 
25097
    if self.timestamp is not None:
-
 
25098
      oprot.writeFieldBegin('timestamp', TType.I64, 2)
-
 
25099
      oprot.writeI64(self.timestamp)
-
 
25100
      oprot.writeFieldEnd()
-
 
25101
    oprot.writeFieldStop()
-
 
25102
    oprot.writeStructEnd()
-
 
25103
 
-
 
25104
  def validate(self):
-
 
25105
    return
-
 
25106
 
-
 
25107
 
-
 
25108
  def __repr__(self):
-
 
25109
    L = ['%s=%r' % (key, value)
-
 
25110
      for key, value in self.__dict__.iteritems()]
-
 
25111
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
 
25112
 
-
 
25113
  def __eq__(self, other):
-
 
25114
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
 
25115
 
-
 
25116
  def __ne__(self, other):
-
 
25117
    return not (self == other)
-
 
25118
 
-
 
25119
class updateMarketPlacePriceUpdateStatus_result:
-
 
25120
 
-
 
25121
  thrift_spec = (
-
 
25122
  )
-
 
25123
 
-
 
25124
  def read(self, iprot):
-
 
25125
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
-
 
25126
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
-
 
25127
      return
-
 
25128
    iprot.readStructBegin()
-
 
25129
    while True:
-
 
25130
      (fname, ftype, fid) = iprot.readFieldBegin()
-
 
25131
      if ftype == TType.STOP:
-
 
25132
        break
-
 
25133
      else:
-
 
25134
        iprot.skip(ftype)
-
 
25135
      iprot.readFieldEnd()
-
 
25136
    iprot.readStructEnd()
-
 
25137
 
-
 
25138
  def write(self, oprot):
-
 
25139
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
-
 
25140
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
-
 
25141
      return
-
 
25142
    oprot.writeStructBegin('updateMarketPlacePriceUpdateStatus_result')
-
 
25143
    oprot.writeFieldStop()
-
 
25144
    oprot.writeStructEnd()
-
 
25145
 
-
 
25146
  def validate(self):
-
 
25147
    return
24799
 
25148
 
24800
 
25149
 
24801
  def __repr__(self):
25150
  def __repr__(self):
24802
    L = ['%s=%r' % (key, value)
25151
    L = ['%s=%r' % (key, value)
24803
      for key, value in self.__dict__.iteritems()]
25152
      for key, value in self.__dict__.iteritems()]