Subversion Repositories SmartDukaan

Rev

Rev 22364 | Blame | Compare with Previous | Last modification | View Log | RSS feed

#
# Autogenerated by Thrift Compiler (0.7.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#

from thrift.Thrift import *
import shop2020.thriftpy.generic.GenericService
from ttypes import *
from thrift.Thrift import TProcessor
from thrift.transport import TTransport
from thrift.protocol import TBinaryProtocol, TProtocol
try:
  from thrift.protocol import fastbinary
except:
  fastbinary = None


class Iface(shop2020.thriftpy.generic.GenericService.Iface):
  """
  service
  """
  def createAnonymousUser(self, jsessionId):
    """
    Parameters:
     - jsessionId
    """
    pass

  def getUserById(self, userId):
    """
    Parameters:
     - userId
    """
    pass

  def getUserByCartId(self, cartId):
    """
    Parameters:
     - cartId
    """
    pass

  def getUserByEmail(self, email):
    """
    Parameters:
     - email
    """
    pass

  def getUserByMobileNumber(self, mobileNumber):
    """
    Parameters:
     - mobileNumber
    """
    pass

  def createUser(self, user):
    """
    Parameters:
     - user
    """
    pass

  def updateUser(self, user):
    """
    Parameters:
     - user
    """
    pass

  def authenticateUser(self, email, password):
    """
    Parameters:
     - email
     - password
    """
    pass

  def userExists(self, email):
    """
    Parameters:
     - email
    """
    pass

  def addAddressForUser(self, userId, address, setDefault):
    """
    Parameters:
     - userId
     - address
     - setDefault
    """
    pass

  def removeAddressForUser(self, userid, addressId):
    """
    Parameters:
     - userid
     - addressId
    """
    pass

  def updateAddress(self, address):
    """
    Parameters:
     - address
    """
    pass

  def updateCounter(self, counter):
    """
    Parameters:
     - counter
    """
    pass

  def setUserAsLoggedIn(self, userId, timestamp):
    """
    Parameters:
     - userId
     - timestamp
    """
    pass

  def setUserAsLoggedOut(self, userid, timestamp):
    """
    Parameters:
     - userid
     - timestamp
    """
    pass

  def setDefaultAddress(self, userid, addressId):
    """
    Parameters:
     - userid
     - addressId
    """
    pass

  def updatePassword(self, userid, oldPassword, newPassword):
    """
    Parameters:
     - userid
     - oldPassword
     - newPassword
    """
    pass

  def forgotPassword(self, email, newPassword):
    """
    Parameters:
     - email
     - newPassword
    """
    pass

  def getAllAddressesForUser(self, userId):
    """
    Parameters:
     - userId
    """
    pass

  def getAddressById(self, addressId):
    """
    Parameters:
     - addressId
    """
    pass

  def getDefaultAddressId(self, userId):
    """
    Parameters:
     - userId
    """
    pass

  def getDefaultPincode(self, userId):
    """
    Parameters:
     - userId
    """
    pass

  def saveUserCommunication(self, userId, replyTo, communicationType, orderId, airwaybillNo, productName, subject, message):
    """
    Parameters:
     - userId
     - replyTo
     - communicationType
     - orderId
     - airwaybillNo
     - productName
     - subject
     - message
    """
    pass

  def getUserCommunicationById(self, id):
    """
    Parameters:
     - id
    """
    pass

  def getUserCommunicationByUser(self, userId):
    """
    Parameters:
     - userId
    """
    pass

  def getAllUserCommunications(self, ):
    pass

  def removeUserCommunication(self, id):
    """
    Parameters:
     - id
    """
    pass

  def createMasterAffiliate(self, name, addedOn):
    """
    Parameters:
     - name
     - addedOn
    """
    pass

  def getAllMasterAffiliates(self, ):
    pass

  def getMasterAffiliateById(self, id):
    """
    Parameters:
     - id
    """
    pass

  def getMasterAffiliateByName(self, name):
    """
    Parameters:
     - name
    """
    pass

  def createAffiliate(self, name, url, masterAffiliateId, addedOn):
    """
    Parameters:
     - name
     - url
     - masterAffiliateId
     - addedOn
    """
    pass

  def getAffiliateById(self, id):
    """
    Parameters:
     - id
    """
    pass

  def getAffiliateByName(self, name):
    """
    Parameters:
     - name
    """
    pass

  def getTrackerById(self, id):
    """
    Parameters:
     - id
    """
    pass

  def getAffiliatesByMasterAffiliate(self, id):
    """
    Parameters:
     - id
    """
    pass

  def addTrackLog(self, affiliateId, userId, event, url, data, addedOn):
    """
    Parameters:
     - affiliateId
     - userId
     - event
     - url
     - data
     - addedOn
    """
    pass

  def getTrackLogById(self, id):
    """
    Parameters:
     - id
    """
    pass

  def getTrackLogsByAffiliate(self, affiliateId, startDate, endDate):
    """
    Parameters:
     - affiliateId
     - startDate
     - endDate
    """
    pass

  def getTrackLogsByUser(self, userId):
    """
    Parameters:
     - userId
    """
    pass

  def getTrackLogs(self, userId, event, url):
    """
    Parameters:
     - userId
     - event
     - url
    """
    pass

  def getCurrentCart(self, userId):
    """
    Parameters:
     - userId
    """
    pass

  def getCart(self, cartId):
    """
    Parameters:
     - cartId
    """
    pass

  def getCartsByTime(self, from_time, to_time, status):
    """
    Parameters:
     - from_time
     - to_time
     - status
    """
    pass

  def addItemToCart(self, cartId, itemId, quantity, sourceId):
    """
    Parameters:
     - cartId
     - itemId
     - quantity
     - sourceId
    """
    pass

  def deleteItemFromCart(self, cartId, itemId):
    """
    Parameters:
     - cartId
     - itemId
    """
    pass

  def addAddressToCart(self, cartId, addressId):
    """
    Parameters:
     - cartId
     - addressId
    """
    pass

  def addStoreToCart(self, cartId, storeId):
    """
    Parameters:
     - cartId
     - storeId
    """
    pass

  def applyCouponToCart(self, cart, couponCode):
    """
    Parameters:
     - cart
     - couponCode
    """
    pass

  def removeCoupon(self, cartId):
    """
    Parameters:
     - cartId
    """
    pass

  def deleteDiscountsFromCart(self, cartId):
    """
    Deletes all the discounts associated with the cart

    Parameters:
     - cartId
    """
    pass

  def saveDiscounts(self, discounts):
    """
    Accepts a list of thrift objects of Discount type and saves them

    Parameters:
     - discounts
    """
    pass

  def createOrders(self, cartId, sessionSource, sessionStartTime, firstSource, firstSourceTime, userId, schemeId, orderSource, selfPickup):
    """
    Creates a transaction and multiple orders for the given cart. Returns the transaction ID created.

    Parameters:
     - cartId
     - sessionSource
     - sessionStartTime
     - firstSource
     - firstSourceTime
     - userId
     - schemeId
     - orderSource
     - selfPickup
    """
    pass

  def validateCart(self, cartId, sourceId):
    """
    Validates that:
    1. The checkout timestamp is greater than the updatedOn timestamp.
    2. All of the lines in the cart are active items.
    3. The estimate for any of the lines in cart doesn't change.
    If all three are true, returns empty string; else returns appropriate message.

    Parameters:
     - cartId
     - sourceId
    """
    pass

  def validateCartWithDealerCoupon(self, cartId, sourceId, dealCoupon):
    """
    Validates that:
    1. The checkout timestamp is greater than the updatedOn timestamp.
    2. All of the lines in the cart are active items.
    3. The estimate for any of the lines in cart doesn't change.
    If all three are true, returns empty string; else returns appropriate message.

    Parameters:
     - cartId
     - sourceId
     - dealCoupon
    """
    pass

  def mergeCart(self, fromCartId, toCartId):
    """
    Merges the lines from the first cart into the second cart. Lines with duplicate items are removed.

    Parameters:
     - fromCartId
     - toCartId
    """
    pass

  def checkOut(self, cartId):
    """
    Sets the checkedOutOn timestamp of the cart. Raises an exception if the specified cart can't be found.

    Parameters:
     - cartId
    """
    pass

  def resetCart(self, cartId, items):
    """
    The second parameter is a map of item ids and their quantities which have been successfully processed.
    This methods removes the specified quantiry of the specified item from the cart.

    Parameters:
     - cartId
     - items
    """
    pass

  def getUserCount(self, userType):
    """
    Returns number of registered users.
    If userType = null, then it returns count of all users, including anonymous
    If userType = UserType.ANONYMOUS, then it returns count of anonymous users only
    If userType = UserType.USER, then it returns count of non-anonymous users only

    Parameters:
     - userType
    """
    pass

  def getAllUsers(self, userType, startDate, endDate):
    """
    Returns list of users of type userType who registered between startDate and endDate (both inclusive).
    If any of startDate or endDate is -1, then that filter is ignored.
    If userType is null, then returns all the users, irrespective of anonymous flag


    Parameters:
     - userType
     - startDate
     - endDate
    """
    pass

  def getMyResearchItems(self, userId):
    """
    Returns list of item ids in myresearch for the user

    Parameters:
     - userId
    """
    pass

  def updateMyResearch(self, userId, itemId):
    """
    add item to my research for a user

    Parameters:
     - userId
     - itemId
    """
    pass

  def deleteItemFromMyResearch(self, userId, itemId):
    """
    delete item from my research for a user

    Parameters:
     - userId
     - itemId
    """
    pass

  def getBrowseHistoryItems(self, userId):
    """
    Returns list of item ids in browse history for the user. It will return maximum 10 items.

    Parameters:
     - userId
    """
    pass

  def updateBrowseHistory(self, userId, itemId):
    """
    add item to browse history for a user

    Parameters:
     - userId
     - itemId
    """
    pass

  def getCartsWithCouponCount(self, couponCode):
    """
    Returns count of Carts with given coupon applied

    Parameters:
     - couponCode
    """
    pass

  def increaseTrustLevel(self, userId, trustLevelDelta):
    """
    Updates COD trust level of a user

    Parameters:
     - userId
     - trustLevelDelta
    """
    pass

  def getTrustLevel(self, userId):
    """
    Get trust level of a user

    Parameters:
     - userId
    """
    pass

  def showCODOption(self, cartId, sourceId, pincode):
    """
    Returns true/false depending on wether COD is allowed for a cart or not

    Parameters:
     - cartId
     - sourceId
     - pincode
    """
    pass

  def getUserEmails(self, startDate, endDate):
    """
    Get email addresses for users activated within a given date range

    Parameters:
     - startDate
     - endDate
    """
    pass

  def insureItem(self, itemId, cartId, toInsure, insurerType):
    """
    Mark a cart lineitem as insured. Returns true/false.

    Parameters:
     - itemId
     - cartId
     - toInsure
     - insurerType
    """
    pass

  def cancelInsurance(self, cartId):
    """
    Cancel insurance for all items in the cart

    Parameters:
     - cartId
    """
    pass

  def storeInsuranceSpecificDetails(self, addressId, dob, guardianName):
    """
    Stores insurance specific details like date of birth and guardianName

    Parameters:
     - addressId
     - dob
     - guardianName
    """
    pass

  def isInsuranceDetailPresent(self, addressId):
    """
    Return true or false based on whether the user has stored any insurance info corresponding to the given addressId

    Parameters:
     - addressId
    """
    pass

  def getProductsAddedToCart(self, startDate, endDate):
    """
    Returns list of item ids which added to cart from startDate to endDate

    Parameters:
     - startDate
     - endDate
    """
    pass

  def validateCartPlus(self, cartId, sourceId, dealerCoupon):
    """
    This method is speciically used to avoid overloadaed calls to userClient

    Parameters:
     - cartId
     - sourceId
     - dealerCoupon
    """
    pass

  def isPrivateDealUser(self, userId):
    """
    Parameters:
     - userId
    """
    pass

  def addPrivateDealUser(self, userId):
    """
    Parameters:
     - userId
    """
    pass

  def changePrivateDealUserStatus(self, userId, isActive):
    """
    Parameters:
     - userId
     - isActive
    """
    pass

  def getPrivateDealUser(self, userId):
    """
    Parameters:
     - userId
    """
    pass

  def registerCounter(self, counter, userId):
    """
    Parameters:
     - counter
     - userId
    """
    pass

  def searchCounter(self, type1, searchString):
    """
    Parameters:
     - type1
     - searchString
    """
    pass

  def getCounterByUserId(self, userId):
    """
    Parameters:
     - userId
    """
    pass

  def getAllUsersByCounter(self, counterId):
    """
    Parameters:
     - counterId
    """
    pass

  def getActiveAccessTokenForUser(self, userId, source):
    """
    Parameters:
     - userId
     - source
    """
    pass

  def validateAccessToken(self, accessToken):
    """
    Parameters:
     - accessToken
    """
    pass

  def addItemsToCart(self, cartId, itemQty, couponCode):
    """
    Parameters:
     - cartId
     - itemQty
     - couponCode
    """
    pass

  def validateCartNew(self, cartId, pinCode, sourceId):
    """
    Parameters:
     - cartId
     - pinCode
     - sourceId
    """
    pass

  def isAddressEditableForCounter(self, userId):
    """
    Parameters:
     - userId
    """
    pass

  def getBillingAddressForUser(self, userId):
    """
    Parameters:
     - userId
    """
    pass

  def isCreditorAssigned(self, userId):
    """
    Parameters:
     - userId
    """
    pass

  def isTaxInvoiceEnabledUser(self, userId):
    """
    Parameters:
     - userId
    """
    pass

  def taxInvoiceAvailable(self, addressId):
    """
    Parameters:
     - addressId
    """
    pass

  def getCartByValue(self, cartIds):
    """
    Parameters:
     - cartIds
    """
    pass

  def getCounterName(self, userIds):
    """
    Parameters:
     - userIds
    """
    pass

  def setWalletAmountInCart(self, cartId, wallet_amount):
    """
    Parameters:
     - cartId
     - wallet_amount
    """
    pass

  def addItemPricingToCart(self, cartId, itemPriceQuantityList):
    """
    Parameters:
     - cartId
     - itemPriceQuantityList
    """
    pass


class Client(shop2020.thriftpy.generic.GenericService.Client, Iface):
  """
  service
  """
  def __init__(self, iprot, oprot=None):
    shop2020.thriftpy.generic.GenericService.Client.__init__(self, iprot, oprot)

  def createAnonymousUser(self, jsessionId):
    """
    Parameters:
     - jsessionId
    """
    self.send_createAnonymousUser(jsessionId)
    return self.recv_createAnonymousUser()

  def send_createAnonymousUser(self, jsessionId):
    self._oprot.writeMessageBegin('createAnonymousUser', TMessageType.CALL, self._seqid)
    args = createAnonymousUser_args()
    args.jsessionId = jsessionId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_createAnonymousUser(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = createAnonymousUser_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucex is not None:
      raise result.ucex
    raise TApplicationException(TApplicationException.MISSING_RESULT, "createAnonymousUser failed: unknown result");

  def getUserById(self, userId):
    """
    Parameters:
     - userId
    """
    self.send_getUserById(userId)
    return self.recv_getUserById()

  def send_getUserById(self, userId):
    self._oprot.writeMessageBegin('getUserById', TMessageType.CALL, self._seqid)
    args = getUserById_args()
    args.userId = userId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getUserById(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getUserById_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucex is not None:
      raise result.ucex
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getUserById failed: unknown result");

  def getUserByCartId(self, cartId):
    """
    Parameters:
     - cartId
    """
    self.send_getUserByCartId(cartId)
    return self.recv_getUserByCartId()

  def send_getUserByCartId(self, cartId):
    self._oprot.writeMessageBegin('getUserByCartId', TMessageType.CALL, self._seqid)
    args = getUserByCartId_args()
    args.cartId = cartId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getUserByCartId(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getUserByCartId_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucex is not None:
      raise result.ucex
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getUserByCartId failed: unknown result");

  def getUserByEmail(self, email):
    """
    Parameters:
     - email
    """
    self.send_getUserByEmail(email)
    return self.recv_getUserByEmail()

  def send_getUserByEmail(self, email):
    self._oprot.writeMessageBegin('getUserByEmail', TMessageType.CALL, self._seqid)
    args = getUserByEmail_args()
    args.email = email
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getUserByEmail(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getUserByEmail_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucex is not None:
      raise result.ucex
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getUserByEmail failed: unknown result");

  def getUserByMobileNumber(self, mobileNumber):
    """
    Parameters:
     - mobileNumber
    """
    self.send_getUserByMobileNumber(mobileNumber)
    return self.recv_getUserByMobileNumber()

  def send_getUserByMobileNumber(self, mobileNumber):
    self._oprot.writeMessageBegin('getUserByMobileNumber', TMessageType.CALL, self._seqid)
    args = getUserByMobileNumber_args()
    args.mobileNumber = mobileNumber
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getUserByMobileNumber(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getUserByMobileNumber_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucex is not None:
      raise result.ucex
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getUserByMobileNumber failed: unknown result");

  def createUser(self, user):
    """
    Parameters:
     - user
    """
    self.send_createUser(user)
    return self.recv_createUser()

  def send_createUser(self, user):
    self._oprot.writeMessageBegin('createUser', TMessageType.CALL, self._seqid)
    args = createUser_args()
    args.user = user
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_createUser(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = createUser_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucex is not None:
      raise result.ucex
    raise TApplicationException(TApplicationException.MISSING_RESULT, "createUser failed: unknown result");

  def updateUser(self, user):
    """
    Parameters:
     - user
    """
    self.send_updateUser(user)
    return self.recv_updateUser()

  def send_updateUser(self, user):
    self._oprot.writeMessageBegin('updateUser', TMessageType.CALL, self._seqid)
    args = updateUser_args()
    args.user = user
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_updateUser(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = updateUser_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucex is not None:
      raise result.ucex
    raise TApplicationException(TApplicationException.MISSING_RESULT, "updateUser failed: unknown result");

  def authenticateUser(self, email, password):
    """
    Parameters:
     - email
     - password
    """
    self.send_authenticateUser(email, password)
    return self.recv_authenticateUser()

  def send_authenticateUser(self, email, password):
    self._oprot.writeMessageBegin('authenticateUser', TMessageType.CALL, self._seqid)
    args = authenticateUser_args()
    args.email = email
    args.password = password
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_authenticateUser(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = authenticateUser_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.auex is not None:
      raise result.auex
    raise TApplicationException(TApplicationException.MISSING_RESULT, "authenticateUser failed: unknown result");

  def userExists(self, email):
    """
    Parameters:
     - email
    """
    self.send_userExists(email)
    return self.recv_userExists()

  def send_userExists(self, email):
    self._oprot.writeMessageBegin('userExists', TMessageType.CALL, self._seqid)
    args = userExists_args()
    args.email = email
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_userExists(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = userExists_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucx is not None:
      raise result.ucx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "userExists failed: unknown result");

  def addAddressForUser(self, userId, address, setDefault):
    """
    Parameters:
     - userId
     - address
     - setDefault
    """
    self.send_addAddressForUser(userId, address, setDefault)
    return self.recv_addAddressForUser()

  def send_addAddressForUser(self, userId, address, setDefault):
    self._oprot.writeMessageBegin('addAddressForUser', TMessageType.CALL, self._seqid)
    args = addAddressForUser_args()
    args.userId = userId
    args.address = address
    args.setDefault = setDefault
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_addAddressForUser(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = addAddressForUser_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucx is not None:
      raise result.ucx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "addAddressForUser failed: unknown result");

  def removeAddressForUser(self, userid, addressId):
    """
    Parameters:
     - userid
     - addressId
    """
    self.send_removeAddressForUser(userid, addressId)
    return self.recv_removeAddressForUser()

  def send_removeAddressForUser(self, userid, addressId):
    self._oprot.writeMessageBegin('removeAddressForUser', TMessageType.CALL, self._seqid)
    args = removeAddressForUser_args()
    args.userid = userid
    args.addressId = addressId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_removeAddressForUser(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = removeAddressForUser_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucx is not None:
      raise result.ucx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "removeAddressForUser failed: unknown result");

  def updateAddress(self, address):
    """
    Parameters:
     - address
    """
    self.send_updateAddress(address)
    return self.recv_updateAddress()

  def send_updateAddress(self, address):
    self._oprot.writeMessageBegin('updateAddress', TMessageType.CALL, self._seqid)
    args = updateAddress_args()
    args.address = address
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_updateAddress(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = updateAddress_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucx is not None:
      raise result.ucx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "updateAddress failed: unknown result");

  def updateCounter(self, counter):
    """
    Parameters:
     - counter
    """
    self.send_updateCounter(counter)
    return self.recv_updateCounter()

  def send_updateCounter(self, counter):
    self._oprot.writeMessageBegin('updateCounter', TMessageType.CALL, self._seqid)
    args = updateCounter_args()
    args.counter = counter
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_updateCounter(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = updateCounter_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucx is not None:
      raise result.ucx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "updateCounter failed: unknown result");

  def setUserAsLoggedIn(self, userId, timestamp):
    """
    Parameters:
     - userId
     - timestamp
    """
    self.send_setUserAsLoggedIn(userId, timestamp)
    return self.recv_setUserAsLoggedIn()

  def send_setUserAsLoggedIn(self, userId, timestamp):
    self._oprot.writeMessageBegin('setUserAsLoggedIn', TMessageType.CALL, self._seqid)
    args = setUserAsLoggedIn_args()
    args.userId = userId
    args.timestamp = timestamp
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_setUserAsLoggedIn(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = setUserAsLoggedIn_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucx is not None:
      raise result.ucx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "setUserAsLoggedIn failed: unknown result");

  def setUserAsLoggedOut(self, userid, timestamp):
    """
    Parameters:
     - userid
     - timestamp
    """
    self.send_setUserAsLoggedOut(userid, timestamp)
    return self.recv_setUserAsLoggedOut()

  def send_setUserAsLoggedOut(self, userid, timestamp):
    self._oprot.writeMessageBegin('setUserAsLoggedOut', TMessageType.CALL, self._seqid)
    args = setUserAsLoggedOut_args()
    args.userid = userid
    args.timestamp = timestamp
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_setUserAsLoggedOut(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = setUserAsLoggedOut_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucx is not None:
      raise result.ucx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "setUserAsLoggedOut failed: unknown result");

  def setDefaultAddress(self, userid, addressId):
    """
    Parameters:
     - userid
     - addressId
    """
    self.send_setDefaultAddress(userid, addressId)
    return self.recv_setDefaultAddress()

  def send_setDefaultAddress(self, userid, addressId):
    self._oprot.writeMessageBegin('setDefaultAddress', TMessageType.CALL, self._seqid)
    args = setDefaultAddress_args()
    args.userid = userid
    args.addressId = addressId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_setDefaultAddress(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = setDefaultAddress_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucx is not None:
      raise result.ucx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "setDefaultAddress failed: unknown result");

  def updatePassword(self, userid, oldPassword, newPassword):
    """
    Parameters:
     - userid
     - oldPassword
     - newPassword
    """
    self.send_updatePassword(userid, oldPassword, newPassword)
    return self.recv_updatePassword()

  def send_updatePassword(self, userid, oldPassword, newPassword):
    self._oprot.writeMessageBegin('updatePassword', TMessageType.CALL, self._seqid)
    args = updatePassword_args()
    args.userid = userid
    args.oldPassword = oldPassword
    args.newPassword = newPassword
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_updatePassword(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = updatePassword_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucx is not None:
      raise result.ucx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "updatePassword failed: unknown result");

  def forgotPassword(self, email, newPassword):
    """
    Parameters:
     - email
     - newPassword
    """
    self.send_forgotPassword(email, newPassword)
    return self.recv_forgotPassword()

  def send_forgotPassword(self, email, newPassword):
    self._oprot.writeMessageBegin('forgotPassword', TMessageType.CALL, self._seqid)
    args = forgotPassword_args()
    args.email = email
    args.newPassword = newPassword
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_forgotPassword(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = forgotPassword_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucx is not None:
      raise result.ucx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "forgotPassword failed: unknown result");

  def getAllAddressesForUser(self, userId):
    """
    Parameters:
     - userId
    """
    self.send_getAllAddressesForUser(userId)
    return self.recv_getAllAddressesForUser()

  def send_getAllAddressesForUser(self, userId):
    self._oprot.writeMessageBegin('getAllAddressesForUser', TMessageType.CALL, self._seqid)
    args = getAllAddressesForUser_args()
    args.userId = userId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getAllAddressesForUser(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getAllAddressesForUser_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucx is not None:
      raise result.ucx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getAllAddressesForUser failed: unknown result");

  def getAddressById(self, addressId):
    """
    Parameters:
     - addressId
    """
    self.send_getAddressById(addressId)
    return self.recv_getAddressById()

  def send_getAddressById(self, addressId):
    self._oprot.writeMessageBegin('getAddressById', TMessageType.CALL, self._seqid)
    args = getAddressById_args()
    args.addressId = addressId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getAddressById(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getAddressById_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucx is not None:
      raise result.ucx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getAddressById failed: unknown result");

  def getDefaultAddressId(self, userId):
    """
    Parameters:
     - userId
    """
    self.send_getDefaultAddressId(userId)
    return self.recv_getDefaultAddressId()

  def send_getDefaultAddressId(self, userId):
    self._oprot.writeMessageBegin('getDefaultAddressId', TMessageType.CALL, self._seqid)
    args = getDefaultAddressId_args()
    args.userId = userId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getDefaultAddressId(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getDefaultAddressId_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucx is not None:
      raise result.ucx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getDefaultAddressId failed: unknown result");

  def getDefaultPincode(self, userId):
    """
    Parameters:
     - userId
    """
    self.send_getDefaultPincode(userId)
    return self.recv_getDefaultPincode()

  def send_getDefaultPincode(self, userId):
    self._oprot.writeMessageBegin('getDefaultPincode', TMessageType.CALL, self._seqid)
    args = getDefaultPincode_args()
    args.userId = userId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getDefaultPincode(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getDefaultPincode_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucx is not None:
      raise result.ucx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getDefaultPincode failed: unknown result");

  def saveUserCommunication(self, userId, replyTo, communicationType, orderId, airwaybillNo, productName, subject, message):
    """
    Parameters:
     - userId
     - replyTo
     - communicationType
     - orderId
     - airwaybillNo
     - productName
     - subject
     - message
    """
    self.send_saveUserCommunication(userId, replyTo, communicationType, orderId, airwaybillNo, productName, subject, message)
    return self.recv_saveUserCommunication()

  def send_saveUserCommunication(self, userId, replyTo, communicationType, orderId, airwaybillNo, productName, subject, message):
    self._oprot.writeMessageBegin('saveUserCommunication', TMessageType.CALL, self._seqid)
    args = saveUserCommunication_args()
    args.userId = userId
    args.replyTo = replyTo
    args.communicationType = communicationType
    args.orderId = orderId
    args.airwaybillNo = airwaybillNo
    args.productName = productName
    args.subject = subject
    args.message = message
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_saveUserCommunication(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = saveUserCommunication_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucx is not None:
      raise result.ucx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "saveUserCommunication failed: unknown result");

  def getUserCommunicationById(self, id):
    """
    Parameters:
     - id
    """
    self.send_getUserCommunicationById(id)
    return self.recv_getUserCommunicationById()

  def send_getUserCommunicationById(self, id):
    self._oprot.writeMessageBegin('getUserCommunicationById', TMessageType.CALL, self._seqid)
    args = getUserCommunicationById_args()
    args.id = id
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getUserCommunicationById(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getUserCommunicationById_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucx is not None:
      raise result.ucx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getUserCommunicationById failed: unknown result");

  def getUserCommunicationByUser(self, userId):
    """
    Parameters:
     - userId
    """
    self.send_getUserCommunicationByUser(userId)
    return self.recv_getUserCommunicationByUser()

  def send_getUserCommunicationByUser(self, userId):
    self._oprot.writeMessageBegin('getUserCommunicationByUser', TMessageType.CALL, self._seqid)
    args = getUserCommunicationByUser_args()
    args.userId = userId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getUserCommunicationByUser(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getUserCommunicationByUser_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucx is not None:
      raise result.ucx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getUserCommunicationByUser failed: unknown result");

  def getAllUserCommunications(self, ):
    self.send_getAllUserCommunications()
    return self.recv_getAllUserCommunications()

  def send_getAllUserCommunications(self, ):
    self._oprot.writeMessageBegin('getAllUserCommunications', TMessageType.CALL, self._seqid)
    args = getAllUserCommunications_args()
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getAllUserCommunications(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getAllUserCommunications_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.ucx is not None:
      raise result.ucx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getAllUserCommunications failed: unknown result");

  def removeUserCommunication(self, id):
    """
    Parameters:
     - id
    """
    self.send_removeUserCommunication(id)
    self.recv_removeUserCommunication()

  def send_removeUserCommunication(self, id):
    self._oprot.writeMessageBegin('removeUserCommunication', TMessageType.CALL, self._seqid)
    args = removeUserCommunication_args()
    args.id = id
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_removeUserCommunication(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = removeUserCommunication_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.ucx is not None:
      raise result.ucx
    return

  def createMasterAffiliate(self, name, addedOn):
    """
    Parameters:
     - name
     - addedOn
    """
    self.send_createMasterAffiliate(name, addedOn)
    return self.recv_createMasterAffiliate()

  def send_createMasterAffiliate(self, name, addedOn):
    self._oprot.writeMessageBegin('createMasterAffiliate', TMessageType.CALL, self._seqid)
    args = createMasterAffiliate_args()
    args.name = name
    args.addedOn = addedOn
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_createMasterAffiliate(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = createMasterAffiliate_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.utx is not None:
      raise result.utx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "createMasterAffiliate failed: unknown result");

  def getAllMasterAffiliates(self, ):
    self.send_getAllMasterAffiliates()
    return self.recv_getAllMasterAffiliates()

  def send_getAllMasterAffiliates(self, ):
    self._oprot.writeMessageBegin('getAllMasterAffiliates', TMessageType.CALL, self._seqid)
    args = getAllMasterAffiliates_args()
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getAllMasterAffiliates(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getAllMasterAffiliates_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.utx is not None:
      raise result.utx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getAllMasterAffiliates failed: unknown result");

  def getMasterAffiliateById(self, id):
    """
    Parameters:
     - id
    """
    self.send_getMasterAffiliateById(id)
    return self.recv_getMasterAffiliateById()

  def send_getMasterAffiliateById(self, id):
    self._oprot.writeMessageBegin('getMasterAffiliateById', TMessageType.CALL, self._seqid)
    args = getMasterAffiliateById_args()
    args.id = id
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getMasterAffiliateById(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getMasterAffiliateById_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.utx is not None:
      raise result.utx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getMasterAffiliateById failed: unknown result");

  def getMasterAffiliateByName(self, name):
    """
    Parameters:
     - name
    """
    self.send_getMasterAffiliateByName(name)
    return self.recv_getMasterAffiliateByName()

  def send_getMasterAffiliateByName(self, name):
    self._oprot.writeMessageBegin('getMasterAffiliateByName', TMessageType.CALL, self._seqid)
    args = getMasterAffiliateByName_args()
    args.name = name
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getMasterAffiliateByName(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getMasterAffiliateByName_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.utx is not None:
      raise result.utx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getMasterAffiliateByName failed: unknown result");

  def createAffiliate(self, name, url, masterAffiliateId, addedOn):
    """
    Parameters:
     - name
     - url
     - masterAffiliateId
     - addedOn
    """
    self.send_createAffiliate(name, url, masterAffiliateId, addedOn)
    return self.recv_createAffiliate()

  def send_createAffiliate(self, name, url, masterAffiliateId, addedOn):
    self._oprot.writeMessageBegin('createAffiliate', TMessageType.CALL, self._seqid)
    args = createAffiliate_args()
    args.name = name
    args.url = url
    args.masterAffiliateId = masterAffiliateId
    args.addedOn = addedOn
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_createAffiliate(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = createAffiliate_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.utx is not None:
      raise result.utx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "createAffiliate failed: unknown result");

  def getAffiliateById(self, id):
    """
    Parameters:
     - id
    """
    self.send_getAffiliateById(id)
    return self.recv_getAffiliateById()

  def send_getAffiliateById(self, id):
    self._oprot.writeMessageBegin('getAffiliateById', TMessageType.CALL, self._seqid)
    args = getAffiliateById_args()
    args.id = id
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getAffiliateById(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getAffiliateById_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.utx is not None:
      raise result.utx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getAffiliateById failed: unknown result");

  def getAffiliateByName(self, name):
    """
    Parameters:
     - name
    """
    self.send_getAffiliateByName(name)
    return self.recv_getAffiliateByName()

  def send_getAffiliateByName(self, name):
    self._oprot.writeMessageBegin('getAffiliateByName', TMessageType.CALL, self._seqid)
    args = getAffiliateByName_args()
    args.name = name
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getAffiliateByName(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getAffiliateByName_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.utx is not None:
      raise result.utx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getAffiliateByName failed: unknown result");

  def getTrackerById(self, id):
    """
    Parameters:
     - id
    """
    self.send_getTrackerById(id)
    return self.recv_getTrackerById()

  def send_getTrackerById(self, id):
    self._oprot.writeMessageBegin('getTrackerById', TMessageType.CALL, self._seqid)
    args = getTrackerById_args()
    args.id = id
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getTrackerById(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getTrackerById_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.utx is not None:
      raise result.utx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getTrackerById failed: unknown result");

  def getAffiliatesByMasterAffiliate(self, id):
    """
    Parameters:
     - id
    """
    self.send_getAffiliatesByMasterAffiliate(id)
    return self.recv_getAffiliatesByMasterAffiliate()

  def send_getAffiliatesByMasterAffiliate(self, id):
    self._oprot.writeMessageBegin('getAffiliatesByMasterAffiliate', TMessageType.CALL, self._seqid)
    args = getAffiliatesByMasterAffiliate_args()
    args.id = id
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getAffiliatesByMasterAffiliate(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getAffiliatesByMasterAffiliate_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.utx is not None:
      raise result.utx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getAffiliatesByMasterAffiliate failed: unknown result");

  def addTrackLog(self, affiliateId, userId, event, url, data, addedOn):
    """
    Parameters:
     - affiliateId
     - userId
     - event
     - url
     - data
     - addedOn
    """
    self.send_addTrackLog(affiliateId, userId, event, url, data, addedOn)
    return self.recv_addTrackLog()

  def send_addTrackLog(self, affiliateId, userId, event, url, data, addedOn):
    self._oprot.writeMessageBegin('addTrackLog', TMessageType.CALL, self._seqid)
    args = addTrackLog_args()
    args.affiliateId = affiliateId
    args.userId = userId
    args.event = event
    args.url = url
    args.data = data
    args.addedOn = addedOn
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_addTrackLog(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = addTrackLog_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.utx is not None:
      raise result.utx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "addTrackLog failed: unknown result");

  def getTrackLogById(self, id):
    """
    Parameters:
     - id
    """
    self.send_getTrackLogById(id)
    return self.recv_getTrackLogById()

  def send_getTrackLogById(self, id):
    self._oprot.writeMessageBegin('getTrackLogById', TMessageType.CALL, self._seqid)
    args = getTrackLogById_args()
    args.id = id
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getTrackLogById(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getTrackLogById_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.utx is not None:
      raise result.utx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getTrackLogById failed: unknown result");

  def getTrackLogsByAffiliate(self, affiliateId, startDate, endDate):
    """
    Parameters:
     - affiliateId
     - startDate
     - endDate
    """
    self.send_getTrackLogsByAffiliate(affiliateId, startDate, endDate)
    return self.recv_getTrackLogsByAffiliate()

  def send_getTrackLogsByAffiliate(self, affiliateId, startDate, endDate):
    self._oprot.writeMessageBegin('getTrackLogsByAffiliate', TMessageType.CALL, self._seqid)
    args = getTrackLogsByAffiliate_args()
    args.affiliateId = affiliateId
    args.startDate = startDate
    args.endDate = endDate
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getTrackLogsByAffiliate(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getTrackLogsByAffiliate_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.utx is not None:
      raise result.utx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getTrackLogsByAffiliate failed: unknown result");

  def getTrackLogsByUser(self, userId):
    """
    Parameters:
     - userId
    """
    self.send_getTrackLogsByUser(userId)
    return self.recv_getTrackLogsByUser()

  def send_getTrackLogsByUser(self, userId):
    self._oprot.writeMessageBegin('getTrackLogsByUser', TMessageType.CALL, self._seqid)
    args = getTrackLogsByUser_args()
    args.userId = userId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getTrackLogsByUser(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getTrackLogsByUser_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.utx is not None:
      raise result.utx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getTrackLogsByUser failed: unknown result");

  def getTrackLogs(self, userId, event, url):
    """
    Parameters:
     - userId
     - event
     - url
    """
    self.send_getTrackLogs(userId, event, url)
    return self.recv_getTrackLogs()

  def send_getTrackLogs(self, userId, event, url):
    self._oprot.writeMessageBegin('getTrackLogs', TMessageType.CALL, self._seqid)
    args = getTrackLogs_args()
    args.userId = userId
    args.event = event
    args.url = url
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getTrackLogs(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getTrackLogs_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.utx is not None:
      raise result.utx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getTrackLogs failed: unknown result");

  def getCurrentCart(self, userId):
    """
    Parameters:
     - userId
    """
    self.send_getCurrentCart(userId)
    return self.recv_getCurrentCart()

  def send_getCurrentCart(self, userId):
    self._oprot.writeMessageBegin('getCurrentCart', TMessageType.CALL, self._seqid)
    args = getCurrentCart_args()
    args.userId = userId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getCurrentCart(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getCurrentCart_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.scx is not None:
      raise result.scx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getCurrentCart failed: unknown result");

  def getCart(self, cartId):
    """
    Parameters:
     - cartId
    """
    self.send_getCart(cartId)
    return self.recv_getCart()

  def send_getCart(self, cartId):
    self._oprot.writeMessageBegin('getCart', TMessageType.CALL, self._seqid)
    args = getCart_args()
    args.cartId = cartId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getCart(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getCart_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.scx is not None:
      raise result.scx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getCart failed: unknown result");

  def getCartsByTime(self, from_time, to_time, status):
    """
    Parameters:
     - from_time
     - to_time
     - status
    """
    self.send_getCartsByTime(from_time, to_time, status)
    return self.recv_getCartsByTime()

  def send_getCartsByTime(self, from_time, to_time, status):
    self._oprot.writeMessageBegin('getCartsByTime', TMessageType.CALL, self._seqid)
    args = getCartsByTime_args()
    args.from_time = from_time
    args.to_time = to_time
    args.status = status
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getCartsByTime(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getCartsByTime_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.scx is not None:
      raise result.scx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getCartsByTime failed: unknown result");

  def addItemToCart(self, cartId, itemId, quantity, sourceId):
    """
    Parameters:
     - cartId
     - itemId
     - quantity
     - sourceId
    """
    self.send_addItemToCart(cartId, itemId, quantity, sourceId)
    return self.recv_addItemToCart()

  def send_addItemToCart(self, cartId, itemId, quantity, sourceId):
    self._oprot.writeMessageBegin('addItemToCart', TMessageType.CALL, self._seqid)
    args = addItemToCart_args()
    args.cartId = cartId
    args.itemId = itemId
    args.quantity = quantity
    args.sourceId = sourceId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_addItemToCart(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = addItemToCart_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.scx is not None:
      raise result.scx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "addItemToCart failed: unknown result");

  def deleteItemFromCart(self, cartId, itemId):
    """
    Parameters:
     - cartId
     - itemId
    """
    self.send_deleteItemFromCart(cartId, itemId)
    self.recv_deleteItemFromCart()

  def send_deleteItemFromCart(self, cartId, itemId):
    self._oprot.writeMessageBegin('deleteItemFromCart', TMessageType.CALL, self._seqid)
    args = deleteItemFromCart_args()
    args.cartId = cartId
    args.itemId = itemId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_deleteItemFromCart(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = deleteItemFromCart_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.scx is not None:
      raise result.scx
    return

  def addAddressToCart(self, cartId, addressId):
    """
    Parameters:
     - cartId
     - addressId
    """
    self.send_addAddressToCart(cartId, addressId)
    self.recv_addAddressToCart()

  def send_addAddressToCart(self, cartId, addressId):
    self._oprot.writeMessageBegin('addAddressToCart', TMessageType.CALL, self._seqid)
    args = addAddressToCart_args()
    args.cartId = cartId
    args.addressId = addressId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_addAddressToCart(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = addAddressToCart_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.scx is not None:
      raise result.scx
    return

  def addStoreToCart(self, cartId, storeId):
    """
    Parameters:
     - cartId
     - storeId
    """
    self.send_addStoreToCart(cartId, storeId)
    self.recv_addStoreToCart()

  def send_addStoreToCart(self, cartId, storeId):
    self._oprot.writeMessageBegin('addStoreToCart', TMessageType.CALL, self._seqid)
    args = addStoreToCart_args()
    args.cartId = cartId
    args.storeId = storeId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_addStoreToCart(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = addStoreToCart_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.scx is not None:
      raise result.scx
    return

  def applyCouponToCart(self, cart, couponCode):
    """
    Parameters:
     - cart
     - couponCode
    """
    self.send_applyCouponToCart(cart, couponCode)
    self.recv_applyCouponToCart()

  def send_applyCouponToCart(self, cart, couponCode):
    self._oprot.writeMessageBegin('applyCouponToCart', TMessageType.CALL, self._seqid)
    args = applyCouponToCart_args()
    args.cart = cart
    args.couponCode = couponCode
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_applyCouponToCart(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = applyCouponToCart_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.scx is not None:
      raise result.scx
    return

  def removeCoupon(self, cartId):
    """
    Parameters:
     - cartId
    """
    self.send_removeCoupon(cartId)
    self.recv_removeCoupon()

  def send_removeCoupon(self, cartId):
    self._oprot.writeMessageBegin('removeCoupon', TMessageType.CALL, self._seqid)
    args = removeCoupon_args()
    args.cartId = cartId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_removeCoupon(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = removeCoupon_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.scx is not None:
      raise result.scx
    return

  def deleteDiscountsFromCart(self, cartId):
    """
    Deletes all the discounts associated with the cart

    Parameters:
     - cartId
    """
    self.send_deleteDiscountsFromCart(cartId)
    self.recv_deleteDiscountsFromCart()

  def send_deleteDiscountsFromCart(self, cartId):
    self._oprot.writeMessageBegin('deleteDiscountsFromCart', TMessageType.CALL, self._seqid)
    args = deleteDiscountsFromCart_args()
    args.cartId = cartId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_deleteDiscountsFromCart(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = deleteDiscountsFromCart_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.scx is not None:
      raise result.scx
    return

  def saveDiscounts(self, discounts):
    """
    Accepts a list of thrift objects of Discount type and saves them

    Parameters:
     - discounts
    """
    self.send_saveDiscounts(discounts)
    self.recv_saveDiscounts()

  def send_saveDiscounts(self, discounts):
    self._oprot.writeMessageBegin('saveDiscounts', TMessageType.CALL, self._seqid)
    args = saveDiscounts_args()
    args.discounts = discounts
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_saveDiscounts(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = saveDiscounts_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.scx is not None:
      raise result.scx
    return

  def createOrders(self, cartId, sessionSource, sessionStartTime, firstSource, firstSourceTime, userId, schemeId, orderSource, selfPickup):
    """
    Creates a transaction and multiple orders for the given cart. Returns the transaction ID created.

    Parameters:
     - cartId
     - sessionSource
     - sessionStartTime
     - firstSource
     - firstSourceTime
     - userId
     - schemeId
     - orderSource
     - selfPickup
    """
    self.send_createOrders(cartId, sessionSource, sessionStartTime, firstSource, firstSourceTime, userId, schemeId, orderSource, selfPickup)
    return self.recv_createOrders()

  def send_createOrders(self, cartId, sessionSource, sessionStartTime, firstSource, firstSourceTime, userId, schemeId, orderSource, selfPickup):
    self._oprot.writeMessageBegin('createOrders', TMessageType.CALL, self._seqid)
    args = createOrders_args()
    args.cartId = cartId
    args.sessionSource = sessionSource
    args.sessionStartTime = sessionStartTime
    args.firstSource = firstSource
    args.firstSourceTime = firstSourceTime
    args.userId = userId
    args.schemeId = schemeId
    args.orderSource = orderSource
    args.selfPickup = selfPickup
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_createOrders(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = createOrders_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.scx is not None:
      raise result.scx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "createOrders failed: unknown result");

  def validateCart(self, cartId, sourceId):
    """
    Validates that:
    1. The checkout timestamp is greater than the updatedOn timestamp.
    2. All of the lines in the cart are active items.
    3. The estimate for any of the lines in cart doesn't change.
    If all three are true, returns empty string; else returns appropriate message.

    Parameters:
     - cartId
     - sourceId
    """
    self.send_validateCart(cartId, sourceId)
    return self.recv_validateCart()

  def send_validateCart(self, cartId, sourceId):
    self._oprot.writeMessageBegin('validateCart', TMessageType.CALL, self._seqid)
    args = validateCart_args()
    args.cartId = cartId
    args.sourceId = sourceId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_validateCart(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = validateCart_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.scex is not None:
      raise result.scex
    raise TApplicationException(TApplicationException.MISSING_RESULT, "validateCart failed: unknown result");

  def validateCartWithDealerCoupon(self, cartId, sourceId, dealCoupon):
    """
    Validates that:
    1. The checkout timestamp is greater than the updatedOn timestamp.
    2. All of the lines in the cart are active items.
    3. The estimate for any of the lines in cart doesn't change.
    If all three are true, returns empty string; else returns appropriate message.

    Parameters:
     - cartId
     - sourceId
     - dealCoupon
    """
    self.send_validateCartWithDealerCoupon(cartId, sourceId, dealCoupon)
    return self.recv_validateCartWithDealerCoupon()

  def send_validateCartWithDealerCoupon(self, cartId, sourceId, dealCoupon):
    self._oprot.writeMessageBegin('validateCartWithDealerCoupon', TMessageType.CALL, self._seqid)
    args = validateCartWithDealerCoupon_args()
    args.cartId = cartId
    args.sourceId = sourceId
    args.dealCoupon = dealCoupon
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_validateCartWithDealerCoupon(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = validateCartWithDealerCoupon_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.scex is not None:
      raise result.scex
    raise TApplicationException(TApplicationException.MISSING_RESULT, "validateCartWithDealerCoupon failed: unknown result");

  def mergeCart(self, fromCartId, toCartId):
    """
    Merges the lines from the first cart into the second cart. Lines with duplicate items are removed.

    Parameters:
     - fromCartId
     - toCartId
    """
    self.send_mergeCart(fromCartId, toCartId)
    self.recv_mergeCart()

  def send_mergeCart(self, fromCartId, toCartId):
    self._oprot.writeMessageBegin('mergeCart', TMessageType.CALL, self._seqid)
    args = mergeCart_args()
    args.fromCartId = fromCartId
    args.toCartId = toCartId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_mergeCart(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = mergeCart_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    return

  def checkOut(self, cartId):
    """
    Sets the checkedOutOn timestamp of the cart. Raises an exception if the specified cart can't be found.

    Parameters:
     - cartId
    """
    self.send_checkOut(cartId)
    return self.recv_checkOut()

  def send_checkOut(self, cartId):
    self._oprot.writeMessageBegin('checkOut', TMessageType.CALL, self._seqid)
    args = checkOut_args()
    args.cartId = cartId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_checkOut(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = checkOut_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.scex is not None:
      raise result.scex
    raise TApplicationException(TApplicationException.MISSING_RESULT, "checkOut failed: unknown result");

  def resetCart(self, cartId, items):
    """
    The second parameter is a map of item ids and their quantities which have been successfully processed.
    This methods removes the specified quantiry of the specified item from the cart.

    Parameters:
     - cartId
     - items
    """
    self.send_resetCart(cartId, items)
    return self.recv_resetCart()

  def send_resetCart(self, cartId, items):
    self._oprot.writeMessageBegin('resetCart', TMessageType.CALL, self._seqid)
    args = resetCart_args()
    args.cartId = cartId
    args.items = items
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_resetCart(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = resetCart_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.scex is not None:
      raise result.scex
    raise TApplicationException(TApplicationException.MISSING_RESULT, "resetCart failed: unknown result");

  def getUserCount(self, userType):
    """
    Returns number of registered users.
    If userType = null, then it returns count of all users, including anonymous
    If userType = UserType.ANONYMOUS, then it returns count of anonymous users only
    If userType = UserType.USER, then it returns count of non-anonymous users only

    Parameters:
     - userType
    """
    self.send_getUserCount(userType)
    return self.recv_getUserCount()

  def send_getUserCount(self, userType):
    self._oprot.writeMessageBegin('getUserCount', TMessageType.CALL, self._seqid)
    args = getUserCount_args()
    args.userType = userType
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getUserCount(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getUserCount_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getUserCount failed: unknown result");

  def getAllUsers(self, userType, startDate, endDate):
    """
    Returns list of users of type userType who registered between startDate and endDate (both inclusive).
    If any of startDate or endDate is -1, then that filter is ignored.
    If userType is null, then returns all the users, irrespective of anonymous flag


    Parameters:
     - userType
     - startDate
     - endDate
    """
    self.send_getAllUsers(userType, startDate, endDate)
    return self.recv_getAllUsers()

  def send_getAllUsers(self, userType, startDate, endDate):
    self._oprot.writeMessageBegin('getAllUsers', TMessageType.CALL, self._seqid)
    args = getAllUsers_args()
    args.userType = userType
    args.startDate = startDate
    args.endDate = endDate
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getAllUsers(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getAllUsers_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getAllUsers failed: unknown result");

  def getMyResearchItems(self, userId):
    """
    Returns list of item ids in myresearch for the user

    Parameters:
     - userId
    """
    self.send_getMyResearchItems(userId)
    return self.recv_getMyResearchItems()

  def send_getMyResearchItems(self, userId):
    self._oprot.writeMessageBegin('getMyResearchItems', TMessageType.CALL, self._seqid)
    args = getMyResearchItems_args()
    args.userId = userId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getMyResearchItems(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getMyResearchItems_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.scx is not None:
      raise result.scx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getMyResearchItems failed: unknown result");

  def updateMyResearch(self, userId, itemId):
    """
    add item to my research for a user

    Parameters:
     - userId
     - itemId
    """
    self.send_updateMyResearch(userId, itemId)
    return self.recv_updateMyResearch()

  def send_updateMyResearch(self, userId, itemId):
    self._oprot.writeMessageBegin('updateMyResearch', TMessageType.CALL, self._seqid)
    args = updateMyResearch_args()
    args.userId = userId
    args.itemId = itemId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_updateMyResearch(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = updateMyResearch_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.scx is not None:
      raise result.scx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "updateMyResearch failed: unknown result");

  def deleteItemFromMyResearch(self, userId, itemId):
    """
    delete item from my research for a user

    Parameters:
     - userId
     - itemId
    """
    self.send_deleteItemFromMyResearch(userId, itemId)
    self.recv_deleteItemFromMyResearch()

  def send_deleteItemFromMyResearch(self, userId, itemId):
    self._oprot.writeMessageBegin('deleteItemFromMyResearch', TMessageType.CALL, self._seqid)
    args = deleteItemFromMyResearch_args()
    args.userId = userId
    args.itemId = itemId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_deleteItemFromMyResearch(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = deleteItemFromMyResearch_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.scx is not None:
      raise result.scx
    return

  def getBrowseHistoryItems(self, userId):
    """
    Returns list of item ids in browse history for the user. It will return maximum 10 items.

    Parameters:
     - userId
    """
    self.send_getBrowseHistoryItems(userId)
    return self.recv_getBrowseHistoryItems()

  def send_getBrowseHistoryItems(self, userId):
    self._oprot.writeMessageBegin('getBrowseHistoryItems', TMessageType.CALL, self._seqid)
    args = getBrowseHistoryItems_args()
    args.userId = userId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getBrowseHistoryItems(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getBrowseHistoryItems_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.scx is not None:
      raise result.scx
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getBrowseHistoryItems failed: unknown result");

  def updateBrowseHistory(self, userId, itemId):
    """
    add item to browse history for a user

    Parameters:
     - userId
     - itemId
    """
    self.send_updateBrowseHistory(userId, itemId)
    self.recv_updateBrowseHistory()

  def send_updateBrowseHistory(self, userId, itemId):
    self._oprot.writeMessageBegin('updateBrowseHistory', TMessageType.CALL, self._seqid)
    args = updateBrowseHistory_args()
    args.userId = userId
    args.itemId = itemId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_updateBrowseHistory(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = updateBrowseHistory_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    return

  def getCartsWithCouponCount(self, couponCode):
    """
    Returns count of Carts with given coupon applied

    Parameters:
     - couponCode
    """
    self.send_getCartsWithCouponCount(couponCode)
    return self.recv_getCartsWithCouponCount()

  def send_getCartsWithCouponCount(self, couponCode):
    self._oprot.writeMessageBegin('getCartsWithCouponCount', TMessageType.CALL, self._seqid)
    args = getCartsWithCouponCount_args()
    args.couponCode = couponCode
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getCartsWithCouponCount(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getCartsWithCouponCount_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getCartsWithCouponCount failed: unknown result");

  def increaseTrustLevel(self, userId, trustLevelDelta):
    """
    Updates COD trust level of a user

    Parameters:
     - userId
     - trustLevelDelta
    """
    self.send_increaseTrustLevel(userId, trustLevelDelta)

  def send_increaseTrustLevel(self, userId, trustLevelDelta):
    self._oprot.writeMessageBegin('increaseTrustLevel', TMessageType.CALL, self._seqid)
    args = increaseTrustLevel_args()
    args.userId = userId
    args.trustLevelDelta = trustLevelDelta
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()
  def getTrustLevel(self, userId):
    """
    Get trust level of a user

    Parameters:
     - userId
    """
    self.send_getTrustLevel(userId)
    return self.recv_getTrustLevel()

  def send_getTrustLevel(self, userId):
    self._oprot.writeMessageBegin('getTrustLevel', TMessageType.CALL, self._seqid)
    args = getTrustLevel_args()
    args.userId = userId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getTrustLevel(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getTrustLevel_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getTrustLevel failed: unknown result");

  def showCODOption(self, cartId, sourceId, pincode):
    """
    Returns true/false depending on wether COD is allowed for a cart or not

    Parameters:
     - cartId
     - sourceId
     - pincode
    """
    self.send_showCODOption(cartId, sourceId, pincode)
    return self.recv_showCODOption()

  def send_showCODOption(self, cartId, sourceId, pincode):
    self._oprot.writeMessageBegin('showCODOption', TMessageType.CALL, self._seqid)
    args = showCODOption_args()
    args.cartId = cartId
    args.sourceId = sourceId
    args.pincode = pincode
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_showCODOption(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = showCODOption_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "showCODOption failed: unknown result");

  def getUserEmails(self, startDate, endDate):
    """
    Get email addresses for users activated within a given date range

    Parameters:
     - startDate
     - endDate
    """
    self.send_getUserEmails(startDate, endDate)
    return self.recv_getUserEmails()

  def send_getUserEmails(self, startDate, endDate):
    self._oprot.writeMessageBegin('getUserEmails', TMessageType.CALL, self._seqid)
    args = getUserEmails_args()
    args.startDate = startDate
    args.endDate = endDate
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getUserEmails(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getUserEmails_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getUserEmails failed: unknown result");

  def insureItem(self, itemId, cartId, toInsure, insurerType):
    """
    Mark a cart lineitem as insured. Returns true/false.

    Parameters:
     - itemId
     - cartId
     - toInsure
     - insurerType
    """
    self.send_insureItem(itemId, cartId, toInsure, insurerType)
    return self.recv_insureItem()

  def send_insureItem(self, itemId, cartId, toInsure, insurerType):
    self._oprot.writeMessageBegin('insureItem', TMessageType.CALL, self._seqid)
    args = insureItem_args()
    args.itemId = itemId
    args.cartId = cartId
    args.toInsure = toInsure
    args.insurerType = insurerType
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_insureItem(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = insureItem_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "insureItem failed: unknown result");

  def cancelInsurance(self, cartId):
    """
    Cancel insurance for all items in the cart

    Parameters:
     - cartId
    """
    self.send_cancelInsurance(cartId)
    return self.recv_cancelInsurance()

  def send_cancelInsurance(self, cartId):
    self._oprot.writeMessageBegin('cancelInsurance', TMessageType.CALL, self._seqid)
    args = cancelInsurance_args()
    args.cartId = cartId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_cancelInsurance(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = cancelInsurance_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "cancelInsurance failed: unknown result");

  def storeInsuranceSpecificDetails(self, addressId, dob, guardianName):
    """
    Stores insurance specific details like date of birth and guardianName

    Parameters:
     - addressId
     - dob
     - guardianName
    """
    self.send_storeInsuranceSpecificDetails(addressId, dob, guardianName)
    return self.recv_storeInsuranceSpecificDetails()

  def send_storeInsuranceSpecificDetails(self, addressId, dob, guardianName):
    self._oprot.writeMessageBegin('storeInsuranceSpecificDetails', TMessageType.CALL, self._seqid)
    args = storeInsuranceSpecificDetails_args()
    args.addressId = addressId
    args.dob = dob
    args.guardianName = guardianName
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_storeInsuranceSpecificDetails(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = storeInsuranceSpecificDetails_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "storeInsuranceSpecificDetails failed: unknown result");

  def isInsuranceDetailPresent(self, addressId):
    """
    Return true or false based on whether the user has stored any insurance info corresponding to the given addressId

    Parameters:
     - addressId
    """
    self.send_isInsuranceDetailPresent(addressId)
    return self.recv_isInsuranceDetailPresent()

  def send_isInsuranceDetailPresent(self, addressId):
    self._oprot.writeMessageBegin('isInsuranceDetailPresent', TMessageType.CALL, self._seqid)
    args = isInsuranceDetailPresent_args()
    args.addressId = addressId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_isInsuranceDetailPresent(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = isInsuranceDetailPresent_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "isInsuranceDetailPresent failed: unknown result");

  def getProductsAddedToCart(self, startDate, endDate):
    """
    Returns list of item ids which added to cart from startDate to endDate

    Parameters:
     - startDate
     - endDate
    """
    self.send_getProductsAddedToCart(startDate, endDate)
    return self.recv_getProductsAddedToCart()

  def send_getProductsAddedToCart(self, startDate, endDate):
    self._oprot.writeMessageBegin('getProductsAddedToCart', TMessageType.CALL, self._seqid)
    args = getProductsAddedToCart_args()
    args.startDate = startDate
    args.endDate = endDate
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getProductsAddedToCart(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getProductsAddedToCart_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getProductsAddedToCart failed: unknown result");

  def validateCartPlus(self, cartId, sourceId, dealerCoupon):
    """
    This method is speciically used to avoid overloadaed calls to userClient

    Parameters:
     - cartId
     - sourceId
     - dealerCoupon
    """
    self.send_validateCartPlus(cartId, sourceId, dealerCoupon)
    return self.recv_validateCartPlus()

  def send_validateCartPlus(self, cartId, sourceId, dealerCoupon):
    self._oprot.writeMessageBegin('validateCartPlus', TMessageType.CALL, self._seqid)
    args = validateCartPlus_args()
    args.cartId = cartId
    args.sourceId = sourceId
    args.dealerCoupon = dealerCoupon
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_validateCartPlus(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = validateCartPlus_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    if result.scex is not None:
      raise result.scex
    raise TApplicationException(TApplicationException.MISSING_RESULT, "validateCartPlus failed: unknown result");

  def isPrivateDealUser(self, userId):
    """
    Parameters:
     - userId
    """
    self.send_isPrivateDealUser(userId)
    return self.recv_isPrivateDealUser()

  def send_isPrivateDealUser(self, userId):
    self._oprot.writeMessageBegin('isPrivateDealUser', TMessageType.CALL, self._seqid)
    args = isPrivateDealUser_args()
    args.userId = userId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_isPrivateDealUser(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = isPrivateDealUser_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "isPrivateDealUser failed: unknown result");

  def addPrivateDealUser(self, userId):
    """
    Parameters:
     - userId
    """
    self.send_addPrivateDealUser(userId)
    return self.recv_addPrivateDealUser()

  def send_addPrivateDealUser(self, userId):
    self._oprot.writeMessageBegin('addPrivateDealUser', TMessageType.CALL, self._seqid)
    args = addPrivateDealUser_args()
    args.userId = userId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_addPrivateDealUser(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = addPrivateDealUser_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "addPrivateDealUser failed: unknown result");

  def changePrivateDealUserStatus(self, userId, isActive):
    """
    Parameters:
     - userId
     - isActive
    """
    self.send_changePrivateDealUserStatus(userId, isActive)
    return self.recv_changePrivateDealUserStatus()

  def send_changePrivateDealUserStatus(self, userId, isActive):
    self._oprot.writeMessageBegin('changePrivateDealUserStatus', TMessageType.CALL, self._seqid)
    args = changePrivateDealUserStatus_args()
    args.userId = userId
    args.isActive = isActive
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_changePrivateDealUserStatus(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = changePrivateDealUserStatus_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "changePrivateDealUserStatus failed: unknown result");

  def getPrivateDealUser(self, userId):
    """
    Parameters:
     - userId
    """
    self.send_getPrivateDealUser(userId)
    return self.recv_getPrivateDealUser()

  def send_getPrivateDealUser(self, userId):
    self._oprot.writeMessageBegin('getPrivateDealUser', TMessageType.CALL, self._seqid)
    args = getPrivateDealUser_args()
    args.userId = userId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getPrivateDealUser(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getPrivateDealUser_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getPrivateDealUser failed: unknown result");

  def registerCounter(self, counter, userId):
    """
    Parameters:
     - counter
     - userId
    """
    self.send_registerCounter(counter, userId)
    return self.recv_registerCounter()

  def send_registerCounter(self, counter, userId):
    self._oprot.writeMessageBegin('registerCounter', TMessageType.CALL, self._seqid)
    args = registerCounter_args()
    args.counter = counter
    args.userId = userId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_registerCounter(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = registerCounter_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "registerCounter failed: unknown result");

  def searchCounter(self, type1, searchString):
    """
    Parameters:
     - type1
     - searchString
    """
    self.send_searchCounter(type1, searchString)
    return self.recv_searchCounter()

  def send_searchCounter(self, type1, searchString):
    self._oprot.writeMessageBegin('searchCounter', TMessageType.CALL, self._seqid)
    args = searchCounter_args()
    args.type1 = type1
    args.searchString = searchString
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_searchCounter(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = searchCounter_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "searchCounter failed: unknown result");

  def getCounterByUserId(self, userId):
    """
    Parameters:
     - userId
    """
    self.send_getCounterByUserId(userId)
    return self.recv_getCounterByUserId()

  def send_getCounterByUserId(self, userId):
    self._oprot.writeMessageBegin('getCounterByUserId', TMessageType.CALL, self._seqid)
    args = getCounterByUserId_args()
    args.userId = userId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getCounterByUserId(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getCounterByUserId_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getCounterByUserId failed: unknown result");

  def getAllUsersByCounter(self, counterId):
    """
    Parameters:
     - counterId
    """
    self.send_getAllUsersByCounter(counterId)
    return self.recv_getAllUsersByCounter()

  def send_getAllUsersByCounter(self, counterId):
    self._oprot.writeMessageBegin('getAllUsersByCounter', TMessageType.CALL, self._seqid)
    args = getAllUsersByCounter_args()
    args.counterId = counterId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getAllUsersByCounter(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getAllUsersByCounter_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getAllUsersByCounter failed: unknown result");

  def getActiveAccessTokenForUser(self, userId, source):
    """
    Parameters:
     - userId
     - source
    """
    self.send_getActiveAccessTokenForUser(userId, source)
    return self.recv_getActiveAccessTokenForUser()

  def send_getActiveAccessTokenForUser(self, userId, source):
    self._oprot.writeMessageBegin('getActiveAccessTokenForUser', TMessageType.CALL, self._seqid)
    args = getActiveAccessTokenForUser_args()
    args.userId = userId
    args.source = source
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getActiveAccessTokenForUser(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getActiveAccessTokenForUser_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getActiveAccessTokenForUser failed: unknown result");

  def validateAccessToken(self, accessToken):
    """
    Parameters:
     - accessToken
    """
    self.send_validateAccessToken(accessToken)
    return self.recv_validateAccessToken()

  def send_validateAccessToken(self, accessToken):
    self._oprot.writeMessageBegin('validateAccessToken', TMessageType.CALL, self._seqid)
    args = validateAccessToken_args()
    args.accessToken = accessToken
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_validateAccessToken(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = validateAccessToken_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "validateAccessToken failed: unknown result");

  def addItemsToCart(self, cartId, itemQty, couponCode):
    """
    Parameters:
     - cartId
     - itemQty
     - couponCode
    """
    self.send_addItemsToCart(cartId, itemQty, couponCode)
    return self.recv_addItemsToCart()

  def send_addItemsToCart(self, cartId, itemQty, couponCode):
    self._oprot.writeMessageBegin('addItemsToCart', TMessageType.CALL, self._seqid)
    args = addItemsToCart_args()
    args.cartId = cartId
    args.itemQty = itemQty
    args.couponCode = couponCode
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_addItemsToCart(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = addItemsToCart_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "addItemsToCart failed: unknown result");

  def validateCartNew(self, cartId, pinCode, sourceId):
    """
    Parameters:
     - cartId
     - pinCode
     - sourceId
    """
    self.send_validateCartNew(cartId, pinCode, sourceId)
    return self.recv_validateCartNew()

  def send_validateCartNew(self, cartId, pinCode, sourceId):
    self._oprot.writeMessageBegin('validateCartNew', TMessageType.CALL, self._seqid)
    args = validateCartNew_args()
    args.cartId = cartId
    args.pinCode = pinCode
    args.sourceId = sourceId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_validateCartNew(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = validateCartNew_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "validateCartNew failed: unknown result");

  def isAddressEditableForCounter(self, userId):
    """
    Parameters:
     - userId
    """
    self.send_isAddressEditableForCounter(userId)
    return self.recv_isAddressEditableForCounter()

  def send_isAddressEditableForCounter(self, userId):
    self._oprot.writeMessageBegin('isAddressEditableForCounter', TMessageType.CALL, self._seqid)
    args = isAddressEditableForCounter_args()
    args.userId = userId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_isAddressEditableForCounter(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = isAddressEditableForCounter_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "isAddressEditableForCounter failed: unknown result");

  def getBillingAddressForUser(self, userId):
    """
    Parameters:
     - userId
    """
    self.send_getBillingAddressForUser(userId)
    return self.recv_getBillingAddressForUser()

  def send_getBillingAddressForUser(self, userId):
    self._oprot.writeMessageBegin('getBillingAddressForUser', TMessageType.CALL, self._seqid)
    args = getBillingAddressForUser_args()
    args.userId = userId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getBillingAddressForUser(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getBillingAddressForUser_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getBillingAddressForUser failed: unknown result");

  def isCreditorAssigned(self, userId):
    """
    Parameters:
     - userId
    """
    self.send_isCreditorAssigned(userId)
    return self.recv_isCreditorAssigned()

  def send_isCreditorAssigned(self, userId):
    self._oprot.writeMessageBegin('isCreditorAssigned', TMessageType.CALL, self._seqid)
    args = isCreditorAssigned_args()
    args.userId = userId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_isCreditorAssigned(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = isCreditorAssigned_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "isCreditorAssigned failed: unknown result");

  def isTaxInvoiceEnabledUser(self, userId):
    """
    Parameters:
     - userId
    """
    self.send_isTaxInvoiceEnabledUser(userId)
    return self.recv_isTaxInvoiceEnabledUser()

  def send_isTaxInvoiceEnabledUser(self, userId):
    self._oprot.writeMessageBegin('isTaxInvoiceEnabledUser', TMessageType.CALL, self._seqid)
    args = isTaxInvoiceEnabledUser_args()
    args.userId = userId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_isTaxInvoiceEnabledUser(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = isTaxInvoiceEnabledUser_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "isTaxInvoiceEnabledUser failed: unknown result");

  def taxInvoiceAvailable(self, addressId):
    """
    Parameters:
     - addressId
    """
    self.send_taxInvoiceAvailable(addressId)
    return self.recv_taxInvoiceAvailable()

  def send_taxInvoiceAvailable(self, addressId):
    self._oprot.writeMessageBegin('taxInvoiceAvailable', TMessageType.CALL, self._seqid)
    args = taxInvoiceAvailable_args()
    args.addressId = addressId
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_taxInvoiceAvailable(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = taxInvoiceAvailable_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "taxInvoiceAvailable failed: unknown result");

  def getCartByValue(self, cartIds):
    """
    Parameters:
     - cartIds
    """
    self.send_getCartByValue(cartIds)
    return self.recv_getCartByValue()

  def send_getCartByValue(self, cartIds):
    self._oprot.writeMessageBegin('getCartByValue', TMessageType.CALL, self._seqid)
    args = getCartByValue_args()
    args.cartIds = cartIds
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getCartByValue(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getCartByValue_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getCartByValue failed: unknown result");

  def getCounterName(self, userIds):
    """
    Parameters:
     - userIds
    """
    self.send_getCounterName(userIds)
    return self.recv_getCounterName()

  def send_getCounterName(self, userIds):
    self._oprot.writeMessageBegin('getCounterName', TMessageType.CALL, self._seqid)
    args = getCounterName_args()
    args.userIds = userIds
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_getCounterName(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = getCounterName_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getCounterName failed: unknown result");

  def setWalletAmountInCart(self, cartId, wallet_amount):
    """
    Parameters:
     - cartId
     - wallet_amount
    """
    self.send_setWalletAmountInCart(cartId, wallet_amount)
    return self.recv_setWalletAmountInCart()

  def send_setWalletAmountInCart(self, cartId, wallet_amount):
    self._oprot.writeMessageBegin('setWalletAmountInCart', TMessageType.CALL, self._seqid)
    args = setWalletAmountInCart_args()
    args.cartId = cartId
    args.wallet_amount = wallet_amount
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_setWalletAmountInCart(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = setWalletAmountInCart_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "setWalletAmountInCart failed: unknown result");

  def addItemPricingToCart(self, cartId, itemPriceQuantityList):
    """
    Parameters:
     - cartId
     - itemPriceQuantityList
    """
    self.send_addItemPricingToCart(cartId, itemPriceQuantityList)
    return self.recv_addItemPricingToCart()

  def send_addItemPricingToCart(self, cartId, itemPriceQuantityList):
    self._oprot.writeMessageBegin('addItemPricingToCart', TMessageType.CALL, self._seqid)
    args = addItemPricingToCart_args()
    args.cartId = cartId
    args.itemPriceQuantityList = itemPriceQuantityList
    args.write(self._oprot)
    self._oprot.writeMessageEnd()
    self._oprot.trans.flush()

  def recv_addItemPricingToCart(self, ):
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
    if mtype == TMessageType.EXCEPTION:
      x = TApplicationException()
      x.read(self._iprot)
      self._iprot.readMessageEnd()
      raise x
    result = addItemPricingToCart_result()
    result.read(self._iprot)
    self._iprot.readMessageEnd()
    if result.success is not None:
      return result.success
    raise TApplicationException(TApplicationException.MISSING_RESULT, "addItemPricingToCart failed: unknown result");


class Processor(shop2020.thriftpy.generic.GenericService.Processor, Iface, TProcessor):
  def __init__(self, handler):
    shop2020.thriftpy.generic.GenericService.Processor.__init__(self, handler)
    self._processMap["createAnonymousUser"] = Processor.process_createAnonymousUser
    self._processMap["getUserById"] = Processor.process_getUserById
    self._processMap["getUserByCartId"] = Processor.process_getUserByCartId
    self._processMap["getUserByEmail"] = Processor.process_getUserByEmail
    self._processMap["getUserByMobileNumber"] = Processor.process_getUserByMobileNumber
    self._processMap["createUser"] = Processor.process_createUser
    self._processMap["updateUser"] = Processor.process_updateUser
    self._processMap["authenticateUser"] = Processor.process_authenticateUser
    self._processMap["userExists"] = Processor.process_userExists
    self._processMap["addAddressForUser"] = Processor.process_addAddressForUser
    self._processMap["removeAddressForUser"] = Processor.process_removeAddressForUser
    self._processMap["updateAddress"] = Processor.process_updateAddress
    self._processMap["updateCounter"] = Processor.process_updateCounter
    self._processMap["setUserAsLoggedIn"] = Processor.process_setUserAsLoggedIn
    self._processMap["setUserAsLoggedOut"] = Processor.process_setUserAsLoggedOut
    self._processMap["setDefaultAddress"] = Processor.process_setDefaultAddress
    self._processMap["updatePassword"] = Processor.process_updatePassword
    self._processMap["forgotPassword"] = Processor.process_forgotPassword
    self._processMap["getAllAddressesForUser"] = Processor.process_getAllAddressesForUser
    self._processMap["getAddressById"] = Processor.process_getAddressById
    self._processMap["getDefaultAddressId"] = Processor.process_getDefaultAddressId
    self._processMap["getDefaultPincode"] = Processor.process_getDefaultPincode
    self._processMap["saveUserCommunication"] = Processor.process_saveUserCommunication
    self._processMap["getUserCommunicationById"] = Processor.process_getUserCommunicationById
    self._processMap["getUserCommunicationByUser"] = Processor.process_getUserCommunicationByUser
    self._processMap["getAllUserCommunications"] = Processor.process_getAllUserCommunications
    self._processMap["removeUserCommunication"] = Processor.process_removeUserCommunication
    self._processMap["createMasterAffiliate"] = Processor.process_createMasterAffiliate
    self._processMap["getAllMasterAffiliates"] = Processor.process_getAllMasterAffiliates
    self._processMap["getMasterAffiliateById"] = Processor.process_getMasterAffiliateById
    self._processMap["getMasterAffiliateByName"] = Processor.process_getMasterAffiliateByName
    self._processMap["createAffiliate"] = Processor.process_createAffiliate
    self._processMap["getAffiliateById"] = Processor.process_getAffiliateById
    self._processMap["getAffiliateByName"] = Processor.process_getAffiliateByName
    self._processMap["getTrackerById"] = Processor.process_getTrackerById
    self._processMap["getAffiliatesByMasterAffiliate"] = Processor.process_getAffiliatesByMasterAffiliate
    self._processMap["addTrackLog"] = Processor.process_addTrackLog
    self._processMap["getTrackLogById"] = Processor.process_getTrackLogById
    self._processMap["getTrackLogsByAffiliate"] = Processor.process_getTrackLogsByAffiliate
    self._processMap["getTrackLogsByUser"] = Processor.process_getTrackLogsByUser
    self._processMap["getTrackLogs"] = Processor.process_getTrackLogs
    self._processMap["getCurrentCart"] = Processor.process_getCurrentCart
    self._processMap["getCart"] = Processor.process_getCart
    self._processMap["getCartsByTime"] = Processor.process_getCartsByTime
    self._processMap["addItemToCart"] = Processor.process_addItemToCart
    self._processMap["deleteItemFromCart"] = Processor.process_deleteItemFromCart
    self._processMap["addAddressToCart"] = Processor.process_addAddressToCart
    self._processMap["addStoreToCart"] = Processor.process_addStoreToCart
    self._processMap["applyCouponToCart"] = Processor.process_applyCouponToCart
    self._processMap["removeCoupon"] = Processor.process_removeCoupon
    self._processMap["deleteDiscountsFromCart"] = Processor.process_deleteDiscountsFromCart
    self._processMap["saveDiscounts"] = Processor.process_saveDiscounts
    self._processMap["createOrders"] = Processor.process_createOrders
    self._processMap["validateCart"] = Processor.process_validateCart
    self._processMap["validateCartWithDealerCoupon"] = Processor.process_validateCartWithDealerCoupon
    self._processMap["mergeCart"] = Processor.process_mergeCart
    self._processMap["checkOut"] = Processor.process_checkOut
    self._processMap["resetCart"] = Processor.process_resetCart
    self._processMap["getUserCount"] = Processor.process_getUserCount
    self._processMap["getAllUsers"] = Processor.process_getAllUsers
    self._processMap["getMyResearchItems"] = Processor.process_getMyResearchItems
    self._processMap["updateMyResearch"] = Processor.process_updateMyResearch
    self._processMap["deleteItemFromMyResearch"] = Processor.process_deleteItemFromMyResearch
    self._processMap["getBrowseHistoryItems"] = Processor.process_getBrowseHistoryItems
    self._processMap["updateBrowseHistory"] = Processor.process_updateBrowseHistory
    self._processMap["getCartsWithCouponCount"] = Processor.process_getCartsWithCouponCount
    self._processMap["increaseTrustLevel"] = Processor.process_increaseTrustLevel
    self._processMap["getTrustLevel"] = Processor.process_getTrustLevel
    self._processMap["showCODOption"] = Processor.process_showCODOption
    self._processMap["getUserEmails"] = Processor.process_getUserEmails
    self._processMap["insureItem"] = Processor.process_insureItem
    self._processMap["cancelInsurance"] = Processor.process_cancelInsurance
    self._processMap["storeInsuranceSpecificDetails"] = Processor.process_storeInsuranceSpecificDetails
    self._processMap["isInsuranceDetailPresent"] = Processor.process_isInsuranceDetailPresent
    self._processMap["getProductsAddedToCart"] = Processor.process_getProductsAddedToCart
    self._processMap["validateCartPlus"] = Processor.process_validateCartPlus
    self._processMap["isPrivateDealUser"] = Processor.process_isPrivateDealUser
    self._processMap["addPrivateDealUser"] = Processor.process_addPrivateDealUser
    self._processMap["changePrivateDealUserStatus"] = Processor.process_changePrivateDealUserStatus
    self._processMap["getPrivateDealUser"] = Processor.process_getPrivateDealUser
    self._processMap["registerCounter"] = Processor.process_registerCounter
    self._processMap["searchCounter"] = Processor.process_searchCounter
    self._processMap["getCounterByUserId"] = Processor.process_getCounterByUserId
    self._processMap["getAllUsersByCounter"] = Processor.process_getAllUsersByCounter
    self._processMap["getActiveAccessTokenForUser"] = Processor.process_getActiveAccessTokenForUser
    self._processMap["validateAccessToken"] = Processor.process_validateAccessToken
    self._processMap["addItemsToCart"] = Processor.process_addItemsToCart
    self._processMap["validateCartNew"] = Processor.process_validateCartNew
    self._processMap["isAddressEditableForCounter"] = Processor.process_isAddressEditableForCounter
    self._processMap["getBillingAddressForUser"] = Processor.process_getBillingAddressForUser
    self._processMap["isCreditorAssigned"] = Processor.process_isCreditorAssigned
    self._processMap["isTaxInvoiceEnabledUser"] = Processor.process_isTaxInvoiceEnabledUser
    self._processMap["taxInvoiceAvailable"] = Processor.process_taxInvoiceAvailable
    self._processMap["getCartByValue"] = Processor.process_getCartByValue
    self._processMap["getCounterName"] = Processor.process_getCounterName
    self._processMap["setWalletAmountInCart"] = Processor.process_setWalletAmountInCart
    self._processMap["addItemPricingToCart"] = Processor.process_addItemPricingToCart

  def process(self, iprot, oprot):
    (name, type, seqid) = iprot.readMessageBegin()
    if name not in self._processMap:
      iprot.skip(TType.STRUCT)
      iprot.readMessageEnd()
      x = TApplicationException(TApplicationException.UNKNOWN_METHOD, 'Unknown function %s' % (name))
      oprot.writeMessageBegin(name, TMessageType.EXCEPTION, seqid)
      x.write(oprot)
      oprot.writeMessageEnd()
      oprot.trans.flush()
      return
    else:
      self._processMap[name](self, seqid, iprot, oprot)
    return True

  def process_createAnonymousUser(self, seqid, iprot, oprot):
    args = createAnonymousUser_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = createAnonymousUser_result()
    try:
      result.success = self._handler.createAnonymousUser(args.jsessionId)
    except UserContextException, ucex:
      result.ucex = ucex
    oprot.writeMessageBegin("createAnonymousUser", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getUserById(self, seqid, iprot, oprot):
    args = getUserById_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getUserById_result()
    try:
      result.success = self._handler.getUserById(args.userId)
    except UserContextException, ucex:
      result.ucex = ucex
    oprot.writeMessageBegin("getUserById", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getUserByCartId(self, seqid, iprot, oprot):
    args = getUserByCartId_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getUserByCartId_result()
    try:
      result.success = self._handler.getUserByCartId(args.cartId)
    except UserContextException, ucex:
      result.ucex = ucex
    oprot.writeMessageBegin("getUserByCartId", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getUserByEmail(self, seqid, iprot, oprot):
    args = getUserByEmail_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getUserByEmail_result()
    try:
      result.success = self._handler.getUserByEmail(args.email)
    except UserContextException, ucex:
      result.ucex = ucex
    oprot.writeMessageBegin("getUserByEmail", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getUserByMobileNumber(self, seqid, iprot, oprot):
    args = getUserByMobileNumber_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getUserByMobileNumber_result()
    try:
      result.success = self._handler.getUserByMobileNumber(args.mobileNumber)
    except UserContextException, ucex:
      result.ucex = ucex
    oprot.writeMessageBegin("getUserByMobileNumber", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_createUser(self, seqid, iprot, oprot):
    args = createUser_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = createUser_result()
    try:
      result.success = self._handler.createUser(args.user)
    except UserContextException, ucex:
      result.ucex = ucex
    oprot.writeMessageBegin("createUser", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_updateUser(self, seqid, iprot, oprot):
    args = updateUser_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = updateUser_result()
    try:
      result.success = self._handler.updateUser(args.user)
    except UserContextException, ucex:
      result.ucex = ucex
    oprot.writeMessageBegin("updateUser", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_authenticateUser(self, seqid, iprot, oprot):
    args = authenticateUser_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = authenticateUser_result()
    try:
      result.success = self._handler.authenticateUser(args.email, args.password)
    except AuthenticationException, auex:
      result.auex = auex
    oprot.writeMessageBegin("authenticateUser", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_userExists(self, seqid, iprot, oprot):
    args = userExists_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = userExists_result()
    try:
      result.success = self._handler.userExists(args.email)
    except UserContextException, ucx:
      result.ucx = ucx
    oprot.writeMessageBegin("userExists", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_addAddressForUser(self, seqid, iprot, oprot):
    args = addAddressForUser_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = addAddressForUser_result()
    try:
      result.success = self._handler.addAddressForUser(args.userId, args.address, args.setDefault)
    except UserContextException, ucx:
      result.ucx = ucx
    oprot.writeMessageBegin("addAddressForUser", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_removeAddressForUser(self, seqid, iprot, oprot):
    args = removeAddressForUser_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = removeAddressForUser_result()
    try:
      result.success = self._handler.removeAddressForUser(args.userid, args.addressId)
    except UserContextException, ucx:
      result.ucx = ucx
    oprot.writeMessageBegin("removeAddressForUser", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_updateAddress(self, seqid, iprot, oprot):
    args = updateAddress_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = updateAddress_result()
    try:
      result.success = self._handler.updateAddress(args.address)
    except UserContextException, ucx:
      result.ucx = ucx
    oprot.writeMessageBegin("updateAddress", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_updateCounter(self, seqid, iprot, oprot):
    args = updateCounter_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = updateCounter_result()
    try:
      result.success = self._handler.updateCounter(args.counter)
    except UserContextException, ucx:
      result.ucx = ucx
    oprot.writeMessageBegin("updateCounter", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_setUserAsLoggedIn(self, seqid, iprot, oprot):
    args = setUserAsLoggedIn_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = setUserAsLoggedIn_result()
    try:
      result.success = self._handler.setUserAsLoggedIn(args.userId, args.timestamp)
    except UserContextException, ucx:
      result.ucx = ucx
    oprot.writeMessageBegin("setUserAsLoggedIn", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_setUserAsLoggedOut(self, seqid, iprot, oprot):
    args = setUserAsLoggedOut_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = setUserAsLoggedOut_result()
    try:
      result.success = self._handler.setUserAsLoggedOut(args.userid, args.timestamp)
    except UserContextException, ucx:
      result.ucx = ucx
    oprot.writeMessageBegin("setUserAsLoggedOut", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_setDefaultAddress(self, seqid, iprot, oprot):
    args = setDefaultAddress_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = setDefaultAddress_result()
    try:
      result.success = self._handler.setDefaultAddress(args.userid, args.addressId)
    except UserContextException, ucx:
      result.ucx = ucx
    oprot.writeMessageBegin("setDefaultAddress", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_updatePassword(self, seqid, iprot, oprot):
    args = updatePassword_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = updatePassword_result()
    try:
      result.success = self._handler.updatePassword(args.userid, args.oldPassword, args.newPassword)
    except UserContextException, ucx:
      result.ucx = ucx
    oprot.writeMessageBegin("updatePassword", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_forgotPassword(self, seqid, iprot, oprot):
    args = forgotPassword_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = forgotPassword_result()
    try:
      result.success = self._handler.forgotPassword(args.email, args.newPassword)
    except UserContextException, ucx:
      result.ucx = ucx
    oprot.writeMessageBegin("forgotPassword", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getAllAddressesForUser(self, seqid, iprot, oprot):
    args = getAllAddressesForUser_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getAllAddressesForUser_result()
    try:
      result.success = self._handler.getAllAddressesForUser(args.userId)
    except UserContextException, ucx:
      result.ucx = ucx
    oprot.writeMessageBegin("getAllAddressesForUser", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getAddressById(self, seqid, iprot, oprot):
    args = getAddressById_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getAddressById_result()
    try:
      result.success = self._handler.getAddressById(args.addressId)
    except UserContextException, ucx:
      result.ucx = ucx
    oprot.writeMessageBegin("getAddressById", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getDefaultAddressId(self, seqid, iprot, oprot):
    args = getDefaultAddressId_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getDefaultAddressId_result()
    try:
      result.success = self._handler.getDefaultAddressId(args.userId)
    except UserContextException, ucx:
      result.ucx = ucx
    oprot.writeMessageBegin("getDefaultAddressId", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getDefaultPincode(self, seqid, iprot, oprot):
    args = getDefaultPincode_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getDefaultPincode_result()
    try:
      result.success = self._handler.getDefaultPincode(args.userId)
    except UserContextException, ucx:
      result.ucx = ucx
    oprot.writeMessageBegin("getDefaultPincode", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_saveUserCommunication(self, seqid, iprot, oprot):
    args = saveUserCommunication_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = saveUserCommunication_result()
    try:
      result.success = self._handler.saveUserCommunication(args.userId, args.replyTo, args.communicationType, args.orderId, args.airwaybillNo, args.productName, args.subject, args.message)
    except UserCommunicationException, ucx:
      result.ucx = ucx
    oprot.writeMessageBegin("saveUserCommunication", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getUserCommunicationById(self, seqid, iprot, oprot):
    args = getUserCommunicationById_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getUserCommunicationById_result()
    try:
      result.success = self._handler.getUserCommunicationById(args.id)
    except UserCommunicationException, ucx:
      result.ucx = ucx
    oprot.writeMessageBegin("getUserCommunicationById", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getUserCommunicationByUser(self, seqid, iprot, oprot):
    args = getUserCommunicationByUser_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getUserCommunicationByUser_result()
    try:
      result.success = self._handler.getUserCommunicationByUser(args.userId)
    except UserCommunicationException, ucx:
      result.ucx = ucx
    oprot.writeMessageBegin("getUserCommunicationByUser", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getAllUserCommunications(self, seqid, iprot, oprot):
    args = getAllUserCommunications_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getAllUserCommunications_result()
    try:
      result.success = self._handler.getAllUserCommunications()
    except UserCommunicationException, ucx:
      result.ucx = ucx
    oprot.writeMessageBegin("getAllUserCommunications", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_removeUserCommunication(self, seqid, iprot, oprot):
    args = removeUserCommunication_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = removeUserCommunication_result()
    try:
      self._handler.removeUserCommunication(args.id)
    except UserCommunicationException, ucx:
      result.ucx = ucx
    oprot.writeMessageBegin("removeUserCommunication", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_createMasterAffiliate(self, seqid, iprot, oprot):
    args = createMasterAffiliate_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = createMasterAffiliate_result()
    try:
      result.success = self._handler.createMasterAffiliate(args.name, args.addedOn)
    except UserAffiliateException, utx:
      result.utx = utx
    oprot.writeMessageBegin("createMasterAffiliate", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getAllMasterAffiliates(self, seqid, iprot, oprot):
    args = getAllMasterAffiliates_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getAllMasterAffiliates_result()
    try:
      result.success = self._handler.getAllMasterAffiliates()
    except UserAffiliateException, utx:
      result.utx = utx
    oprot.writeMessageBegin("getAllMasterAffiliates", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getMasterAffiliateById(self, seqid, iprot, oprot):
    args = getMasterAffiliateById_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getMasterAffiliateById_result()
    try:
      result.success = self._handler.getMasterAffiliateById(args.id)
    except UserAffiliateException, utx:
      result.utx = utx
    oprot.writeMessageBegin("getMasterAffiliateById", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getMasterAffiliateByName(self, seqid, iprot, oprot):
    args = getMasterAffiliateByName_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getMasterAffiliateByName_result()
    try:
      result.success = self._handler.getMasterAffiliateByName(args.name)
    except UserAffiliateException, utx:
      result.utx = utx
    oprot.writeMessageBegin("getMasterAffiliateByName", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_createAffiliate(self, seqid, iprot, oprot):
    args = createAffiliate_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = createAffiliate_result()
    try:
      result.success = self._handler.createAffiliate(args.name, args.url, args.masterAffiliateId, args.addedOn)
    except UserAffiliateException, utx:
      result.utx = utx
    oprot.writeMessageBegin("createAffiliate", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getAffiliateById(self, seqid, iprot, oprot):
    args = getAffiliateById_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getAffiliateById_result()
    try:
      result.success = self._handler.getAffiliateById(args.id)
    except UserAffiliateException, utx:
      result.utx = utx
    oprot.writeMessageBegin("getAffiliateById", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getAffiliateByName(self, seqid, iprot, oprot):
    args = getAffiliateByName_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getAffiliateByName_result()
    try:
      result.success = self._handler.getAffiliateByName(args.name)
    except UserAffiliateException, utx:
      result.utx = utx
    oprot.writeMessageBegin("getAffiliateByName", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getTrackerById(self, seqid, iprot, oprot):
    args = getTrackerById_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getTrackerById_result()
    try:
      result.success = self._handler.getTrackerById(args.id)
    except UserAffiliateException, utx:
      result.utx = utx
    oprot.writeMessageBegin("getTrackerById", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getAffiliatesByMasterAffiliate(self, seqid, iprot, oprot):
    args = getAffiliatesByMasterAffiliate_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getAffiliatesByMasterAffiliate_result()
    try:
      result.success = self._handler.getAffiliatesByMasterAffiliate(args.id)
    except UserAffiliateException, utx:
      result.utx = utx
    oprot.writeMessageBegin("getAffiliatesByMasterAffiliate", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_addTrackLog(self, seqid, iprot, oprot):
    args = addTrackLog_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = addTrackLog_result()
    try:
      result.success = self._handler.addTrackLog(args.affiliateId, args.userId, args.event, args.url, args.data, args.addedOn)
    except UserAffiliateException, utx:
      result.utx = utx
    oprot.writeMessageBegin("addTrackLog", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getTrackLogById(self, seqid, iprot, oprot):
    args = getTrackLogById_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getTrackLogById_result()
    try:
      result.success = self._handler.getTrackLogById(args.id)
    except UserAffiliateException, utx:
      result.utx = utx
    oprot.writeMessageBegin("getTrackLogById", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getTrackLogsByAffiliate(self, seqid, iprot, oprot):
    args = getTrackLogsByAffiliate_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getTrackLogsByAffiliate_result()
    try:
      result.success = self._handler.getTrackLogsByAffiliate(args.affiliateId, args.startDate, args.endDate)
    except UserAffiliateException, utx:
      result.utx = utx
    oprot.writeMessageBegin("getTrackLogsByAffiliate", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getTrackLogsByUser(self, seqid, iprot, oprot):
    args = getTrackLogsByUser_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getTrackLogsByUser_result()
    try:
      result.success = self._handler.getTrackLogsByUser(args.userId)
    except UserAffiliateException, utx:
      result.utx = utx
    oprot.writeMessageBegin("getTrackLogsByUser", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getTrackLogs(self, seqid, iprot, oprot):
    args = getTrackLogs_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getTrackLogs_result()
    try:
      result.success = self._handler.getTrackLogs(args.userId, args.event, args.url)
    except UserAffiliateException, utx:
      result.utx = utx
    oprot.writeMessageBegin("getTrackLogs", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getCurrentCart(self, seqid, iprot, oprot):
    args = getCurrentCart_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getCurrentCart_result()
    try:
      result.success = self._handler.getCurrentCart(args.userId)
    except ShoppingCartException, scx:
      result.scx = scx
    oprot.writeMessageBegin("getCurrentCart", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getCart(self, seqid, iprot, oprot):
    args = getCart_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getCart_result()
    try:
      result.success = self._handler.getCart(args.cartId)
    except ShoppingCartException, scx:
      result.scx = scx
    oprot.writeMessageBegin("getCart", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getCartsByTime(self, seqid, iprot, oprot):
    args = getCartsByTime_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getCartsByTime_result()
    try:
      result.success = self._handler.getCartsByTime(args.from_time, args.to_time, args.status)
    except ShoppingCartException, scx:
      result.scx = scx
    oprot.writeMessageBegin("getCartsByTime", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_addItemToCart(self, seqid, iprot, oprot):
    args = addItemToCart_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = addItemToCart_result()
    try:
      result.success = self._handler.addItemToCart(args.cartId, args.itemId, args.quantity, args.sourceId)
    except ShoppingCartException, scx:
      result.scx = scx
    oprot.writeMessageBegin("addItemToCart", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_deleteItemFromCart(self, seqid, iprot, oprot):
    args = deleteItemFromCart_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = deleteItemFromCart_result()
    try:
      self._handler.deleteItemFromCart(args.cartId, args.itemId)
    except ShoppingCartException, scx:
      result.scx = scx
    oprot.writeMessageBegin("deleteItemFromCart", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_addAddressToCart(self, seqid, iprot, oprot):
    args = addAddressToCart_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = addAddressToCart_result()
    try:
      self._handler.addAddressToCart(args.cartId, args.addressId)
    except ShoppingCartException, scx:
      result.scx = scx
    oprot.writeMessageBegin("addAddressToCart", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_addStoreToCart(self, seqid, iprot, oprot):
    args = addStoreToCart_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = addStoreToCart_result()
    try:
      self._handler.addStoreToCart(args.cartId, args.storeId)
    except ShoppingCartException, scx:
      result.scx = scx
    oprot.writeMessageBegin("addStoreToCart", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_applyCouponToCart(self, seqid, iprot, oprot):
    args = applyCouponToCart_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = applyCouponToCart_result()
    try:
      self._handler.applyCouponToCart(args.cart, args.couponCode)
    except ShoppingCartException, scx:
      result.scx = scx
    oprot.writeMessageBegin("applyCouponToCart", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_removeCoupon(self, seqid, iprot, oprot):
    args = removeCoupon_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = removeCoupon_result()
    try:
      self._handler.removeCoupon(args.cartId)
    except ShoppingCartException, scx:
      result.scx = scx
    oprot.writeMessageBegin("removeCoupon", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_deleteDiscountsFromCart(self, seqid, iprot, oprot):
    args = deleteDiscountsFromCart_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = deleteDiscountsFromCart_result()
    try:
      self._handler.deleteDiscountsFromCart(args.cartId)
    except ShoppingCartException, scx:
      result.scx = scx
    oprot.writeMessageBegin("deleteDiscountsFromCart", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_saveDiscounts(self, seqid, iprot, oprot):
    args = saveDiscounts_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = saveDiscounts_result()
    try:
      self._handler.saveDiscounts(args.discounts)
    except ShoppingCartException, scx:
      result.scx = scx
    oprot.writeMessageBegin("saveDiscounts", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_createOrders(self, seqid, iprot, oprot):
    args = createOrders_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = createOrders_result()
    try:
      result.success = self._handler.createOrders(args.cartId, args.sessionSource, args.sessionStartTime, args.firstSource, args.firstSourceTime, args.userId, args.schemeId, args.orderSource, args.selfPickup)
    except ShoppingCartException, scx:
      result.scx = scx
    oprot.writeMessageBegin("createOrders", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_validateCart(self, seqid, iprot, oprot):
    args = validateCart_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = validateCart_result()
    try:
      result.success = self._handler.validateCart(args.cartId, args.sourceId)
    except ShoppingCartException, scex:
      result.scex = scex
    oprot.writeMessageBegin("validateCart", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_validateCartWithDealerCoupon(self, seqid, iprot, oprot):
    args = validateCartWithDealerCoupon_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = validateCartWithDealerCoupon_result()
    try:
      result.success = self._handler.validateCartWithDealerCoupon(args.cartId, args.sourceId, args.dealCoupon)
    except ShoppingCartException, scex:
      result.scex = scex
    oprot.writeMessageBegin("validateCartWithDealerCoupon", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_mergeCart(self, seqid, iprot, oprot):
    args = mergeCart_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = mergeCart_result()
    self._handler.mergeCart(args.fromCartId, args.toCartId)
    oprot.writeMessageBegin("mergeCart", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_checkOut(self, seqid, iprot, oprot):
    args = checkOut_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = checkOut_result()
    try:
      result.success = self._handler.checkOut(args.cartId)
    except ShoppingCartException, scex:
      result.scex = scex
    oprot.writeMessageBegin("checkOut", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_resetCart(self, seqid, iprot, oprot):
    args = resetCart_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = resetCart_result()
    try:
      result.success = self._handler.resetCart(args.cartId, args.items)
    except ShoppingCartException, scex:
      result.scex = scex
    oprot.writeMessageBegin("resetCart", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getUserCount(self, seqid, iprot, oprot):
    args = getUserCount_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getUserCount_result()
    result.success = self._handler.getUserCount(args.userType)
    oprot.writeMessageBegin("getUserCount", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getAllUsers(self, seqid, iprot, oprot):
    args = getAllUsers_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getAllUsers_result()
    result.success = self._handler.getAllUsers(args.userType, args.startDate, args.endDate)
    oprot.writeMessageBegin("getAllUsers", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getMyResearchItems(self, seqid, iprot, oprot):
    args = getMyResearchItems_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getMyResearchItems_result()
    try:
      result.success = self._handler.getMyResearchItems(args.userId)
    except WidgetException, scx:
      result.scx = scx
    oprot.writeMessageBegin("getMyResearchItems", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_updateMyResearch(self, seqid, iprot, oprot):
    args = updateMyResearch_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = updateMyResearch_result()
    try:
      result.success = self._handler.updateMyResearch(args.userId, args.itemId)
    except WidgetException, scx:
      result.scx = scx
    oprot.writeMessageBegin("updateMyResearch", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_deleteItemFromMyResearch(self, seqid, iprot, oprot):
    args = deleteItemFromMyResearch_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = deleteItemFromMyResearch_result()
    try:
      self._handler.deleteItemFromMyResearch(args.userId, args.itemId)
    except WidgetException, scx:
      result.scx = scx
    oprot.writeMessageBegin("deleteItemFromMyResearch", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getBrowseHistoryItems(self, seqid, iprot, oprot):
    args = getBrowseHistoryItems_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getBrowseHistoryItems_result()
    try:
      result.success = self._handler.getBrowseHistoryItems(args.userId)
    except WidgetException, scx:
      result.scx = scx
    oprot.writeMessageBegin("getBrowseHistoryItems", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_updateBrowseHistory(self, seqid, iprot, oprot):
    args = updateBrowseHistory_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = updateBrowseHistory_result()
    self._handler.updateBrowseHistory(args.userId, args.itemId)
    oprot.writeMessageBegin("updateBrowseHistory", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getCartsWithCouponCount(self, seqid, iprot, oprot):
    args = getCartsWithCouponCount_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getCartsWithCouponCount_result()
    result.success = self._handler.getCartsWithCouponCount(args.couponCode)
    oprot.writeMessageBegin("getCartsWithCouponCount", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_increaseTrustLevel(self, seqid, iprot, oprot):
    args = increaseTrustLevel_args()
    args.read(iprot)
    iprot.readMessageEnd()
    self._handler.increaseTrustLevel(args.userId, args.trustLevelDelta)
    return

  def process_getTrustLevel(self, seqid, iprot, oprot):
    args = getTrustLevel_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getTrustLevel_result()
    result.success = self._handler.getTrustLevel(args.userId)
    oprot.writeMessageBegin("getTrustLevel", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_showCODOption(self, seqid, iprot, oprot):
    args = showCODOption_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = showCODOption_result()
    result.success = self._handler.showCODOption(args.cartId, args.sourceId, args.pincode)
    oprot.writeMessageBegin("showCODOption", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getUserEmails(self, seqid, iprot, oprot):
    args = getUserEmails_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getUserEmails_result()
    result.success = self._handler.getUserEmails(args.startDate, args.endDate)
    oprot.writeMessageBegin("getUserEmails", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_insureItem(self, seqid, iprot, oprot):
    args = insureItem_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = insureItem_result()
    result.success = self._handler.insureItem(args.itemId, args.cartId, args.toInsure, args.insurerType)
    oprot.writeMessageBegin("insureItem", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_cancelInsurance(self, seqid, iprot, oprot):
    args = cancelInsurance_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = cancelInsurance_result()
    result.success = self._handler.cancelInsurance(args.cartId)
    oprot.writeMessageBegin("cancelInsurance", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_storeInsuranceSpecificDetails(self, seqid, iprot, oprot):
    args = storeInsuranceSpecificDetails_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = storeInsuranceSpecificDetails_result()
    result.success = self._handler.storeInsuranceSpecificDetails(args.addressId, args.dob, args.guardianName)
    oprot.writeMessageBegin("storeInsuranceSpecificDetails", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_isInsuranceDetailPresent(self, seqid, iprot, oprot):
    args = isInsuranceDetailPresent_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = isInsuranceDetailPresent_result()
    result.success = self._handler.isInsuranceDetailPresent(args.addressId)
    oprot.writeMessageBegin("isInsuranceDetailPresent", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getProductsAddedToCart(self, seqid, iprot, oprot):
    args = getProductsAddedToCart_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getProductsAddedToCart_result()
    result.success = self._handler.getProductsAddedToCart(args.startDate, args.endDate)
    oprot.writeMessageBegin("getProductsAddedToCart", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_validateCartPlus(self, seqid, iprot, oprot):
    args = validateCartPlus_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = validateCartPlus_result()
    try:
      result.success = self._handler.validateCartPlus(args.cartId, args.sourceId, args.dealerCoupon)
    except ShoppingCartException, scex:
      result.scex = scex
    oprot.writeMessageBegin("validateCartPlus", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_isPrivateDealUser(self, seqid, iprot, oprot):
    args = isPrivateDealUser_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = isPrivateDealUser_result()
    result.success = self._handler.isPrivateDealUser(args.userId)
    oprot.writeMessageBegin("isPrivateDealUser", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_addPrivateDealUser(self, seqid, iprot, oprot):
    args = addPrivateDealUser_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = addPrivateDealUser_result()
    result.success = self._handler.addPrivateDealUser(args.userId)
    oprot.writeMessageBegin("addPrivateDealUser", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_changePrivateDealUserStatus(self, seqid, iprot, oprot):
    args = changePrivateDealUserStatus_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = changePrivateDealUserStatus_result()
    result.success = self._handler.changePrivateDealUserStatus(args.userId, args.isActive)
    oprot.writeMessageBegin("changePrivateDealUserStatus", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getPrivateDealUser(self, seqid, iprot, oprot):
    args = getPrivateDealUser_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getPrivateDealUser_result()
    result.success = self._handler.getPrivateDealUser(args.userId)
    oprot.writeMessageBegin("getPrivateDealUser", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_registerCounter(self, seqid, iprot, oprot):
    args = registerCounter_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = registerCounter_result()
    result.success = self._handler.registerCounter(args.counter, args.userId)
    oprot.writeMessageBegin("registerCounter", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_searchCounter(self, seqid, iprot, oprot):
    args = searchCounter_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = searchCounter_result()
    result.success = self._handler.searchCounter(args.type1, args.searchString)
    oprot.writeMessageBegin("searchCounter", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getCounterByUserId(self, seqid, iprot, oprot):
    args = getCounterByUserId_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getCounterByUserId_result()
    result.success = self._handler.getCounterByUserId(args.userId)
    oprot.writeMessageBegin("getCounterByUserId", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getAllUsersByCounter(self, seqid, iprot, oprot):
    args = getAllUsersByCounter_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getAllUsersByCounter_result()
    result.success = self._handler.getAllUsersByCounter(args.counterId)
    oprot.writeMessageBegin("getAllUsersByCounter", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getActiveAccessTokenForUser(self, seqid, iprot, oprot):
    args = getActiveAccessTokenForUser_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getActiveAccessTokenForUser_result()
    result.success = self._handler.getActiveAccessTokenForUser(args.userId, args.source)
    oprot.writeMessageBegin("getActiveAccessTokenForUser", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_validateAccessToken(self, seqid, iprot, oprot):
    args = validateAccessToken_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = validateAccessToken_result()
    result.success = self._handler.validateAccessToken(args.accessToken)
    oprot.writeMessageBegin("validateAccessToken", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_addItemsToCart(self, seqid, iprot, oprot):
    args = addItemsToCart_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = addItemsToCart_result()
    result.success = self._handler.addItemsToCart(args.cartId, args.itemQty, args.couponCode)
    oprot.writeMessageBegin("addItemsToCart", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_validateCartNew(self, seqid, iprot, oprot):
    args = validateCartNew_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = validateCartNew_result()
    result.success = self._handler.validateCartNew(args.cartId, args.pinCode, args.sourceId)
    oprot.writeMessageBegin("validateCartNew", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_isAddressEditableForCounter(self, seqid, iprot, oprot):
    args = isAddressEditableForCounter_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = isAddressEditableForCounter_result()
    result.success = self._handler.isAddressEditableForCounter(args.userId)
    oprot.writeMessageBegin("isAddressEditableForCounter", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getBillingAddressForUser(self, seqid, iprot, oprot):
    args = getBillingAddressForUser_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getBillingAddressForUser_result()
    result.success = self._handler.getBillingAddressForUser(args.userId)
    oprot.writeMessageBegin("getBillingAddressForUser", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_isCreditorAssigned(self, seqid, iprot, oprot):
    args = isCreditorAssigned_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = isCreditorAssigned_result()
    result.success = self._handler.isCreditorAssigned(args.userId)
    oprot.writeMessageBegin("isCreditorAssigned", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_isTaxInvoiceEnabledUser(self, seqid, iprot, oprot):
    args = isTaxInvoiceEnabledUser_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = isTaxInvoiceEnabledUser_result()
    result.success = self._handler.isTaxInvoiceEnabledUser(args.userId)
    oprot.writeMessageBegin("isTaxInvoiceEnabledUser", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_taxInvoiceAvailable(self, seqid, iprot, oprot):
    args = taxInvoiceAvailable_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = taxInvoiceAvailable_result()
    result.success = self._handler.taxInvoiceAvailable(args.addressId)
    oprot.writeMessageBegin("taxInvoiceAvailable", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getCartByValue(self, seqid, iprot, oprot):
    args = getCartByValue_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getCartByValue_result()
    result.success = self._handler.getCartByValue(args.cartIds)
    oprot.writeMessageBegin("getCartByValue", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_getCounterName(self, seqid, iprot, oprot):
    args = getCounterName_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = getCounterName_result()
    result.success = self._handler.getCounterName(args.userIds)
    oprot.writeMessageBegin("getCounterName", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_setWalletAmountInCart(self, seqid, iprot, oprot):
    args = setWalletAmountInCart_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = setWalletAmountInCart_result()
    result.success = self._handler.setWalletAmountInCart(args.cartId, args.wallet_amount)
    oprot.writeMessageBegin("setWalletAmountInCart", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()

  def process_addItemPricingToCart(self, seqid, iprot, oprot):
    args = addItemPricingToCart_args()
    args.read(iprot)
    iprot.readMessageEnd()
    result = addItemPricingToCart_result()
    result.success = self._handler.addItemPricingToCart(args.cartId, args.itemPriceQuantityList)
    oprot.writeMessageBegin("addItemPricingToCart", TMessageType.REPLY, seqid)
    result.write(oprot)
    oprot.writeMessageEnd()
    oprot.trans.flush()


# HELPER FUNCTIONS AND STRUCTURES

class createAnonymousUser_args:
  """
  Attributes:
   - jsessionId
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRING, 'jsessionId', None, None, ), # 1
  )

  def __init__(self, jsessionId=None,):
    self.jsessionId = jsessionId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRING:
          self.jsessionId = iprot.readString();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('createAnonymousUser_args')
    if self.jsessionId is not None:
      oprot.writeFieldBegin('jsessionId', TType.STRING, 1)
      oprot.writeString(self.jsessionId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class createAnonymousUser_result:
  """
  Attributes:
   - success
   - ucex
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (User, User.thrift_spec), None, ), # 0
    (1, TType.STRUCT, 'ucex', (UserContextException, UserContextException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucex=None,):
    self.success = success
    self.ucex = ucex

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = User()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucex = UserContextException()
          self.ucex.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('createAnonymousUser_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    if self.ucex is not None:
      oprot.writeFieldBegin('ucex', TType.STRUCT, 1)
      self.ucex.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getUserById_args:
  """
  Attributes:
   - userId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
  )

  def __init__(self, userId=None,):
    self.userId = userId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getUserById_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getUserById_result:
  """
  Attributes:
   - success
   - ucex
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (User, User.thrift_spec), None, ), # 0
    (1, TType.STRUCT, 'ucex', (UserContextException, UserContextException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucex=None,):
    self.success = success
    self.ucex = ucex

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = User()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucex = UserContextException()
          self.ucex.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getUserById_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    if self.ucex is not None:
      oprot.writeFieldBegin('ucex', TType.STRUCT, 1)
      self.ucex.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getUserByCartId_args:
  """
  Attributes:
   - cartId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'cartId', None, None, ), # 1
  )

  def __init__(self, cartId=None,):
    self.cartId = cartId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.cartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getUserByCartId_args')
    if self.cartId is not None:
      oprot.writeFieldBegin('cartId', TType.I64, 1)
      oprot.writeI64(self.cartId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getUserByCartId_result:
  """
  Attributes:
   - success
   - ucex
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (User, User.thrift_spec), None, ), # 0
    (1, TType.STRUCT, 'ucex', (UserContextException, UserContextException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucex=None,):
    self.success = success
    self.ucex = ucex

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = User()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucex = UserContextException()
          self.ucex.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getUserByCartId_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    if self.ucex is not None:
      oprot.writeFieldBegin('ucex', TType.STRUCT, 1)
      self.ucex.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getUserByEmail_args:
  """
  Attributes:
   - email
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRING, 'email', None, None, ), # 1
  )

  def __init__(self, email=None,):
    self.email = email

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRING:
          self.email = iprot.readString();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getUserByEmail_args')
    if self.email is not None:
      oprot.writeFieldBegin('email', TType.STRING, 1)
      oprot.writeString(self.email)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getUserByEmail_result:
  """
  Attributes:
   - success
   - ucex
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (User, User.thrift_spec), None, ), # 0
    (1, TType.STRUCT, 'ucex', (UserContextException, UserContextException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucex=None,):
    self.success = success
    self.ucex = ucex

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = User()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucex = UserContextException()
          self.ucex.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getUserByEmail_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    if self.ucex is not None:
      oprot.writeFieldBegin('ucex', TType.STRUCT, 1)
      self.ucex.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getUserByMobileNumber_args:
  """
  Attributes:
   - mobileNumber
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'mobileNumber', None, None, ), # 1
  )

  def __init__(self, mobileNumber=None,):
    self.mobileNumber = mobileNumber

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.mobileNumber = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getUserByMobileNumber_args')
    if self.mobileNumber is not None:
      oprot.writeFieldBegin('mobileNumber', TType.I64, 1)
      oprot.writeI64(self.mobileNumber)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getUserByMobileNumber_result:
  """
  Attributes:
   - success
   - ucex
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (User, User.thrift_spec), None, ), # 0
    (1, TType.STRUCT, 'ucex', (UserContextException, UserContextException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucex=None,):
    self.success = success
    self.ucex = ucex

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = User()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucex = UserContextException()
          self.ucex.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getUserByMobileNumber_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    if self.ucex is not None:
      oprot.writeFieldBegin('ucex', TType.STRUCT, 1)
      self.ucex.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class createUser_args:
  """
  Attributes:
   - user
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRUCT, 'user', (User, User.thrift_spec), None, ), # 1
  )

  def __init__(self, user=None,):
    self.user = user

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRUCT:
          self.user = User()
          self.user.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('createUser_args')
    if self.user is not None:
      oprot.writeFieldBegin('user', TType.STRUCT, 1)
      self.user.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class createUser_result:
  """
  Attributes:
   - success
   - ucex
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (User, User.thrift_spec), None, ), # 0
    (1, TType.STRUCT, 'ucex', (UserContextException, UserContextException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucex=None,):
    self.success = success
    self.ucex = ucex

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = User()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucex = UserContextException()
          self.ucex.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('createUser_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    if self.ucex is not None:
      oprot.writeFieldBegin('ucex', TType.STRUCT, 1)
      self.ucex.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class updateUser_args:
  """
  Attributes:
   - user
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRUCT, 'user', (User, User.thrift_spec), None, ), # 1
  )

  def __init__(self, user=None,):
    self.user = user

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRUCT:
          self.user = User()
          self.user.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('updateUser_args')
    if self.user is not None:
      oprot.writeFieldBegin('user', TType.STRUCT, 1)
      self.user.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class updateUser_result:
  """
  Attributes:
   - success
   - ucex
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (User, User.thrift_spec), None, ), # 0
    (1, TType.STRUCT, 'ucex', (UserContextException, UserContextException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucex=None,):
    self.success = success
    self.ucex = ucex

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = User()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucex = UserContextException()
          self.ucex.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('updateUser_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    if self.ucex is not None:
      oprot.writeFieldBegin('ucex', TType.STRUCT, 1)
      self.ucex.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class authenticateUser_args:
  """
  Attributes:
   - email
   - password
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRING, 'email', None, None, ), # 1
    (2, TType.STRING, 'password', None, None, ), # 2
  )

  def __init__(self, email=None, password=None,):
    self.email = email
    self.password = password

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRING:
          self.email = iprot.readString();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.STRING:
          self.password = iprot.readString();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('authenticateUser_args')
    if self.email is not None:
      oprot.writeFieldBegin('email', TType.STRING, 1)
      oprot.writeString(self.email)
      oprot.writeFieldEnd()
    if self.password is not None:
      oprot.writeFieldBegin('password', TType.STRING, 2)
      oprot.writeString(self.password)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class authenticateUser_result:
  """
  Attributes:
   - success
   - auex
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (User, User.thrift_spec), None, ), # 0
    (1, TType.STRUCT, 'auex', (AuthenticationException, AuthenticationException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, auex=None,):
    self.success = success
    self.auex = auex

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = User()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.auex = AuthenticationException()
          self.auex.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('authenticateUser_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    if self.auex is not None:
      oprot.writeFieldBegin('auex', TType.STRUCT, 1)
      self.auex.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class userExists_args:
  """
  Attributes:
   - email
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRING, 'email', None, None, ), # 1
  )

  def __init__(self, email=None,):
    self.email = email

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRING:
          self.email = iprot.readString();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('userExists_args')
    if self.email is not None:
      oprot.writeFieldBegin('email', TType.STRING, 1)
      oprot.writeString(self.email)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class userExists_result:
  """
  Attributes:
   - success
   - ucx
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
    (1, TType.STRUCT, 'ucx', (UserContextException, UserContextException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucx=None,):
    self.success = success
    self.ucx = ucx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucx = UserContextException()
          self.ucx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('userExists_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    if self.ucx is not None:
      oprot.writeFieldBegin('ucx', TType.STRUCT, 1)
      self.ucx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class addAddressForUser_args:
  """
  Attributes:
   - userId
   - address
   - setDefault
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
    (2, TType.STRUCT, 'address', (Address, Address.thrift_spec), None, ), # 2
    (3, TType.BOOL, 'setDefault', None, None, ), # 3
  )

  def __init__(self, userId=None, address=None, setDefault=None,):
    self.userId = userId
    self.address = address
    self.setDefault = setDefault

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.STRUCT:
          self.address = Address()
          self.address.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 3:
        if ftype == TType.BOOL:
          self.setDefault = iprot.readBool();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('addAddressForUser_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    if self.address is not None:
      oprot.writeFieldBegin('address', TType.STRUCT, 2)
      self.address.write(oprot)
      oprot.writeFieldEnd()
    if self.setDefault is not None:
      oprot.writeFieldBegin('setDefault', TType.BOOL, 3)
      oprot.writeBool(self.setDefault)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class addAddressForUser_result:
  """
  Attributes:
   - success
   - ucx
  """

  thrift_spec = (
    (0, TType.I64, 'success', None, None, ), # 0
    (1, TType.STRUCT, 'ucx', (UserContextException, UserContextException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucx=None,):
    self.success = success
    self.ucx = ucx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.I64:
          self.success = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucx = UserContextException()
          self.ucx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('addAddressForUser_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.I64, 0)
      oprot.writeI64(self.success)
      oprot.writeFieldEnd()
    if self.ucx is not None:
      oprot.writeFieldBegin('ucx', TType.STRUCT, 1)
      self.ucx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class removeAddressForUser_args:
  """
  Attributes:
   - userid
   - addressId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userid', None, None, ), # 1
    (2, TType.I64, 'addressId', None, None, ), # 2
  )

  def __init__(self, userid=None, addressId=None,):
    self.userid = userid
    self.addressId = addressId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userid = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.addressId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('removeAddressForUser_args')
    if self.userid is not None:
      oprot.writeFieldBegin('userid', TType.I64, 1)
      oprot.writeI64(self.userid)
      oprot.writeFieldEnd()
    if self.addressId is not None:
      oprot.writeFieldBegin('addressId', TType.I64, 2)
      oprot.writeI64(self.addressId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class removeAddressForUser_result:
  """
  Attributes:
   - success
   - ucx
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
    (1, TType.STRUCT, 'ucx', (UserContextException, UserContextException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucx=None,):
    self.success = success
    self.ucx = ucx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucx = UserContextException()
          self.ucx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('removeAddressForUser_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    if self.ucx is not None:
      oprot.writeFieldBegin('ucx', TType.STRUCT, 1)
      self.ucx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class updateAddress_args:
  """
  Attributes:
   - address
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRUCT, 'address', (Address, Address.thrift_spec), None, ), # 1
  )

  def __init__(self, address=None,):
    self.address = address

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRUCT:
          self.address = Address()
          self.address.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('updateAddress_args')
    if self.address is not None:
      oprot.writeFieldBegin('address', TType.STRUCT, 1)
      self.address.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class updateAddress_result:
  """
  Attributes:
   - success
   - ucx
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
    (1, TType.STRUCT, 'ucx', (UserContextException, UserContextException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucx=None,):
    self.success = success
    self.ucx = ucx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucx = UserContextException()
          self.ucx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('updateAddress_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    if self.ucx is not None:
      oprot.writeFieldBegin('ucx', TType.STRUCT, 1)
      self.ucx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class updateCounter_args:
  """
  Attributes:
   - counter
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRUCT, 'counter', (Counter, Counter.thrift_spec), None, ), # 1
  )

  def __init__(self, counter=None,):
    self.counter = counter

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRUCT:
          self.counter = Counter()
          self.counter.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('updateCounter_args')
    if self.counter is not None:
      oprot.writeFieldBegin('counter', TType.STRUCT, 1)
      self.counter.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class updateCounter_result:
  """
  Attributes:
   - success
   - ucx
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
    (1, TType.STRUCT, 'ucx', (UserContextException, UserContextException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucx=None,):
    self.success = success
    self.ucx = ucx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucx = UserContextException()
          self.ucx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('updateCounter_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    if self.ucx is not None:
      oprot.writeFieldBegin('ucx', TType.STRUCT, 1)
      self.ucx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class setUserAsLoggedIn_args:
  """
  Attributes:
   - userId
   - timestamp
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
    (2, TType.I64, 'timestamp', None, None, ), # 2
  )

  def __init__(self, userId=None, timestamp=None,):
    self.userId = userId
    self.timestamp = timestamp

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.timestamp = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('setUserAsLoggedIn_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    if self.timestamp is not None:
      oprot.writeFieldBegin('timestamp', TType.I64, 2)
      oprot.writeI64(self.timestamp)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class setUserAsLoggedIn_result:
  """
  Attributes:
   - success
   - ucx
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
    (1, TType.STRUCT, 'ucx', (UserContextException, UserContextException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucx=None,):
    self.success = success
    self.ucx = ucx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucx = UserContextException()
          self.ucx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('setUserAsLoggedIn_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    if self.ucx is not None:
      oprot.writeFieldBegin('ucx', TType.STRUCT, 1)
      self.ucx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class setUserAsLoggedOut_args:
  """
  Attributes:
   - userid
   - timestamp
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userid', None, None, ), # 1
    (2, TType.I64, 'timestamp', None, None, ), # 2
  )

  def __init__(self, userid=None, timestamp=None,):
    self.userid = userid
    self.timestamp = timestamp

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userid = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.timestamp = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('setUserAsLoggedOut_args')
    if self.userid is not None:
      oprot.writeFieldBegin('userid', TType.I64, 1)
      oprot.writeI64(self.userid)
      oprot.writeFieldEnd()
    if self.timestamp is not None:
      oprot.writeFieldBegin('timestamp', TType.I64, 2)
      oprot.writeI64(self.timestamp)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class setUserAsLoggedOut_result:
  """
  Attributes:
   - success
   - ucx
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
    (1, TType.STRUCT, 'ucx', (UserContextException, UserContextException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucx=None,):
    self.success = success
    self.ucx = ucx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucx = UserContextException()
          self.ucx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('setUserAsLoggedOut_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    if self.ucx is not None:
      oprot.writeFieldBegin('ucx', TType.STRUCT, 1)
      self.ucx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class setDefaultAddress_args:
  """
  Attributes:
   - userid
   - addressId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userid', None, None, ), # 1
    (2, TType.I64, 'addressId', None, None, ), # 2
  )

  def __init__(self, userid=None, addressId=None,):
    self.userid = userid
    self.addressId = addressId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userid = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.addressId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('setDefaultAddress_args')
    if self.userid is not None:
      oprot.writeFieldBegin('userid', TType.I64, 1)
      oprot.writeI64(self.userid)
      oprot.writeFieldEnd()
    if self.addressId is not None:
      oprot.writeFieldBegin('addressId', TType.I64, 2)
      oprot.writeI64(self.addressId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class setDefaultAddress_result:
  """
  Attributes:
   - success
   - ucx
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
    (1, TType.STRUCT, 'ucx', (UserContextException, UserContextException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucx=None,):
    self.success = success
    self.ucx = ucx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucx = UserContextException()
          self.ucx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('setDefaultAddress_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    if self.ucx is not None:
      oprot.writeFieldBegin('ucx', TType.STRUCT, 1)
      self.ucx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class updatePassword_args:
  """
  Attributes:
   - userid
   - oldPassword
   - newPassword
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userid', None, None, ), # 1
    (2, TType.STRING, 'oldPassword', None, None, ), # 2
    (3, TType.STRING, 'newPassword', None, None, ), # 3
  )

  def __init__(self, userid=None, oldPassword=None, newPassword=None,):
    self.userid = userid
    self.oldPassword = oldPassword
    self.newPassword = newPassword

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userid = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.STRING:
          self.oldPassword = iprot.readString();
        else:
          iprot.skip(ftype)
      elif fid == 3:
        if ftype == TType.STRING:
          self.newPassword = iprot.readString();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('updatePassword_args')
    if self.userid is not None:
      oprot.writeFieldBegin('userid', TType.I64, 1)
      oprot.writeI64(self.userid)
      oprot.writeFieldEnd()
    if self.oldPassword is not None:
      oprot.writeFieldBegin('oldPassword', TType.STRING, 2)
      oprot.writeString(self.oldPassword)
      oprot.writeFieldEnd()
    if self.newPassword is not None:
      oprot.writeFieldBegin('newPassword', TType.STRING, 3)
      oprot.writeString(self.newPassword)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class updatePassword_result:
  """
  Attributes:
   - success
   - ucx
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
    (1, TType.STRUCT, 'ucx', (UserContextException, UserContextException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucx=None,):
    self.success = success
    self.ucx = ucx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucx = UserContextException()
          self.ucx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('updatePassword_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    if self.ucx is not None:
      oprot.writeFieldBegin('ucx', TType.STRUCT, 1)
      self.ucx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class forgotPassword_args:
  """
  Attributes:
   - email
   - newPassword
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRING, 'email', None, None, ), # 1
    (2, TType.STRING, 'newPassword', None, None, ), # 2
  )

  def __init__(self, email=None, newPassword=None,):
    self.email = email
    self.newPassword = newPassword

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRING:
          self.email = iprot.readString();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.STRING:
          self.newPassword = iprot.readString();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('forgotPassword_args')
    if self.email is not None:
      oprot.writeFieldBegin('email', TType.STRING, 1)
      oprot.writeString(self.email)
      oprot.writeFieldEnd()
    if self.newPassword is not None:
      oprot.writeFieldBegin('newPassword', TType.STRING, 2)
      oprot.writeString(self.newPassword)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class forgotPassword_result:
  """
  Attributes:
   - success
   - ucx
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
    (1, TType.STRUCT, 'ucx', (UserContextException, UserContextException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucx=None,):
    self.success = success
    self.ucx = ucx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucx = UserContextException()
          self.ucx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('forgotPassword_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    if self.ucx is not None:
      oprot.writeFieldBegin('ucx', TType.STRUCT, 1)
      self.ucx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getAllAddressesForUser_args:
  """
  Attributes:
   - userId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
  )

  def __init__(self, userId=None,):
    self.userId = userId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getAllAddressesForUser_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getAllAddressesForUser_result:
  """
  Attributes:
   - success
   - ucx
  """

  thrift_spec = (
    (0, TType.LIST, 'success', (TType.STRUCT,(Address, Address.thrift_spec)), None, ), # 0
    (1, TType.STRUCT, 'ucx', (UserContextException, UserContextException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucx=None,):
    self.success = success
    self.ucx = ucx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.LIST:
          self.success = []
          (_etype100, _size97) = iprot.readListBegin()
          for _i101 in xrange(_size97):
            _elem102 = Address()
            _elem102.read(iprot)
            self.success.append(_elem102)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucx = UserContextException()
          self.ucx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getAllAddressesForUser_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.LIST, 0)
      oprot.writeListBegin(TType.STRUCT, len(self.success))
      for iter103 in self.success:
        iter103.write(oprot)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    if self.ucx is not None:
      oprot.writeFieldBegin('ucx', TType.STRUCT, 1)
      self.ucx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getAddressById_args:
  """
  Attributes:
   - addressId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'addressId', None, None, ), # 1
  )

  def __init__(self, addressId=None,):
    self.addressId = addressId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.addressId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getAddressById_args')
    if self.addressId is not None:
      oprot.writeFieldBegin('addressId', TType.I64, 1)
      oprot.writeI64(self.addressId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getAddressById_result:
  """
  Attributes:
   - success
   - ucx
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (Address, Address.thrift_spec), None, ), # 0
    (1, TType.STRUCT, 'ucx', (UserContextException, UserContextException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucx=None,):
    self.success = success
    self.ucx = ucx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = Address()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucx = UserContextException()
          self.ucx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getAddressById_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    if self.ucx is not None:
      oprot.writeFieldBegin('ucx', TType.STRUCT, 1)
      self.ucx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getDefaultAddressId_args:
  """
  Attributes:
   - userId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
  )

  def __init__(self, userId=None,):
    self.userId = userId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getDefaultAddressId_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getDefaultAddressId_result:
  """
  Attributes:
   - success
   - ucx
  """

  thrift_spec = (
    (0, TType.I64, 'success', None, None, ), # 0
    (1, TType.STRUCT, 'ucx', (UserContextException, UserContextException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucx=None,):
    self.success = success
    self.ucx = ucx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.I64:
          self.success = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucx = UserContextException()
          self.ucx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getDefaultAddressId_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.I64, 0)
      oprot.writeI64(self.success)
      oprot.writeFieldEnd()
    if self.ucx is not None:
      oprot.writeFieldBegin('ucx', TType.STRUCT, 1)
      self.ucx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getDefaultPincode_args:
  """
  Attributes:
   - userId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
  )

  def __init__(self, userId=None,):
    self.userId = userId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getDefaultPincode_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getDefaultPincode_result:
  """
  Attributes:
   - success
   - ucx
  """

  thrift_spec = (
    (0, TType.STRING, 'success', None, None, ), # 0
    (1, TType.STRUCT, 'ucx', (UserContextException, UserContextException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucx=None,):
    self.success = success
    self.ucx = ucx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRING:
          self.success = iprot.readString();
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucx = UserContextException()
          self.ucx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getDefaultPincode_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRING, 0)
      oprot.writeString(self.success)
      oprot.writeFieldEnd()
    if self.ucx is not None:
      oprot.writeFieldBegin('ucx', TType.STRUCT, 1)
      self.ucx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class saveUserCommunication_args:
  """
  Attributes:
   - userId
   - replyTo
   - communicationType
   - orderId
   - airwaybillNo
   - productName
   - subject
   - message
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
    (2, TType.STRING, 'replyTo', None, None, ), # 2
    (3, TType.I64, 'communicationType', None, None, ), # 3
    (4, TType.I64, 'orderId', None, None, ), # 4
    (5, TType.STRING, 'airwaybillNo', None, None, ), # 5
    (6, TType.STRING, 'productName', None, None, ), # 6
    (7, TType.STRING, 'subject', None, None, ), # 7
    (8, TType.STRING, 'message', None, None, ), # 8
  )

  def __init__(self, userId=None, replyTo=None, communicationType=None, orderId=None, airwaybillNo=None, productName=None, subject=None, message=None,):
    self.userId = userId
    self.replyTo = replyTo
    self.communicationType = communicationType
    self.orderId = orderId
    self.airwaybillNo = airwaybillNo
    self.productName = productName
    self.subject = subject
    self.message = message

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.STRING:
          self.replyTo = iprot.readString();
        else:
          iprot.skip(ftype)
      elif fid == 3:
        if ftype == TType.I64:
          self.communicationType = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 4:
        if ftype == TType.I64:
          self.orderId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 5:
        if ftype == TType.STRING:
          self.airwaybillNo = iprot.readString();
        else:
          iprot.skip(ftype)
      elif fid == 6:
        if ftype == TType.STRING:
          self.productName = iprot.readString();
        else:
          iprot.skip(ftype)
      elif fid == 7:
        if ftype == TType.STRING:
          self.subject = iprot.readString();
        else:
          iprot.skip(ftype)
      elif fid == 8:
        if ftype == TType.STRING:
          self.message = iprot.readString();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('saveUserCommunication_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    if self.replyTo is not None:
      oprot.writeFieldBegin('replyTo', TType.STRING, 2)
      oprot.writeString(self.replyTo)
      oprot.writeFieldEnd()
    if self.communicationType is not None:
      oprot.writeFieldBegin('communicationType', TType.I64, 3)
      oprot.writeI64(self.communicationType)
      oprot.writeFieldEnd()
    if self.orderId is not None:
      oprot.writeFieldBegin('orderId', TType.I64, 4)
      oprot.writeI64(self.orderId)
      oprot.writeFieldEnd()
    if self.airwaybillNo is not None:
      oprot.writeFieldBegin('airwaybillNo', TType.STRING, 5)
      oprot.writeString(self.airwaybillNo)
      oprot.writeFieldEnd()
    if self.productName is not None:
      oprot.writeFieldBegin('productName', TType.STRING, 6)
      oprot.writeString(self.productName)
      oprot.writeFieldEnd()
    if self.subject is not None:
      oprot.writeFieldBegin('subject', TType.STRING, 7)
      oprot.writeString(self.subject)
      oprot.writeFieldEnd()
    if self.message is not None:
      oprot.writeFieldBegin('message', TType.STRING, 8)
      oprot.writeString(self.message)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class saveUserCommunication_result:
  """
  Attributes:
   - success
   - ucx
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
    (1, TType.STRUCT, 'ucx', (UserCommunicationException, UserCommunicationException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucx=None,):
    self.success = success
    self.ucx = ucx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucx = UserCommunicationException()
          self.ucx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('saveUserCommunication_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    if self.ucx is not None:
      oprot.writeFieldBegin('ucx', TType.STRUCT, 1)
      self.ucx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getUserCommunicationById_args:
  """
  Attributes:
   - id
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'id', None, None, ), # 1
  )

  def __init__(self, id=None,):
    self.id = id

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.id = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getUserCommunicationById_args')
    if self.id is not None:
      oprot.writeFieldBegin('id', TType.I64, 1)
      oprot.writeI64(self.id)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getUserCommunicationById_result:
  """
  Attributes:
   - success
   - ucx
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (UserCommunication, UserCommunication.thrift_spec), None, ), # 0
    (1, TType.STRUCT, 'ucx', (UserCommunicationException, UserCommunicationException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucx=None,):
    self.success = success
    self.ucx = ucx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = UserCommunication()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucx = UserCommunicationException()
          self.ucx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getUserCommunicationById_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    if self.ucx is not None:
      oprot.writeFieldBegin('ucx', TType.STRUCT, 1)
      self.ucx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getUserCommunicationByUser_args:
  """
  Attributes:
   - userId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
  )

  def __init__(self, userId=None,):
    self.userId = userId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getUserCommunicationByUser_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getUserCommunicationByUser_result:
  """
  Attributes:
   - success
   - ucx
  """

  thrift_spec = (
    (0, TType.LIST, 'success', (TType.STRUCT,(UserCommunication, UserCommunication.thrift_spec)), None, ), # 0
    (1, TType.STRUCT, 'ucx', (UserCommunicationException, UserCommunicationException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucx=None,):
    self.success = success
    self.ucx = ucx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.LIST:
          self.success = []
          (_etype107, _size104) = iprot.readListBegin()
          for _i108 in xrange(_size104):
            _elem109 = UserCommunication()
            _elem109.read(iprot)
            self.success.append(_elem109)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucx = UserCommunicationException()
          self.ucx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getUserCommunicationByUser_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.LIST, 0)
      oprot.writeListBegin(TType.STRUCT, len(self.success))
      for iter110 in self.success:
        iter110.write(oprot)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    if self.ucx is not None:
      oprot.writeFieldBegin('ucx', TType.STRUCT, 1)
      self.ucx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getAllUserCommunications_args:

  thrift_spec = (
  )

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getAllUserCommunications_args')
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getAllUserCommunications_result:
  """
  Attributes:
   - success
   - ucx
  """

  thrift_spec = (
    (0, TType.LIST, 'success', (TType.STRUCT,(UserCommunication, UserCommunication.thrift_spec)), None, ), # 0
    (1, TType.STRUCT, 'ucx', (UserCommunicationException, UserCommunicationException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, ucx=None,):
    self.success = success
    self.ucx = ucx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.LIST:
          self.success = []
          (_etype114, _size111) = iprot.readListBegin()
          for _i115 in xrange(_size111):
            _elem116 = UserCommunication()
            _elem116.read(iprot)
            self.success.append(_elem116)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.ucx = UserCommunicationException()
          self.ucx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getAllUserCommunications_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.LIST, 0)
      oprot.writeListBegin(TType.STRUCT, len(self.success))
      for iter117 in self.success:
        iter117.write(oprot)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    if self.ucx is not None:
      oprot.writeFieldBegin('ucx', TType.STRUCT, 1)
      self.ucx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class removeUserCommunication_args:
  """
  Attributes:
   - id
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'id', None, None, ), # 1
  )

  def __init__(self, id=None,):
    self.id = id

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.id = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('removeUserCommunication_args')
    if self.id is not None:
      oprot.writeFieldBegin('id', TType.I64, 1)
      oprot.writeI64(self.id)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class removeUserCommunication_result:
  """
  Attributes:
   - ucx
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRUCT, 'ucx', (UserCommunicationException, UserCommunicationException.thrift_spec), None, ), # 1
  )

  def __init__(self, ucx=None,):
    self.ucx = ucx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRUCT:
          self.ucx = UserCommunicationException()
          self.ucx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('removeUserCommunication_result')
    if self.ucx is not None:
      oprot.writeFieldBegin('ucx', TType.STRUCT, 1)
      self.ucx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class createMasterAffiliate_args:
  """
  Attributes:
   - name
   - addedOn
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRING, 'name', None, None, ), # 1
    (2, TType.I64, 'addedOn', None, None, ), # 2
  )

  def __init__(self, name=None, addedOn=None,):
    self.name = name
    self.addedOn = addedOn

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRING:
          self.name = iprot.readString();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.addedOn = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('createMasterAffiliate_args')
    if self.name is not None:
      oprot.writeFieldBegin('name', TType.STRING, 1)
      oprot.writeString(self.name)
      oprot.writeFieldEnd()
    if self.addedOn is not None:
      oprot.writeFieldBegin('addedOn', TType.I64, 2)
      oprot.writeI64(self.addedOn)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class createMasterAffiliate_result:
  """
  Attributes:
   - success
   - utx
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (MasterAffiliate, MasterAffiliate.thrift_spec), None, ), # 0
    (1, TType.STRUCT, 'utx', (UserAffiliateException, UserAffiliateException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, utx=None,):
    self.success = success
    self.utx = utx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = MasterAffiliate()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.utx = UserAffiliateException()
          self.utx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('createMasterAffiliate_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    if self.utx is not None:
      oprot.writeFieldBegin('utx', TType.STRUCT, 1)
      self.utx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getAllMasterAffiliates_args:

  thrift_spec = (
  )

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getAllMasterAffiliates_args')
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getAllMasterAffiliates_result:
  """
  Attributes:
   - success
   - utx
  """

  thrift_spec = (
    (0, TType.LIST, 'success', (TType.STRUCT,(MasterAffiliate, MasterAffiliate.thrift_spec)), None, ), # 0
    (1, TType.STRUCT, 'utx', (UserAffiliateException, UserAffiliateException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, utx=None,):
    self.success = success
    self.utx = utx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.LIST:
          self.success = []
          (_etype121, _size118) = iprot.readListBegin()
          for _i122 in xrange(_size118):
            _elem123 = MasterAffiliate()
            _elem123.read(iprot)
            self.success.append(_elem123)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.utx = UserAffiliateException()
          self.utx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getAllMasterAffiliates_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.LIST, 0)
      oprot.writeListBegin(TType.STRUCT, len(self.success))
      for iter124 in self.success:
        iter124.write(oprot)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    if self.utx is not None:
      oprot.writeFieldBegin('utx', TType.STRUCT, 1)
      self.utx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getMasterAffiliateById_args:
  """
  Attributes:
   - id
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'id', None, None, ), # 1
  )

  def __init__(self, id=None,):
    self.id = id

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.id = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getMasterAffiliateById_args')
    if self.id is not None:
      oprot.writeFieldBegin('id', TType.I64, 1)
      oprot.writeI64(self.id)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getMasterAffiliateById_result:
  """
  Attributes:
   - success
   - utx
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (MasterAffiliate, MasterAffiliate.thrift_spec), None, ), # 0
    (1, TType.STRUCT, 'utx', (UserAffiliateException, UserAffiliateException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, utx=None,):
    self.success = success
    self.utx = utx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = MasterAffiliate()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.utx = UserAffiliateException()
          self.utx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getMasterAffiliateById_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    if self.utx is not None:
      oprot.writeFieldBegin('utx', TType.STRUCT, 1)
      self.utx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getMasterAffiliateByName_args:
  """
  Attributes:
   - name
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRING, 'name', None, None, ), # 1
  )

  def __init__(self, name=None,):
    self.name = name

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRING:
          self.name = iprot.readString();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getMasterAffiliateByName_args')
    if self.name is not None:
      oprot.writeFieldBegin('name', TType.STRING, 1)
      oprot.writeString(self.name)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getMasterAffiliateByName_result:
  """
  Attributes:
   - success
   - utx
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (MasterAffiliate, MasterAffiliate.thrift_spec), None, ), # 0
    (1, TType.STRUCT, 'utx', (UserAffiliateException, UserAffiliateException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, utx=None,):
    self.success = success
    self.utx = utx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = MasterAffiliate()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.utx = UserAffiliateException()
          self.utx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getMasterAffiliateByName_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    if self.utx is not None:
      oprot.writeFieldBegin('utx', TType.STRUCT, 1)
      self.utx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class createAffiliate_args:
  """
  Attributes:
   - name
   - url
   - masterAffiliateId
   - addedOn
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRING, 'name', None, None, ), # 1
    (2, TType.STRING, 'url', None, None, ), # 2
    (3, TType.I64, 'masterAffiliateId', None, None, ), # 3
    (4, TType.I64, 'addedOn', None, None, ), # 4
  )

  def __init__(self, name=None, url=None, masterAffiliateId=None, addedOn=None,):
    self.name = name
    self.url = url
    self.masterAffiliateId = masterAffiliateId
    self.addedOn = addedOn

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRING:
          self.name = iprot.readString();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.STRING:
          self.url = iprot.readString();
        else:
          iprot.skip(ftype)
      elif fid == 3:
        if ftype == TType.I64:
          self.masterAffiliateId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 4:
        if ftype == TType.I64:
          self.addedOn = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('createAffiliate_args')
    if self.name is not None:
      oprot.writeFieldBegin('name', TType.STRING, 1)
      oprot.writeString(self.name)
      oprot.writeFieldEnd()
    if self.url is not None:
      oprot.writeFieldBegin('url', TType.STRING, 2)
      oprot.writeString(self.url)
      oprot.writeFieldEnd()
    if self.masterAffiliateId is not None:
      oprot.writeFieldBegin('masterAffiliateId', TType.I64, 3)
      oprot.writeI64(self.masterAffiliateId)
      oprot.writeFieldEnd()
    if self.addedOn is not None:
      oprot.writeFieldBegin('addedOn', TType.I64, 4)
      oprot.writeI64(self.addedOn)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class createAffiliate_result:
  """
  Attributes:
   - success
   - utx
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (Affiliate, Affiliate.thrift_spec), None, ), # 0
    (1, TType.STRUCT, 'utx', (UserAffiliateException, UserAffiliateException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, utx=None,):
    self.success = success
    self.utx = utx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = Affiliate()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.utx = UserAffiliateException()
          self.utx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('createAffiliate_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    if self.utx is not None:
      oprot.writeFieldBegin('utx', TType.STRUCT, 1)
      self.utx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getAffiliateById_args:
  """
  Attributes:
   - id
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'id', None, None, ), # 1
  )

  def __init__(self, id=None,):
    self.id = id

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.id = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getAffiliateById_args')
    if self.id is not None:
      oprot.writeFieldBegin('id', TType.I64, 1)
      oprot.writeI64(self.id)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getAffiliateById_result:
  """
  Attributes:
   - success
   - utx
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (Affiliate, Affiliate.thrift_spec), None, ), # 0
    (1, TType.STRUCT, 'utx', (UserAffiliateException, UserAffiliateException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, utx=None,):
    self.success = success
    self.utx = utx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = Affiliate()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.utx = UserAffiliateException()
          self.utx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getAffiliateById_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    if self.utx is not None:
      oprot.writeFieldBegin('utx', TType.STRUCT, 1)
      self.utx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getAffiliateByName_args:
  """
  Attributes:
   - name
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRING, 'name', None, None, ), # 1
  )

  def __init__(self, name=None,):
    self.name = name

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRING:
          self.name = iprot.readString();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getAffiliateByName_args')
    if self.name is not None:
      oprot.writeFieldBegin('name', TType.STRING, 1)
      oprot.writeString(self.name)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getAffiliateByName_result:
  """
  Attributes:
   - success
   - utx
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (Affiliate, Affiliate.thrift_spec), None, ), # 0
    (1, TType.STRUCT, 'utx', (UserAffiliateException, UserAffiliateException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, utx=None,):
    self.success = success
    self.utx = utx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = Affiliate()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.utx = UserAffiliateException()
          self.utx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getAffiliateByName_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    if self.utx is not None:
      oprot.writeFieldBegin('utx', TType.STRUCT, 1)
      self.utx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getTrackerById_args:
  """
  Attributes:
   - id
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'id', None, None, ), # 1
  )

  def __init__(self, id=None,):
    self.id = id

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.id = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getTrackerById_args')
    if self.id is not None:
      oprot.writeFieldBegin('id', TType.I64, 1)
      oprot.writeI64(self.id)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getTrackerById_result:
  """
  Attributes:
   - success
   - utx
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (Tracker, Tracker.thrift_spec), None, ), # 0
    (1, TType.STRUCT, 'utx', (UserAffiliateException, UserAffiliateException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, utx=None,):
    self.success = success
    self.utx = utx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = Tracker()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.utx = UserAffiliateException()
          self.utx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getTrackerById_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    if self.utx is not None:
      oprot.writeFieldBegin('utx', TType.STRUCT, 1)
      self.utx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getAffiliatesByMasterAffiliate_args:
  """
  Attributes:
   - id
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'id', None, None, ), # 1
  )

  def __init__(self, id=None,):
    self.id = id

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.id = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getAffiliatesByMasterAffiliate_args')
    if self.id is not None:
      oprot.writeFieldBegin('id', TType.I64, 1)
      oprot.writeI64(self.id)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getAffiliatesByMasterAffiliate_result:
  """
  Attributes:
   - success
   - utx
  """

  thrift_spec = (
    (0, TType.LIST, 'success', (TType.STRUCT,(Affiliate, Affiliate.thrift_spec)), None, ), # 0
    (1, TType.STRUCT, 'utx', (UserAffiliateException, UserAffiliateException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, utx=None,):
    self.success = success
    self.utx = utx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.LIST:
          self.success = []
          (_etype128, _size125) = iprot.readListBegin()
          for _i129 in xrange(_size125):
            _elem130 = Affiliate()
            _elem130.read(iprot)
            self.success.append(_elem130)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.utx = UserAffiliateException()
          self.utx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getAffiliatesByMasterAffiliate_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.LIST, 0)
      oprot.writeListBegin(TType.STRUCT, len(self.success))
      for iter131 in self.success:
        iter131.write(oprot)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    if self.utx is not None:
      oprot.writeFieldBegin('utx', TType.STRUCT, 1)
      self.utx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class addTrackLog_args:
  """
  Attributes:
   - affiliateId
   - userId
   - event
   - url
   - data
   - addedOn
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'affiliateId', None, None, ), # 1
    (2, TType.I64, 'userId', None, None, ), # 2
    (3, TType.I32, 'event', None, None, ), # 3
    (4, TType.STRING, 'url', None, None, ), # 4
    (5, TType.STRING, 'data', None, None, ), # 5
    (6, TType.I64, 'addedOn', None, None, ), # 6
  )

  def __init__(self, affiliateId=None, userId=None, event=None, url=None, data=None, addedOn=None,):
    self.affiliateId = affiliateId
    self.userId = userId
    self.event = event
    self.url = url
    self.data = data
    self.addedOn = addedOn

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.affiliateId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 3:
        if ftype == TType.I32:
          self.event = iprot.readI32();
        else:
          iprot.skip(ftype)
      elif fid == 4:
        if ftype == TType.STRING:
          self.url = iprot.readString();
        else:
          iprot.skip(ftype)
      elif fid == 5:
        if ftype == TType.STRING:
          self.data = iprot.readString();
        else:
          iprot.skip(ftype)
      elif fid == 6:
        if ftype == TType.I64:
          self.addedOn = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('addTrackLog_args')
    if self.affiliateId is not None:
      oprot.writeFieldBegin('affiliateId', TType.I64, 1)
      oprot.writeI64(self.affiliateId)
      oprot.writeFieldEnd()
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 2)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    if self.event is not None:
      oprot.writeFieldBegin('event', TType.I32, 3)
      oprot.writeI32(self.event)
      oprot.writeFieldEnd()
    if self.url is not None:
      oprot.writeFieldBegin('url', TType.STRING, 4)
      oprot.writeString(self.url)
      oprot.writeFieldEnd()
    if self.data is not None:
      oprot.writeFieldBegin('data', TType.STRING, 5)
      oprot.writeString(self.data)
      oprot.writeFieldEnd()
    if self.addedOn is not None:
      oprot.writeFieldBegin('addedOn', TType.I64, 6)
      oprot.writeI64(self.addedOn)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class addTrackLog_result:
  """
  Attributes:
   - success
   - utx
  """

  thrift_spec = (
    (0, TType.I64, 'success', None, None, ), # 0
    (1, TType.STRUCT, 'utx', (UserAffiliateException, UserAffiliateException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, utx=None,):
    self.success = success
    self.utx = utx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.I64:
          self.success = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.utx = UserAffiliateException()
          self.utx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('addTrackLog_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.I64, 0)
      oprot.writeI64(self.success)
      oprot.writeFieldEnd()
    if self.utx is not None:
      oprot.writeFieldBegin('utx', TType.STRUCT, 1)
      self.utx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getTrackLogById_args:
  """
  Attributes:
   - id
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'id', None, None, ), # 1
  )

  def __init__(self, id=None,):
    self.id = id

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.id = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getTrackLogById_args')
    if self.id is not None:
      oprot.writeFieldBegin('id', TType.I64, 1)
      oprot.writeI64(self.id)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getTrackLogById_result:
  """
  Attributes:
   - success
   - utx
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (TrackLog, TrackLog.thrift_spec), None, ), # 0
    (1, TType.STRUCT, 'utx', (UserAffiliateException, UserAffiliateException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, utx=None,):
    self.success = success
    self.utx = utx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = TrackLog()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.utx = UserAffiliateException()
          self.utx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getTrackLogById_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    if self.utx is not None:
      oprot.writeFieldBegin('utx', TType.STRUCT, 1)
      self.utx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getTrackLogsByAffiliate_args:
  """
  Attributes:
   - affiliateId
   - startDate
   - endDate
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'affiliateId', None, None, ), # 1
    (2, TType.I64, 'startDate', None, None, ), # 2
    (3, TType.I64, 'endDate', None, None, ), # 3
  )

  def __init__(self, affiliateId=None, startDate=None, endDate=None,):
    self.affiliateId = affiliateId
    self.startDate = startDate
    self.endDate = endDate

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.affiliateId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.startDate = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 3:
        if ftype == TType.I64:
          self.endDate = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getTrackLogsByAffiliate_args')
    if self.affiliateId is not None:
      oprot.writeFieldBegin('affiliateId', TType.I64, 1)
      oprot.writeI64(self.affiliateId)
      oprot.writeFieldEnd()
    if self.startDate is not None:
      oprot.writeFieldBegin('startDate', TType.I64, 2)
      oprot.writeI64(self.startDate)
      oprot.writeFieldEnd()
    if self.endDate is not None:
      oprot.writeFieldBegin('endDate', TType.I64, 3)
      oprot.writeI64(self.endDate)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getTrackLogsByAffiliate_result:
  """
  Attributes:
   - success
   - utx
  """

  thrift_spec = (
    (0, TType.LIST, 'success', (TType.STRUCT,(TrackLog, TrackLog.thrift_spec)), None, ), # 0
    (1, TType.STRUCT, 'utx', (UserAffiliateException, UserAffiliateException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, utx=None,):
    self.success = success
    self.utx = utx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.LIST:
          self.success = []
          (_etype135, _size132) = iprot.readListBegin()
          for _i136 in xrange(_size132):
            _elem137 = TrackLog()
            _elem137.read(iprot)
            self.success.append(_elem137)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.utx = UserAffiliateException()
          self.utx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getTrackLogsByAffiliate_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.LIST, 0)
      oprot.writeListBegin(TType.STRUCT, len(self.success))
      for iter138 in self.success:
        iter138.write(oprot)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    if self.utx is not None:
      oprot.writeFieldBegin('utx', TType.STRUCT, 1)
      self.utx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getTrackLogsByUser_args:
  """
  Attributes:
   - userId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
  )

  def __init__(self, userId=None,):
    self.userId = userId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getTrackLogsByUser_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getTrackLogsByUser_result:
  """
  Attributes:
   - success
   - utx
  """

  thrift_spec = (
    (0, TType.LIST, 'success', (TType.STRUCT,(TrackLog, TrackLog.thrift_spec)), None, ), # 0
    (1, TType.STRUCT, 'utx', (UserAffiliateException, UserAffiliateException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, utx=None,):
    self.success = success
    self.utx = utx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.LIST:
          self.success = []
          (_etype142, _size139) = iprot.readListBegin()
          for _i143 in xrange(_size139):
            _elem144 = TrackLog()
            _elem144.read(iprot)
            self.success.append(_elem144)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.utx = UserAffiliateException()
          self.utx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getTrackLogsByUser_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.LIST, 0)
      oprot.writeListBegin(TType.STRUCT, len(self.success))
      for iter145 in self.success:
        iter145.write(oprot)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    if self.utx is not None:
      oprot.writeFieldBegin('utx', TType.STRUCT, 1)
      self.utx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getTrackLogs_args:
  """
  Attributes:
   - userId
   - event
   - url
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
    (2, TType.STRING, 'event', None, None, ), # 2
    (3, TType.STRING, 'url', None, None, ), # 3
  )

  def __init__(self, userId=None, event=None, url=None,):
    self.userId = userId
    self.event = event
    self.url = url

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.STRING:
          self.event = iprot.readString();
        else:
          iprot.skip(ftype)
      elif fid == 3:
        if ftype == TType.STRING:
          self.url = iprot.readString();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getTrackLogs_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    if self.event is not None:
      oprot.writeFieldBegin('event', TType.STRING, 2)
      oprot.writeString(self.event)
      oprot.writeFieldEnd()
    if self.url is not None:
      oprot.writeFieldBegin('url', TType.STRING, 3)
      oprot.writeString(self.url)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getTrackLogs_result:
  """
  Attributes:
   - success
   - utx
  """

  thrift_spec = (
    (0, TType.LIST, 'success', (TType.STRUCT,(TrackLog, TrackLog.thrift_spec)), None, ), # 0
    (1, TType.STRUCT, 'utx', (UserAffiliateException, UserAffiliateException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, utx=None,):
    self.success = success
    self.utx = utx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.LIST:
          self.success = []
          (_etype149, _size146) = iprot.readListBegin()
          for _i150 in xrange(_size146):
            _elem151 = TrackLog()
            _elem151.read(iprot)
            self.success.append(_elem151)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.utx = UserAffiliateException()
          self.utx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getTrackLogs_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.LIST, 0)
      oprot.writeListBegin(TType.STRUCT, len(self.success))
      for iter152 in self.success:
        iter152.write(oprot)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    if self.utx is not None:
      oprot.writeFieldBegin('utx', TType.STRUCT, 1)
      self.utx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getCurrentCart_args:
  """
  Attributes:
   - userId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
  )

  def __init__(self, userId=None,):
    self.userId = userId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getCurrentCart_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getCurrentCart_result:
  """
  Attributes:
   - success
   - scx
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (Cart, Cart.thrift_spec), None, ), # 0
    (1, TType.STRUCT, 'scx', (ShoppingCartException, ShoppingCartException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, scx=None,):
    self.success = success
    self.scx = scx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = Cart()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.scx = ShoppingCartException()
          self.scx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getCurrentCart_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    if self.scx is not None:
      oprot.writeFieldBegin('scx', TType.STRUCT, 1)
      self.scx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getCart_args:
  """
  Attributes:
   - cartId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'cartId', None, None, ), # 1
  )

  def __init__(self, cartId=None,):
    self.cartId = cartId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.cartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getCart_args')
    if self.cartId is not None:
      oprot.writeFieldBegin('cartId', TType.I64, 1)
      oprot.writeI64(self.cartId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getCart_result:
  """
  Attributes:
   - success
   - scx
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (Cart, Cart.thrift_spec), None, ), # 0
    (1, TType.STRUCT, 'scx', (ShoppingCartException, ShoppingCartException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, scx=None,):
    self.success = success
    self.scx = scx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = Cart()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.scx = ShoppingCartException()
          self.scx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getCart_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    if self.scx is not None:
      oprot.writeFieldBegin('scx', TType.STRUCT, 1)
      self.scx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getCartsByTime_args:
  """
  Attributes:
   - from_time
   - to_time
   - status
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'from_time', None, None, ), # 1
    (2, TType.I64, 'to_time', None, None, ), # 2
    (3, TType.I32, 'status', None, None, ), # 3
  )

  def __init__(self, from_time=None, to_time=None, status=None,):
    self.from_time = from_time
    self.to_time = to_time
    self.status = status

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.from_time = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.to_time = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 3:
        if ftype == TType.I32:
          self.status = iprot.readI32();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getCartsByTime_args')
    if self.from_time is not None:
      oprot.writeFieldBegin('from_time', TType.I64, 1)
      oprot.writeI64(self.from_time)
      oprot.writeFieldEnd()
    if self.to_time is not None:
      oprot.writeFieldBegin('to_time', TType.I64, 2)
      oprot.writeI64(self.to_time)
      oprot.writeFieldEnd()
    if self.status is not None:
      oprot.writeFieldBegin('status', TType.I32, 3)
      oprot.writeI32(self.status)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getCartsByTime_result:
  """
  Attributes:
   - success
   - scx
  """

  thrift_spec = (
    (0, TType.LIST, 'success', (TType.STRUCT,(Cart, Cart.thrift_spec)), None, ), # 0
    (1, TType.STRUCT, 'scx', (ShoppingCartException, ShoppingCartException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, scx=None,):
    self.success = success
    self.scx = scx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.LIST:
          self.success = []
          (_etype156, _size153) = iprot.readListBegin()
          for _i157 in xrange(_size153):
            _elem158 = Cart()
            _elem158.read(iprot)
            self.success.append(_elem158)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.scx = ShoppingCartException()
          self.scx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getCartsByTime_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.LIST, 0)
      oprot.writeListBegin(TType.STRUCT, len(self.success))
      for iter159 in self.success:
        iter159.write(oprot)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    if self.scx is not None:
      oprot.writeFieldBegin('scx', TType.STRUCT, 1)
      self.scx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class addItemToCart_args:
  """
  Attributes:
   - cartId
   - itemId
   - quantity
   - sourceId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'cartId', None, None, ), # 1
    (2, TType.I64, 'itemId', None, None, ), # 2
    (3, TType.I64, 'quantity', None, None, ), # 3
    (4, TType.I64, 'sourceId', None, None, ), # 4
  )

  def __init__(self, cartId=None, itemId=None, quantity=None, sourceId=None,):
    self.cartId = cartId
    self.itemId = itemId
    self.quantity = quantity
    self.sourceId = sourceId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.cartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.itemId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 3:
        if ftype == TType.I64:
          self.quantity = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 4:
        if ftype == TType.I64:
          self.sourceId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('addItemToCart_args')
    if self.cartId is not None:
      oprot.writeFieldBegin('cartId', TType.I64, 1)
      oprot.writeI64(self.cartId)
      oprot.writeFieldEnd()
    if self.itemId is not None:
      oprot.writeFieldBegin('itemId', TType.I64, 2)
      oprot.writeI64(self.itemId)
      oprot.writeFieldEnd()
    if self.quantity is not None:
      oprot.writeFieldBegin('quantity', TType.I64, 3)
      oprot.writeI64(self.quantity)
      oprot.writeFieldEnd()
    if self.sourceId is not None:
      oprot.writeFieldBegin('sourceId', TType.I64, 4)
      oprot.writeI64(self.sourceId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class addItemToCart_result:
  """
  Attributes:
   - success
   - scx
  """

  thrift_spec = (
    (0, TType.STRING, 'success', None, None, ), # 0
    (1, TType.STRUCT, 'scx', (ShoppingCartException, ShoppingCartException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, scx=None,):
    self.success = success
    self.scx = scx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRING:
          self.success = iprot.readString();
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.scx = ShoppingCartException()
          self.scx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('addItemToCart_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRING, 0)
      oprot.writeString(self.success)
      oprot.writeFieldEnd()
    if self.scx is not None:
      oprot.writeFieldBegin('scx', TType.STRUCT, 1)
      self.scx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class deleteItemFromCart_args:
  """
  Attributes:
   - cartId
   - itemId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'cartId', None, None, ), # 1
    (2, TType.I64, 'itemId', None, None, ), # 2
  )

  def __init__(self, cartId=None, itemId=None,):
    self.cartId = cartId
    self.itemId = itemId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.cartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.itemId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('deleteItemFromCart_args')
    if self.cartId is not None:
      oprot.writeFieldBegin('cartId', TType.I64, 1)
      oprot.writeI64(self.cartId)
      oprot.writeFieldEnd()
    if self.itemId is not None:
      oprot.writeFieldBegin('itemId', TType.I64, 2)
      oprot.writeI64(self.itemId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class deleteItemFromCart_result:
  """
  Attributes:
   - scx
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRUCT, 'scx', (ShoppingCartException, ShoppingCartException.thrift_spec), None, ), # 1
  )

  def __init__(self, scx=None,):
    self.scx = scx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRUCT:
          self.scx = ShoppingCartException()
          self.scx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('deleteItemFromCart_result')
    if self.scx is not None:
      oprot.writeFieldBegin('scx', TType.STRUCT, 1)
      self.scx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class addAddressToCart_args:
  """
  Attributes:
   - cartId
   - addressId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'cartId', None, None, ), # 1
    (2, TType.I64, 'addressId', None, None, ), # 2
  )

  def __init__(self, cartId=None, addressId=None,):
    self.cartId = cartId
    self.addressId = addressId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.cartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.addressId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('addAddressToCart_args')
    if self.cartId is not None:
      oprot.writeFieldBegin('cartId', TType.I64, 1)
      oprot.writeI64(self.cartId)
      oprot.writeFieldEnd()
    if self.addressId is not None:
      oprot.writeFieldBegin('addressId', TType.I64, 2)
      oprot.writeI64(self.addressId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class addAddressToCart_result:
  """
  Attributes:
   - scx
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRUCT, 'scx', (ShoppingCartException, ShoppingCartException.thrift_spec), None, ), # 1
  )

  def __init__(self, scx=None,):
    self.scx = scx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRUCT:
          self.scx = ShoppingCartException()
          self.scx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('addAddressToCart_result')
    if self.scx is not None:
      oprot.writeFieldBegin('scx', TType.STRUCT, 1)
      self.scx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class addStoreToCart_args:
  """
  Attributes:
   - cartId
   - storeId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'cartId', None, None, ), # 1
    (2, TType.I64, 'storeId', None, None, ), # 2
  )

  def __init__(self, cartId=None, storeId=None,):
    self.cartId = cartId
    self.storeId = storeId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.cartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.storeId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('addStoreToCart_args')
    if self.cartId is not None:
      oprot.writeFieldBegin('cartId', TType.I64, 1)
      oprot.writeI64(self.cartId)
      oprot.writeFieldEnd()
    if self.storeId is not None:
      oprot.writeFieldBegin('storeId', TType.I64, 2)
      oprot.writeI64(self.storeId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class addStoreToCart_result:
  """
  Attributes:
   - scx
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRUCT, 'scx', (ShoppingCartException, ShoppingCartException.thrift_spec), None, ), # 1
  )

  def __init__(self, scx=None,):
    self.scx = scx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRUCT:
          self.scx = ShoppingCartException()
          self.scx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('addStoreToCart_result')
    if self.scx is not None:
      oprot.writeFieldBegin('scx', TType.STRUCT, 1)
      self.scx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class applyCouponToCart_args:
  """
  Attributes:
   - cart
   - couponCode
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRUCT, 'cart', (Cart, Cart.thrift_spec), None, ), # 1
    (2, TType.STRING, 'couponCode', None, None, ), # 2
  )

  def __init__(self, cart=None, couponCode=None,):
    self.cart = cart
    self.couponCode = couponCode

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRUCT:
          self.cart = Cart()
          self.cart.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.STRING:
          self.couponCode = iprot.readString();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('applyCouponToCart_args')
    if self.cart is not None:
      oprot.writeFieldBegin('cart', TType.STRUCT, 1)
      self.cart.write(oprot)
      oprot.writeFieldEnd()
    if self.couponCode is not None:
      oprot.writeFieldBegin('couponCode', TType.STRING, 2)
      oprot.writeString(self.couponCode)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class applyCouponToCart_result:
  """
  Attributes:
   - scx
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRUCT, 'scx', (ShoppingCartException, ShoppingCartException.thrift_spec), None, ), # 1
  )

  def __init__(self, scx=None,):
    self.scx = scx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRUCT:
          self.scx = ShoppingCartException()
          self.scx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('applyCouponToCart_result')
    if self.scx is not None:
      oprot.writeFieldBegin('scx', TType.STRUCT, 1)
      self.scx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class removeCoupon_args:
  """
  Attributes:
   - cartId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'cartId', None, None, ), # 1
  )

  def __init__(self, cartId=None,):
    self.cartId = cartId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.cartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('removeCoupon_args')
    if self.cartId is not None:
      oprot.writeFieldBegin('cartId', TType.I64, 1)
      oprot.writeI64(self.cartId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class removeCoupon_result:
  """
  Attributes:
   - scx
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRUCT, 'scx', (ShoppingCartException, ShoppingCartException.thrift_spec), None, ), # 1
  )

  def __init__(self, scx=None,):
    self.scx = scx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRUCT:
          self.scx = ShoppingCartException()
          self.scx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('removeCoupon_result')
    if self.scx is not None:
      oprot.writeFieldBegin('scx', TType.STRUCT, 1)
      self.scx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class deleteDiscountsFromCart_args:
  """
  Attributes:
   - cartId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'cartId', None, None, ), # 1
  )

  def __init__(self, cartId=None,):
    self.cartId = cartId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.cartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('deleteDiscountsFromCart_args')
    if self.cartId is not None:
      oprot.writeFieldBegin('cartId', TType.I64, 1)
      oprot.writeI64(self.cartId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class deleteDiscountsFromCart_result:
  """
  Attributes:
   - scx
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRUCT, 'scx', (ShoppingCartException, ShoppingCartException.thrift_spec), None, ), # 1
  )

  def __init__(self, scx=None,):
    self.scx = scx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRUCT:
          self.scx = ShoppingCartException()
          self.scx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('deleteDiscountsFromCart_result')
    if self.scx is not None:
      oprot.writeFieldBegin('scx', TType.STRUCT, 1)
      self.scx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class saveDiscounts_args:
  """
  Attributes:
   - discounts
  """

  thrift_spec = (
    None, # 0
    (1, TType.LIST, 'discounts', (TType.STRUCT,(Discount, Discount.thrift_spec)), None, ), # 1
  )

  def __init__(self, discounts=None,):
    self.discounts = discounts

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.LIST:
          self.discounts = []
          (_etype163, _size160) = iprot.readListBegin()
          for _i164 in xrange(_size160):
            _elem165 = Discount()
            _elem165.read(iprot)
            self.discounts.append(_elem165)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('saveDiscounts_args')
    if self.discounts is not None:
      oprot.writeFieldBegin('discounts', TType.LIST, 1)
      oprot.writeListBegin(TType.STRUCT, len(self.discounts))
      for iter166 in self.discounts:
        iter166.write(oprot)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class saveDiscounts_result:
  """
  Attributes:
   - scx
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRUCT, 'scx', (ShoppingCartException, ShoppingCartException.thrift_spec), None, ), # 1
  )

  def __init__(self, scx=None,):
    self.scx = scx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRUCT:
          self.scx = ShoppingCartException()
          self.scx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('saveDiscounts_result')
    if self.scx is not None:
      oprot.writeFieldBegin('scx', TType.STRUCT, 1)
      self.scx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class createOrders_args:
  """
  Attributes:
   - cartId
   - sessionSource
   - sessionStartTime
   - firstSource
   - firstSourceTime
   - userId
   - schemeId
   - orderSource
   - selfPickup
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'cartId', None, None, ), # 1
    (2, TType.STRING, 'sessionSource', None, None, ), # 2
    (3, TType.I64, 'sessionStartTime', None, None, ), # 3
    (4, TType.STRING, 'firstSource', None, None, ), # 4
    (5, TType.I64, 'firstSourceTime', None, None, ), # 5
    (6, TType.I64, 'userId', None, None, ), # 6
    (7, TType.I64, 'schemeId', None, None, ), # 7
    (8, TType.I64, 'orderSource', None, None, ), # 8
    (9, TType.BOOL, 'selfPickup', None, None, ), # 9
  )

  def __init__(self, cartId=None, sessionSource=None, sessionStartTime=None, firstSource=None, firstSourceTime=None, userId=None, schemeId=None, orderSource=None, selfPickup=None,):
    self.cartId = cartId
    self.sessionSource = sessionSource
    self.sessionStartTime = sessionStartTime
    self.firstSource = firstSource
    self.firstSourceTime = firstSourceTime
    self.userId = userId
    self.schemeId = schemeId
    self.orderSource = orderSource
    self.selfPickup = selfPickup

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.cartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.STRING:
          self.sessionSource = iprot.readString();
        else:
          iprot.skip(ftype)
      elif fid == 3:
        if ftype == TType.I64:
          self.sessionStartTime = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 4:
        if ftype == TType.STRING:
          self.firstSource = iprot.readString();
        else:
          iprot.skip(ftype)
      elif fid == 5:
        if ftype == TType.I64:
          self.firstSourceTime = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 6:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 7:
        if ftype == TType.I64:
          self.schemeId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 8:
        if ftype == TType.I64:
          self.orderSource = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 9:
        if ftype == TType.BOOL:
          self.selfPickup = iprot.readBool();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('createOrders_args')
    if self.cartId is not None:
      oprot.writeFieldBegin('cartId', TType.I64, 1)
      oprot.writeI64(self.cartId)
      oprot.writeFieldEnd()
    if self.sessionSource is not None:
      oprot.writeFieldBegin('sessionSource', TType.STRING, 2)
      oprot.writeString(self.sessionSource)
      oprot.writeFieldEnd()
    if self.sessionStartTime is not None:
      oprot.writeFieldBegin('sessionStartTime', TType.I64, 3)
      oprot.writeI64(self.sessionStartTime)
      oprot.writeFieldEnd()
    if self.firstSource is not None:
      oprot.writeFieldBegin('firstSource', TType.STRING, 4)
      oprot.writeString(self.firstSource)
      oprot.writeFieldEnd()
    if self.firstSourceTime is not None:
      oprot.writeFieldBegin('firstSourceTime', TType.I64, 5)
      oprot.writeI64(self.firstSourceTime)
      oprot.writeFieldEnd()
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 6)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    if self.schemeId is not None:
      oprot.writeFieldBegin('schemeId', TType.I64, 7)
      oprot.writeI64(self.schemeId)
      oprot.writeFieldEnd()
    if self.orderSource is not None:
      oprot.writeFieldBegin('orderSource', TType.I64, 8)
      oprot.writeI64(self.orderSource)
      oprot.writeFieldEnd()
    if self.selfPickup is not None:
      oprot.writeFieldBegin('selfPickup', TType.BOOL, 9)
      oprot.writeBool(self.selfPickup)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class createOrders_result:
  """
  Attributes:
   - success
   - scx
  """

  thrift_spec = (
    (0, TType.I64, 'success', None, None, ), # 0
    (1, TType.STRUCT, 'scx', (ShoppingCartException, ShoppingCartException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, scx=None,):
    self.success = success
    self.scx = scx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.I64:
          self.success = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.scx = ShoppingCartException()
          self.scx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('createOrders_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.I64, 0)
      oprot.writeI64(self.success)
      oprot.writeFieldEnd()
    if self.scx is not None:
      oprot.writeFieldBegin('scx', TType.STRUCT, 1)
      self.scx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class validateCart_args:
  """
  Attributes:
   - cartId
   - sourceId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'cartId', None, None, ), # 1
    (2, TType.I64, 'sourceId', None, None, ), # 2
  )

  def __init__(self, cartId=None, sourceId=None,):
    self.cartId = cartId
    self.sourceId = sourceId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.cartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.sourceId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('validateCart_args')
    if self.cartId is not None:
      oprot.writeFieldBegin('cartId', TType.I64, 1)
      oprot.writeI64(self.cartId)
      oprot.writeFieldEnd()
    if self.sourceId is not None:
      oprot.writeFieldBegin('sourceId', TType.I64, 2)
      oprot.writeI64(self.sourceId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class validateCart_result:
  """
  Attributes:
   - success
   - scex
  """

  thrift_spec = (
    (0, TType.LIST, 'success', (TType.STRING,None), None, ), # 0
    (1, TType.STRUCT, 'scex', (ShoppingCartException, ShoppingCartException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, scex=None,):
    self.success = success
    self.scex = scex

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.LIST:
          self.success = []
          (_etype170, _size167) = iprot.readListBegin()
          for _i171 in xrange(_size167):
            _elem172 = iprot.readString();
            self.success.append(_elem172)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.scex = ShoppingCartException()
          self.scex.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('validateCart_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.LIST, 0)
      oprot.writeListBegin(TType.STRING, len(self.success))
      for iter173 in self.success:
        oprot.writeString(iter173)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    if self.scex is not None:
      oprot.writeFieldBegin('scex', TType.STRUCT, 1)
      self.scex.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class validateCartWithDealerCoupon_args:
  """
  Attributes:
   - cartId
   - sourceId
   - dealCoupon
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'cartId', None, None, ), # 1
    (2, TType.I64, 'sourceId', None, None, ), # 2
    (3, TType.STRING, 'dealCoupon', None, None, ), # 3
  )

  def __init__(self, cartId=None, sourceId=None, dealCoupon=None,):
    self.cartId = cartId
    self.sourceId = sourceId
    self.dealCoupon = dealCoupon

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.cartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.sourceId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 3:
        if ftype == TType.STRING:
          self.dealCoupon = iprot.readString();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('validateCartWithDealerCoupon_args')
    if self.cartId is not None:
      oprot.writeFieldBegin('cartId', TType.I64, 1)
      oprot.writeI64(self.cartId)
      oprot.writeFieldEnd()
    if self.sourceId is not None:
      oprot.writeFieldBegin('sourceId', TType.I64, 2)
      oprot.writeI64(self.sourceId)
      oprot.writeFieldEnd()
    if self.dealCoupon is not None:
      oprot.writeFieldBegin('dealCoupon', TType.STRING, 3)
      oprot.writeString(self.dealCoupon)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class validateCartWithDealerCoupon_result:
  """
  Attributes:
   - success
   - scex
  """

  thrift_spec = (
    (0, TType.LIST, 'success', (TType.STRING,None), None, ), # 0
    (1, TType.STRUCT, 'scex', (ShoppingCartException, ShoppingCartException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, scex=None,):
    self.success = success
    self.scex = scex

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.LIST:
          self.success = []
          (_etype177, _size174) = iprot.readListBegin()
          for _i178 in xrange(_size174):
            _elem179 = iprot.readString();
            self.success.append(_elem179)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.scex = ShoppingCartException()
          self.scex.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('validateCartWithDealerCoupon_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.LIST, 0)
      oprot.writeListBegin(TType.STRING, len(self.success))
      for iter180 in self.success:
        oprot.writeString(iter180)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    if self.scex is not None:
      oprot.writeFieldBegin('scex', TType.STRUCT, 1)
      self.scex.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class mergeCart_args:
  """
  Attributes:
   - fromCartId
   - toCartId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'fromCartId', None, None, ), # 1
    (2, TType.I64, 'toCartId', None, None, ), # 2
  )

  def __init__(self, fromCartId=None, toCartId=None,):
    self.fromCartId = fromCartId
    self.toCartId = toCartId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.fromCartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.toCartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('mergeCart_args')
    if self.fromCartId is not None:
      oprot.writeFieldBegin('fromCartId', TType.I64, 1)
      oprot.writeI64(self.fromCartId)
      oprot.writeFieldEnd()
    if self.toCartId is not None:
      oprot.writeFieldBegin('toCartId', TType.I64, 2)
      oprot.writeI64(self.toCartId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class mergeCart_result:

  thrift_spec = (
  )

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('mergeCart_result')
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class checkOut_args:
  """
  Attributes:
   - cartId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'cartId', None, None, ), # 1
  )

  def __init__(self, cartId=None,):
    self.cartId = cartId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.cartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('checkOut_args')
    if self.cartId is not None:
      oprot.writeFieldBegin('cartId', TType.I64, 1)
      oprot.writeI64(self.cartId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class checkOut_result:
  """
  Attributes:
   - success
   - scex
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
    (1, TType.STRUCT, 'scex', (ShoppingCartException, ShoppingCartException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, scex=None,):
    self.success = success
    self.scex = scex

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.scex = ShoppingCartException()
          self.scex.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('checkOut_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    if self.scex is not None:
      oprot.writeFieldBegin('scex', TType.STRUCT, 1)
      self.scex.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class resetCart_args:
  """
  Attributes:
   - cartId
   - items
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'cartId', None, None, ), # 1
    (2, TType.MAP, 'items', (TType.I64,None,TType.DOUBLE,None), None, ), # 2
  )

  def __init__(self, cartId=None, items=None,):
    self.cartId = cartId
    self.items = items

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.cartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.MAP:
          self.items = {}
          (_ktype182, _vtype183, _size181 ) = iprot.readMapBegin() 
          for _i185 in xrange(_size181):
            _key186 = iprot.readI64();
            _val187 = iprot.readDouble();
            self.items[_key186] = _val187
          iprot.readMapEnd()
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('resetCart_args')
    if self.cartId is not None:
      oprot.writeFieldBegin('cartId', TType.I64, 1)
      oprot.writeI64(self.cartId)
      oprot.writeFieldEnd()
    if self.items is not None:
      oprot.writeFieldBegin('items', TType.MAP, 2)
      oprot.writeMapBegin(TType.I64, TType.DOUBLE, len(self.items))
      for kiter188,viter189 in self.items.items():
        oprot.writeI64(kiter188)
        oprot.writeDouble(viter189)
      oprot.writeMapEnd()
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class resetCart_result:
  """
  Attributes:
   - success
   - scex
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
    (1, TType.STRUCT, 'scex', (ShoppingCartException, ShoppingCartException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, scex=None,):
    self.success = success
    self.scex = scex

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.scex = ShoppingCartException()
          self.scex.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('resetCart_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    if self.scex is not None:
      oprot.writeFieldBegin('scex', TType.STRUCT, 1)
      self.scex.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getUserCount_args:
  """
  Attributes:
   - userType
  """

  thrift_spec = (
    None, # 0
    (1, TType.I32, 'userType', None, None, ), # 1
  )

  def __init__(self, userType=None,):
    self.userType = userType

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I32:
          self.userType = iprot.readI32();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getUserCount_args')
    if self.userType is not None:
      oprot.writeFieldBegin('userType', TType.I32, 1)
      oprot.writeI32(self.userType)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getUserCount_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.I64, 'success', None, None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.I64:
          self.success = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getUserCount_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.I64, 0)
      oprot.writeI64(self.success)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getAllUsers_args:
  """
  Attributes:
   - userType
   - startDate
   - endDate
  """

  thrift_spec = (
    None, # 0
    (1, TType.I32, 'userType', None, None, ), # 1
    (2, TType.I64, 'startDate', None, None, ), # 2
    (3, TType.I64, 'endDate', None, None, ), # 3
  )

  def __init__(self, userType=None, startDate=None, endDate=None,):
    self.userType = userType
    self.startDate = startDate
    self.endDate = endDate

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I32:
          self.userType = iprot.readI32();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.startDate = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 3:
        if ftype == TType.I64:
          self.endDate = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getAllUsers_args')
    if self.userType is not None:
      oprot.writeFieldBegin('userType', TType.I32, 1)
      oprot.writeI32(self.userType)
      oprot.writeFieldEnd()
    if self.startDate is not None:
      oprot.writeFieldBegin('startDate', TType.I64, 2)
      oprot.writeI64(self.startDate)
      oprot.writeFieldEnd()
    if self.endDate is not None:
      oprot.writeFieldBegin('endDate', TType.I64, 3)
      oprot.writeI64(self.endDate)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getAllUsers_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.LIST, 'success', (TType.STRUCT,(User, User.thrift_spec)), None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.LIST:
          self.success = []
          (_etype193, _size190) = iprot.readListBegin()
          for _i194 in xrange(_size190):
            _elem195 = User()
            _elem195.read(iprot)
            self.success.append(_elem195)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getAllUsers_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.LIST, 0)
      oprot.writeListBegin(TType.STRUCT, len(self.success))
      for iter196 in self.success:
        iter196.write(oprot)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getMyResearchItems_args:
  """
  Attributes:
   - userId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
  )

  def __init__(self, userId=None,):
    self.userId = userId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getMyResearchItems_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getMyResearchItems_result:
  """
  Attributes:
   - success
   - scx
  """

  thrift_spec = (
    (0, TType.LIST, 'success', (TType.I64,None), None, ), # 0
    (1, TType.STRUCT, 'scx', (WidgetException, WidgetException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, scx=None,):
    self.success = success
    self.scx = scx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.LIST:
          self.success = []
          (_etype200, _size197) = iprot.readListBegin()
          for _i201 in xrange(_size197):
            _elem202 = iprot.readI64();
            self.success.append(_elem202)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.scx = WidgetException()
          self.scx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getMyResearchItems_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.LIST, 0)
      oprot.writeListBegin(TType.I64, len(self.success))
      for iter203 in self.success:
        oprot.writeI64(iter203)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    if self.scx is not None:
      oprot.writeFieldBegin('scx', TType.STRUCT, 1)
      self.scx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class updateMyResearch_args:
  """
  Attributes:
   - userId
   - itemId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
    (2, TType.I64, 'itemId', None, None, ), # 2
  )

  def __init__(self, userId=None, itemId=None,):
    self.userId = userId
    self.itemId = itemId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.itemId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('updateMyResearch_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    if self.itemId is not None:
      oprot.writeFieldBegin('itemId', TType.I64, 2)
      oprot.writeI64(self.itemId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class updateMyResearch_result:
  """
  Attributes:
   - success
   - scx
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
    (1, TType.STRUCT, 'scx', (WidgetException, WidgetException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, scx=None,):
    self.success = success
    self.scx = scx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.scx = WidgetException()
          self.scx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('updateMyResearch_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    if self.scx is not None:
      oprot.writeFieldBegin('scx', TType.STRUCT, 1)
      self.scx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class deleteItemFromMyResearch_args:
  """
  Attributes:
   - userId
   - itemId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
    (2, TType.I64, 'itemId', None, None, ), # 2
  )

  def __init__(self, userId=None, itemId=None,):
    self.userId = userId
    self.itemId = itemId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.itemId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('deleteItemFromMyResearch_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    if self.itemId is not None:
      oprot.writeFieldBegin('itemId', TType.I64, 2)
      oprot.writeI64(self.itemId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class deleteItemFromMyResearch_result:
  """
  Attributes:
   - scx
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRUCT, 'scx', (WidgetException, WidgetException.thrift_spec), None, ), # 1
  )

  def __init__(self, scx=None,):
    self.scx = scx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRUCT:
          self.scx = WidgetException()
          self.scx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('deleteItemFromMyResearch_result')
    if self.scx is not None:
      oprot.writeFieldBegin('scx', TType.STRUCT, 1)
      self.scx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getBrowseHistoryItems_args:
  """
  Attributes:
   - userId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
  )

  def __init__(self, userId=None,):
    self.userId = userId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getBrowseHistoryItems_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getBrowseHistoryItems_result:
  """
  Attributes:
   - success
   - scx
  """

  thrift_spec = (
    (0, TType.LIST, 'success', (TType.I64,None), None, ), # 0
    (1, TType.STRUCT, 'scx', (WidgetException, WidgetException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, scx=None,):
    self.success = success
    self.scx = scx

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.LIST:
          self.success = []
          (_etype207, _size204) = iprot.readListBegin()
          for _i208 in xrange(_size204):
            _elem209 = iprot.readI64();
            self.success.append(_elem209)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.scx = WidgetException()
          self.scx.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getBrowseHistoryItems_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.LIST, 0)
      oprot.writeListBegin(TType.I64, len(self.success))
      for iter210 in self.success:
        oprot.writeI64(iter210)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    if self.scx is not None:
      oprot.writeFieldBegin('scx', TType.STRUCT, 1)
      self.scx.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class updateBrowseHistory_args:
  """
  Attributes:
   - userId
   - itemId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
    (2, TType.I64, 'itemId', None, None, ), # 2
  )

  def __init__(self, userId=None, itemId=None,):
    self.userId = userId
    self.itemId = itemId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.itemId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('updateBrowseHistory_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    if self.itemId is not None:
      oprot.writeFieldBegin('itemId', TType.I64, 2)
      oprot.writeI64(self.itemId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class updateBrowseHistory_result:

  thrift_spec = (
  )

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('updateBrowseHistory_result')
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getCartsWithCouponCount_args:
  """
  Attributes:
   - couponCode
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRING, 'couponCode', None, None, ), # 1
  )

  def __init__(self, couponCode=None,):
    self.couponCode = couponCode

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRING:
          self.couponCode = iprot.readString();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getCartsWithCouponCount_args')
    if self.couponCode is not None:
      oprot.writeFieldBegin('couponCode', TType.STRING, 1)
      oprot.writeString(self.couponCode)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getCartsWithCouponCount_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.I64, 'success', None, None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.I64:
          self.success = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getCartsWithCouponCount_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.I64, 0)
      oprot.writeI64(self.success)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class increaseTrustLevel_args:
  """
  Attributes:
   - userId
   - trustLevelDelta
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
    (2, TType.DOUBLE, 'trustLevelDelta', None, None, ), # 2
  )

  def __init__(self, userId=None, trustLevelDelta=None,):
    self.userId = userId
    self.trustLevelDelta = trustLevelDelta

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.DOUBLE:
          self.trustLevelDelta = iprot.readDouble();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('increaseTrustLevel_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    if self.trustLevelDelta is not None:
      oprot.writeFieldBegin('trustLevelDelta', TType.DOUBLE, 2)
      oprot.writeDouble(self.trustLevelDelta)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getTrustLevel_args:
  """
  Attributes:
   - userId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
  )

  def __init__(self, userId=None,):
    self.userId = userId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getTrustLevel_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getTrustLevel_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.DOUBLE, 'success', None, None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.DOUBLE:
          self.success = iprot.readDouble();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getTrustLevel_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.DOUBLE, 0)
      oprot.writeDouble(self.success)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class showCODOption_args:
  """
  Attributes:
   - cartId
   - sourceId
   - pincode
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'cartId', None, None, ), # 1
    (2, TType.I64, 'sourceId', None, None, ), # 2
    (3, TType.STRING, 'pincode', None, None, ), # 3
  )

  def __init__(self, cartId=None, sourceId=None, pincode=None,):
    self.cartId = cartId
    self.sourceId = sourceId
    self.pincode = pincode

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.cartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.sourceId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 3:
        if ftype == TType.STRING:
          self.pincode = iprot.readString();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('showCODOption_args')
    if self.cartId is not None:
      oprot.writeFieldBegin('cartId', TType.I64, 1)
      oprot.writeI64(self.cartId)
      oprot.writeFieldEnd()
    if self.sourceId is not None:
      oprot.writeFieldBegin('sourceId', TType.I64, 2)
      oprot.writeI64(self.sourceId)
      oprot.writeFieldEnd()
    if self.pincode is not None:
      oprot.writeFieldBegin('pincode', TType.STRING, 3)
      oprot.writeString(self.pincode)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class showCODOption_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('showCODOption_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getUserEmails_args:
  """
  Attributes:
   - startDate
   - endDate
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'startDate', None, None, ), # 1
    (2, TType.I64, 'endDate', None, None, ), # 2
  )

  def __init__(self, startDate=None, endDate=None,):
    self.startDate = startDate
    self.endDate = endDate

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.startDate = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.endDate = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getUserEmails_args')
    if self.startDate is not None:
      oprot.writeFieldBegin('startDate', TType.I64, 1)
      oprot.writeI64(self.startDate)
      oprot.writeFieldEnd()
    if self.endDate is not None:
      oprot.writeFieldBegin('endDate', TType.I64, 2)
      oprot.writeI64(self.endDate)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getUserEmails_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.LIST, 'success', (TType.STRING,None), None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.LIST:
          self.success = []
          (_etype214, _size211) = iprot.readListBegin()
          for _i215 in xrange(_size211):
            _elem216 = iprot.readString();
            self.success.append(_elem216)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getUserEmails_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.LIST, 0)
      oprot.writeListBegin(TType.STRING, len(self.success))
      for iter217 in self.success:
        oprot.writeString(iter217)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class insureItem_args:
  """
  Attributes:
   - itemId
   - cartId
   - toInsure
   - insurerType
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'itemId', None, None, ), # 1
    (2, TType.I64, 'cartId', None, None, ), # 2
    (3, TType.BOOL, 'toInsure', None, None, ), # 3
    (4, TType.I32, 'insurerType', None, None, ), # 4
  )

  def __init__(self, itemId=None, cartId=None, toInsure=None, insurerType=None,):
    self.itemId = itemId
    self.cartId = cartId
    self.toInsure = toInsure
    self.insurerType = insurerType

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.itemId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.cartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 3:
        if ftype == TType.BOOL:
          self.toInsure = iprot.readBool();
        else:
          iprot.skip(ftype)
      elif fid == 4:
        if ftype == TType.I32:
          self.insurerType = iprot.readI32();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('insureItem_args')
    if self.itemId is not None:
      oprot.writeFieldBegin('itemId', TType.I64, 1)
      oprot.writeI64(self.itemId)
      oprot.writeFieldEnd()
    if self.cartId is not None:
      oprot.writeFieldBegin('cartId', TType.I64, 2)
      oprot.writeI64(self.cartId)
      oprot.writeFieldEnd()
    if self.toInsure is not None:
      oprot.writeFieldBegin('toInsure', TType.BOOL, 3)
      oprot.writeBool(self.toInsure)
      oprot.writeFieldEnd()
    if self.insurerType is not None:
      oprot.writeFieldBegin('insurerType', TType.I32, 4)
      oprot.writeI32(self.insurerType)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class insureItem_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('insureItem_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class cancelInsurance_args:
  """
  Attributes:
   - cartId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'cartId', None, None, ), # 1
  )

  def __init__(self, cartId=None,):
    self.cartId = cartId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.cartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('cancelInsurance_args')
    if self.cartId is not None:
      oprot.writeFieldBegin('cartId', TType.I64, 1)
      oprot.writeI64(self.cartId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class cancelInsurance_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('cancelInsurance_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class storeInsuranceSpecificDetails_args:
  """
  Attributes:
   - addressId
   - dob
   - guardianName
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'addressId', None, None, ), # 1
    (2, TType.STRING, 'dob', None, None, ), # 2
    (3, TType.STRING, 'guardianName', None, None, ), # 3
  )

  def __init__(self, addressId=None, dob=None, guardianName=None,):
    self.addressId = addressId
    self.dob = dob
    self.guardianName = guardianName

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.addressId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.STRING:
          self.dob = iprot.readString();
        else:
          iprot.skip(ftype)
      elif fid == 3:
        if ftype == TType.STRING:
          self.guardianName = iprot.readString();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('storeInsuranceSpecificDetails_args')
    if self.addressId is not None:
      oprot.writeFieldBegin('addressId', TType.I64, 1)
      oprot.writeI64(self.addressId)
      oprot.writeFieldEnd()
    if self.dob is not None:
      oprot.writeFieldBegin('dob', TType.STRING, 2)
      oprot.writeString(self.dob)
      oprot.writeFieldEnd()
    if self.guardianName is not None:
      oprot.writeFieldBegin('guardianName', TType.STRING, 3)
      oprot.writeString(self.guardianName)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class storeInsuranceSpecificDetails_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('storeInsuranceSpecificDetails_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class isInsuranceDetailPresent_args:
  """
  Attributes:
   - addressId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'addressId', None, None, ), # 1
  )

  def __init__(self, addressId=None,):
    self.addressId = addressId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.addressId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('isInsuranceDetailPresent_args')
    if self.addressId is not None:
      oprot.writeFieldBegin('addressId', TType.I64, 1)
      oprot.writeI64(self.addressId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class isInsuranceDetailPresent_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('isInsuranceDetailPresent_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getProductsAddedToCart_args:
  """
  Attributes:
   - startDate
   - endDate
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'startDate', None, None, ), # 1
    (2, TType.I64, 'endDate', None, None, ), # 2
  )

  def __init__(self, startDate=None, endDate=None,):
    self.startDate = startDate
    self.endDate = endDate

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.startDate = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.endDate = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getProductsAddedToCart_args')
    if self.startDate is not None:
      oprot.writeFieldBegin('startDate', TType.I64, 1)
      oprot.writeI64(self.startDate)
      oprot.writeFieldEnd()
    if self.endDate is not None:
      oprot.writeFieldBegin('endDate', TType.I64, 2)
      oprot.writeI64(self.endDate)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getProductsAddedToCart_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.LIST, 'success', (TType.I64,None), None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.LIST:
          self.success = []
          (_etype221, _size218) = iprot.readListBegin()
          for _i222 in xrange(_size218):
            _elem223 = iprot.readI64();
            self.success.append(_elem223)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getProductsAddedToCart_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.LIST, 0)
      oprot.writeListBegin(TType.I64, len(self.success))
      for iter224 in self.success:
        oprot.writeI64(iter224)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class validateCartPlus_args:
  """
  Attributes:
   - cartId
   - sourceId
   - dealerCoupon
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'cartId', None, None, ), # 1
    (2, TType.I64, 'sourceId', None, None, ), # 2
    (3, TType.STRING, 'dealerCoupon', None, None, ), # 3
  )

  def __init__(self, cartId=None, sourceId=None, dealerCoupon=None,):
    self.cartId = cartId
    self.sourceId = sourceId
    self.dealerCoupon = dealerCoupon

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.cartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.sourceId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 3:
        if ftype == TType.STRING:
          self.dealerCoupon = iprot.readString();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('validateCartPlus_args')
    if self.cartId is not None:
      oprot.writeFieldBegin('cartId', TType.I64, 1)
      oprot.writeI64(self.cartId)
      oprot.writeFieldEnd()
    if self.sourceId is not None:
      oprot.writeFieldBegin('sourceId', TType.I64, 2)
      oprot.writeI64(self.sourceId)
      oprot.writeFieldEnd()
    if self.dealerCoupon is not None:
      oprot.writeFieldBegin('dealerCoupon', TType.STRING, 3)
      oprot.writeString(self.dealerCoupon)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class validateCartPlus_result:
  """
  Attributes:
   - success
   - scex
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (CartPlus, CartPlus.thrift_spec), None, ), # 0
    (1, TType.STRUCT, 'scex', (ShoppingCartException, ShoppingCartException.thrift_spec), None, ), # 1
  )

  def __init__(self, success=None, scex=None,):
    self.success = success
    self.scex = scex

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = CartPlus()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 1:
        if ftype == TType.STRUCT:
          self.scex = ShoppingCartException()
          self.scex.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('validateCartPlus_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    if self.scex is not None:
      oprot.writeFieldBegin('scex', TType.STRUCT, 1)
      self.scex.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class isPrivateDealUser_args:
  """
  Attributes:
   - userId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
  )

  def __init__(self, userId=None,):
    self.userId = userId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('isPrivateDealUser_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class isPrivateDealUser_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('isPrivateDealUser_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class addPrivateDealUser_args:
  """
  Attributes:
   - userId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
  )

  def __init__(self, userId=None,):
    self.userId = userId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('addPrivateDealUser_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class addPrivateDealUser_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('addPrivateDealUser_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class changePrivateDealUserStatus_args:
  """
  Attributes:
   - userId
   - isActive
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
    (2, TType.BOOL, 'isActive', None, None, ), # 2
  )

  def __init__(self, userId=None, isActive=None,):
    self.userId = userId
    self.isActive = isActive

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.BOOL:
          self.isActive = iprot.readBool();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('changePrivateDealUserStatus_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    if self.isActive is not None:
      oprot.writeFieldBegin('isActive', TType.BOOL, 2)
      oprot.writeBool(self.isActive)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class changePrivateDealUserStatus_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('changePrivateDealUserStatus_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getPrivateDealUser_args:
  """
  Attributes:
   - userId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
  )

  def __init__(self, userId=None,):
    self.userId = userId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getPrivateDealUser_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getPrivateDealUser_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (PrivateDealUser, PrivateDealUser.thrift_spec), None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = PrivateDealUser()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getPrivateDealUser_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class registerCounter_args:
  """
  Attributes:
   - counter
   - userId
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRUCT, 'counter', (Counter, Counter.thrift_spec), None, ), # 1
    (2, TType.I64, 'userId', None, None, ), # 2
  )

  def __init__(self, counter=None, userId=None,):
    self.counter = counter
    self.userId = userId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRUCT:
          self.counter = Counter()
          self.counter.read(iprot)
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('registerCounter_args')
    if self.counter is not None:
      oprot.writeFieldBegin('counter', TType.STRUCT, 1)
      self.counter.write(oprot)
      oprot.writeFieldEnd()
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 2)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class registerCounter_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.MAP, 'success', (TType.STRING,None,TType.STRING,None), None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.MAP:
          self.success = {}
          (_ktype226, _vtype227, _size225 ) = iprot.readMapBegin() 
          for _i229 in xrange(_size225):
            _key230 = iprot.readString();
            _val231 = iprot.readString();
            self.success[_key230] = _val231
          iprot.readMapEnd()
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('registerCounter_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.MAP, 0)
      oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.success))
      for kiter232,viter233 in self.success.items():
        oprot.writeString(kiter232)
        oprot.writeString(viter233)
      oprot.writeMapEnd()
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class searchCounter_args:
  """
  Attributes:
   - type1
   - searchString
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRING, 'type1', None, None, ), # 1
    (2, TType.STRING, 'searchString', None, None, ), # 2
  )

  def __init__(self, type1=None, searchString=None,):
    self.type1 = type1
    self.searchString = searchString

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRING:
          self.type1 = iprot.readString();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.STRING:
          self.searchString = iprot.readString();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('searchCounter_args')
    if self.type1 is not None:
      oprot.writeFieldBegin('type1', TType.STRING, 1)
      oprot.writeString(self.type1)
      oprot.writeFieldEnd()
    if self.searchString is not None:
      oprot.writeFieldBegin('searchString', TType.STRING, 2)
      oprot.writeString(self.searchString)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class searchCounter_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.LIST, 'success', (TType.STRUCT,(Counter, Counter.thrift_spec)), None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.LIST:
          self.success = []
          (_etype237, _size234) = iprot.readListBegin()
          for _i238 in xrange(_size234):
            _elem239 = Counter()
            _elem239.read(iprot)
            self.success.append(_elem239)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('searchCounter_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.LIST, 0)
      oprot.writeListBegin(TType.STRUCT, len(self.success))
      for iter240 in self.success:
        iter240.write(oprot)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getCounterByUserId_args:
  """
  Attributes:
   - userId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
  )

  def __init__(self, userId=None,):
    self.userId = userId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getCounterByUserId_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getCounterByUserId_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (Counter, Counter.thrift_spec), None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = Counter()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getCounterByUserId_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getAllUsersByCounter_args:
  """
  Attributes:
   - counterId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'counterId', None, None, ), # 1
  )

  def __init__(self, counterId=None,):
    self.counterId = counterId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.counterId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getAllUsersByCounter_args')
    if self.counterId is not None:
      oprot.writeFieldBegin('counterId', TType.I64, 1)
      oprot.writeI64(self.counterId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getAllUsersByCounter_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.LIST, 'success', (TType.STRUCT,(User, User.thrift_spec)), None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.LIST:
          self.success = []
          (_etype244, _size241) = iprot.readListBegin()
          for _i245 in xrange(_size241):
            _elem246 = User()
            _elem246.read(iprot)
            self.success.append(_elem246)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getAllUsersByCounter_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.LIST, 0)
      oprot.writeListBegin(TType.STRUCT, len(self.success))
      for iter247 in self.success:
        iter247.write(oprot)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getActiveAccessTokenForUser_args:
  """
  Attributes:
   - userId
   - source
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
    (2, TType.STRING, 'source', None, None, ), # 2
  )

  def __init__(self, userId=None, source=None,):
    self.userId = userId
    self.source = source

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.STRING:
          self.source = iprot.readString();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getActiveAccessTokenForUser_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    if self.source is not None:
      oprot.writeFieldBegin('source', TType.STRING, 2)
      oprot.writeString(self.source)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getActiveAccessTokenForUser_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.STRING, 'success', None, None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRING:
          self.success = iprot.readString();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getActiveAccessTokenForUser_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRING, 0)
      oprot.writeString(self.success)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class validateAccessToken_args:
  """
  Attributes:
   - accessToken
  """

  thrift_spec = (
    None, # 0
    (1, TType.STRING, 'accessToken', None, None, ), # 1
  )

  def __init__(self, accessToken=None,):
    self.accessToken = accessToken

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.STRING:
          self.accessToken = iprot.readString();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('validateAccessToken_args')
    if self.accessToken is not None:
      oprot.writeFieldBegin('accessToken', TType.STRING, 1)
      oprot.writeString(self.accessToken)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class validateAccessToken_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('validateAccessToken_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class addItemsToCart_args:
  """
  Attributes:
   - cartId
   - itemQty
   - couponCode
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'cartId', None, None, ), # 1
    (2, TType.LIST, 'itemQty', (TType.STRUCT,(ItemQuantity, ItemQuantity.thrift_spec)), None, ), # 2
    (3, TType.STRING, 'couponCode', None, None, ), # 3
  )

  def __init__(self, cartId=None, itemQty=None, couponCode=None,):
    self.cartId = cartId
    self.itemQty = itemQty
    self.couponCode = couponCode

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.cartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.LIST:
          self.itemQty = []
          (_etype251, _size248) = iprot.readListBegin()
          for _i252 in xrange(_size248):
            _elem253 = ItemQuantity()
            _elem253.read(iprot)
            self.itemQty.append(_elem253)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      elif fid == 3:
        if ftype == TType.STRING:
          self.couponCode = iprot.readString();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('addItemsToCart_args')
    if self.cartId is not None:
      oprot.writeFieldBegin('cartId', TType.I64, 1)
      oprot.writeI64(self.cartId)
      oprot.writeFieldEnd()
    if self.itemQty is not None:
      oprot.writeFieldBegin('itemQty', TType.LIST, 2)
      oprot.writeListBegin(TType.STRUCT, len(self.itemQty))
      for iter254 in self.itemQty:
        iter254.write(oprot)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    if self.couponCode is not None:
      oprot.writeFieldBegin('couponCode', TType.STRING, 3)
      oprot.writeString(self.couponCode)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class addItemsToCart_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('addItemsToCart_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class validateCartNew_args:
  """
  Attributes:
   - cartId
   - pinCode
   - sourceId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'cartId', None, None, ), # 1
    (2, TType.STRING, 'pinCode', None, None, ), # 2
    (3, TType.I64, 'sourceId', None, None, ), # 3
  )

  def __init__(self, cartId=None, pinCode=None, sourceId=None,):
    self.cartId = cartId
    self.pinCode = pinCode
    self.sourceId = sourceId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.cartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.STRING:
          self.pinCode = iprot.readString();
        else:
          iprot.skip(ftype)
      elif fid == 3:
        if ftype == TType.I64:
          self.sourceId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('validateCartNew_args')
    if self.cartId is not None:
      oprot.writeFieldBegin('cartId', TType.I64, 1)
      oprot.writeI64(self.cartId)
      oprot.writeFieldEnd()
    if self.pinCode is not None:
      oprot.writeFieldBegin('pinCode', TType.STRING, 2)
      oprot.writeString(self.pinCode)
      oprot.writeFieldEnd()
    if self.sourceId is not None:
      oprot.writeFieldBegin('sourceId', TType.I64, 3)
      oprot.writeI64(self.sourceId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class validateCartNew_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.STRING, 'success', None, None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRING:
          self.success = iprot.readString();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('validateCartNew_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRING, 0)
      oprot.writeString(self.success)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class isAddressEditableForCounter_args:
  """
  Attributes:
   - userId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
  )

  def __init__(self, userId=None,):
    self.userId = userId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('isAddressEditableForCounter_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class isAddressEditableForCounter_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('isAddressEditableForCounter_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getBillingAddressForUser_args:
  """
  Attributes:
   - userId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
  )

  def __init__(self, userId=None,):
    self.userId = userId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getBillingAddressForUser_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getBillingAddressForUser_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.STRUCT, 'success', (Address, Address.thrift_spec), None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.STRUCT:
          self.success = Address()
          self.success.read(iprot)
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getBillingAddressForUser_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
      self.success.write(oprot)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class isCreditorAssigned_args:
  """
  Attributes:
   - userId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
  )

  def __init__(self, userId=None,):
    self.userId = userId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('isCreditorAssigned_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class isCreditorAssigned_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('isCreditorAssigned_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class isTaxInvoiceEnabledUser_args:
  """
  Attributes:
   - userId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'userId', None, None, ), # 1
  )

  def __init__(self, userId=None,):
    self.userId = userId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.userId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('isTaxInvoiceEnabledUser_args')
    if self.userId is not None:
      oprot.writeFieldBegin('userId', TType.I64, 1)
      oprot.writeI64(self.userId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class isTaxInvoiceEnabledUser_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('isTaxInvoiceEnabledUser_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class taxInvoiceAvailable_args:
  """
  Attributes:
   - addressId
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'addressId', None, None, ), # 1
  )

  def __init__(self, addressId=None,):
    self.addressId = addressId

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.addressId = iprot.readI64();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('taxInvoiceAvailable_args')
    if self.addressId is not None:
      oprot.writeFieldBegin('addressId', TType.I64, 1)
      oprot.writeI64(self.addressId)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class taxInvoiceAvailable_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('taxInvoiceAvailable_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getCartByValue_args:
  """
  Attributes:
   - cartIds
  """

  thrift_spec = (
    None, # 0
    (1, TType.LIST, 'cartIds', (TType.I64,None), None, ), # 1
  )

  def __init__(self, cartIds=None,):
    self.cartIds = cartIds

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.LIST:
          self.cartIds = []
          (_etype258, _size255) = iprot.readListBegin()
          for _i259 in xrange(_size255):
            _elem260 = iprot.readI64();
            self.cartIds.append(_elem260)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getCartByValue_args')
    if self.cartIds is not None:
      oprot.writeFieldBegin('cartIds', TType.LIST, 1)
      oprot.writeListBegin(TType.I64, len(self.cartIds))
      for iter261 in self.cartIds:
        oprot.writeI64(iter261)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getCartByValue_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.MAP, 'success', (TType.I64,None,TType.LIST,(TType.STRUCT,(Line, Line.thrift_spec))), None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.MAP:
          self.success = {}
          (_ktype263, _vtype264, _size262 ) = iprot.readMapBegin() 
          for _i266 in xrange(_size262):
            _key267 = iprot.readI64();
            _val268 = []
            (_etype272, _size269) = iprot.readListBegin()
            for _i273 in xrange(_size269):
              _elem274 = Line()
              _elem274.read(iprot)
              _val268.append(_elem274)
            iprot.readListEnd()
            self.success[_key267] = _val268
          iprot.readMapEnd()
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getCartByValue_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.MAP, 0)
      oprot.writeMapBegin(TType.I64, TType.LIST, len(self.success))
      for kiter275,viter276 in self.success.items():
        oprot.writeI64(kiter275)
        oprot.writeListBegin(TType.STRUCT, len(viter276))
        for iter277 in viter276:
          iter277.write(oprot)
        oprot.writeListEnd()
      oprot.writeMapEnd()
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getCounterName_args:
  """
  Attributes:
   - userIds
  """

  thrift_spec = (
    None, # 0
    (1, TType.LIST, 'userIds', (TType.I64,None), None, ), # 1
  )

  def __init__(self, userIds=None,):
    self.userIds = userIds

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.LIST:
          self.userIds = []
          (_etype281, _size278) = iprot.readListBegin()
          for _i282 in xrange(_size278):
            _elem283 = iprot.readI64();
            self.userIds.append(_elem283)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getCounterName_args')
    if self.userIds is not None:
      oprot.writeFieldBegin('userIds', TType.LIST, 1)
      oprot.writeListBegin(TType.I64, len(self.userIds))
      for iter284 in self.userIds:
        oprot.writeI64(iter284)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class getCounterName_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.MAP, 'success', (TType.I64,None,TType.STRING,None), None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.MAP:
          self.success = {}
          (_ktype286, _vtype287, _size285 ) = iprot.readMapBegin() 
          for _i289 in xrange(_size285):
            _key290 = iprot.readI64();
            _val291 = iprot.readString();
            self.success[_key290] = _val291
          iprot.readMapEnd()
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('getCounterName_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.MAP, 0)
      oprot.writeMapBegin(TType.I64, TType.STRING, len(self.success))
      for kiter292,viter293 in self.success.items():
        oprot.writeI64(kiter292)
        oprot.writeString(viter293)
      oprot.writeMapEnd()
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class setWalletAmountInCart_args:
  """
  Attributes:
   - cartId
   - wallet_amount
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'cartId', None, None, ), # 1
    (2, TType.DOUBLE, 'wallet_amount', None, None, ), # 2
  )

  def __init__(self, cartId=None, wallet_amount=None,):
    self.cartId = cartId
    self.wallet_amount = wallet_amount

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.cartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.DOUBLE:
          self.wallet_amount = iprot.readDouble();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('setWalletAmountInCart_args')
    if self.cartId is not None:
      oprot.writeFieldBegin('cartId', TType.I64, 1)
      oprot.writeI64(self.cartId)
      oprot.writeFieldEnd()
    if self.wallet_amount is not None:
      oprot.writeFieldBegin('wallet_amount', TType.DOUBLE, 2)
      oprot.writeDouble(self.wallet_amount)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class setWalletAmountInCart_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('setWalletAmountInCart_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class addItemPricingToCart_args:
  """
  Attributes:
   - cartId
   - itemPriceQuantityList
  """

  thrift_spec = (
    None, # 0
    (1, TType.I64, 'cartId', None, None, ), # 1
    (2, TType.LIST, 'itemPriceQuantityList', (TType.STRUCT,(ItemPriceQuantity, ItemPriceQuantity.thrift_spec)), None, ), # 2
  )

  def __init__(self, cartId=None, itemPriceQuantityList=None,):
    self.cartId = cartId
    self.itemPriceQuantityList = itemPriceQuantityList

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 1:
        if ftype == TType.I64:
          self.cartId = iprot.readI64();
        else:
          iprot.skip(ftype)
      elif fid == 2:
        if ftype == TType.LIST:
          self.itemPriceQuantityList = []
          (_etype297, _size294) = iprot.readListBegin()
          for _i298 in xrange(_size294):
            _elem299 = ItemPriceQuantity()
            _elem299.read(iprot)
            self.itemPriceQuantityList.append(_elem299)
          iprot.readListEnd()
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('addItemPricingToCart_args')
    if self.cartId is not None:
      oprot.writeFieldBegin('cartId', TType.I64, 1)
      oprot.writeI64(self.cartId)
      oprot.writeFieldEnd()
    if self.itemPriceQuantityList is not None:
      oprot.writeFieldBegin('itemPriceQuantityList', TType.LIST, 2)
      oprot.writeListBegin(TType.STRUCT, len(self.itemPriceQuantityList))
      for iter300 in self.itemPriceQuantityList:
        iter300.write(oprot)
      oprot.writeListEnd()
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)

class addItemPricingToCart_result:
  """
  Attributes:
   - success
  """

  thrift_spec = (
    (0, TType.BOOL, 'success', None, None, ), # 0
  )

  def __init__(self, success=None,):
    self.success = success

  def read(self, iprot):
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
      return
    iprot.readStructBegin()
    while True:
      (fname, ftype, fid) = iprot.readFieldBegin()
      if ftype == TType.STOP:
        break
      if fid == 0:
        if ftype == TType.BOOL:
          self.success = iprot.readBool();
        else:
          iprot.skip(ftype)
      else:
        iprot.skip(ftype)
      iprot.readFieldEnd()
    iprot.readStructEnd()

  def write(self, oprot):
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
      return
    oprot.writeStructBegin('addItemPricingToCart_result')
    if self.success is not None:
      oprot.writeFieldBegin('success', TType.BOOL, 0)
      oprot.writeBool(self.success)
      oprot.writeFieldEnd()
    oprot.writeFieldStop()
    oprot.writeStructEnd()

  def validate(self):
    return


  def __repr__(self):
    L = ['%s=%r' % (key, value)
      for key, value in self.__dict__.iteritems()]
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))

  def __eq__(self, other):
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__

  def __ne__(self, other):
    return not (self == other)