ExproductconfResponse.py 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145
  1. #!/usr/bin/env python
  2. # -*- coding: utf-8 -*-
  3. import json
  4. from alipay.aop.api.constant.ParamConstants import *
  5. class ExproductconfResponse(object):
  6. def __init__(self):
  7. self._charge_inst = None
  8. self._chargeinst_name = None
  9. self._chargeoff_inst = None
  10. self._chargeoffinst_name = None
  11. self._city = None
  12. self._extend = None
  13. self._province = None
  14. self._status = None
  15. @property
  16. def charge_inst(self):
  17. return self._charge_inst
  18. @charge_inst.setter
  19. def charge_inst(self, value):
  20. self._charge_inst = value
  21. @property
  22. def chargeinst_name(self):
  23. return self._chargeinst_name
  24. @chargeinst_name.setter
  25. def chargeinst_name(self, value):
  26. self._chargeinst_name = value
  27. @property
  28. def chargeoff_inst(self):
  29. return self._chargeoff_inst
  30. @chargeoff_inst.setter
  31. def chargeoff_inst(self, value):
  32. self._chargeoff_inst = value
  33. @property
  34. def chargeoffinst_name(self):
  35. return self._chargeoffinst_name
  36. @chargeoffinst_name.setter
  37. def chargeoffinst_name(self, value):
  38. self._chargeoffinst_name = value
  39. @property
  40. def city(self):
  41. return self._city
  42. @city.setter
  43. def city(self, value):
  44. self._city = value
  45. @property
  46. def extend(self):
  47. return self._extend
  48. @extend.setter
  49. def extend(self, value):
  50. self._extend = value
  51. @property
  52. def province(self):
  53. return self._province
  54. @province.setter
  55. def province(self, value):
  56. self._province = value
  57. @property
  58. def status(self):
  59. return self._status
  60. @status.setter
  61. def status(self, value):
  62. self._status = value
  63. def to_alipay_dict(self):
  64. params = dict()
  65. if self.charge_inst:
  66. if hasattr(self.charge_inst, 'to_alipay_dict'):
  67. params['charge_inst'] = self.charge_inst.to_alipay_dict()
  68. else:
  69. params['charge_inst'] = self.charge_inst
  70. if self.chargeinst_name:
  71. if hasattr(self.chargeinst_name, 'to_alipay_dict'):
  72. params['chargeinst_name'] = self.chargeinst_name.to_alipay_dict()
  73. else:
  74. params['chargeinst_name'] = self.chargeinst_name
  75. if self.chargeoff_inst:
  76. if hasattr(self.chargeoff_inst, 'to_alipay_dict'):
  77. params['chargeoff_inst'] = self.chargeoff_inst.to_alipay_dict()
  78. else:
  79. params['chargeoff_inst'] = self.chargeoff_inst
  80. if self.chargeoffinst_name:
  81. if hasattr(self.chargeoffinst_name, 'to_alipay_dict'):
  82. params['chargeoffinst_name'] = self.chargeoffinst_name.to_alipay_dict()
  83. else:
  84. params['chargeoffinst_name'] = self.chargeoffinst_name
  85. if self.city:
  86. if hasattr(self.city, 'to_alipay_dict'):
  87. params['city'] = self.city.to_alipay_dict()
  88. else:
  89. params['city'] = self.city
  90. if self.extend:
  91. if hasattr(self.extend, 'to_alipay_dict'):
  92. params['extend'] = self.extend.to_alipay_dict()
  93. else:
  94. params['extend'] = self.extend
  95. if self.province:
  96. if hasattr(self.province, 'to_alipay_dict'):
  97. params['province'] = self.province.to_alipay_dict()
  98. else:
  99. params['province'] = self.province
  100. if self.status:
  101. if hasattr(self.status, 'to_alipay_dict'):
  102. params['status'] = self.status.to_alipay_dict()
  103. else:
  104. params['status'] = self.status
  105. return params
  106. @staticmethod
  107. def from_alipay_dict(d):
  108. if not d:
  109. return None
  110. o = ExproductconfResponse()
  111. if 'charge_inst' in d:
  112. o.charge_inst = d['charge_inst']
  113. if 'chargeinst_name' in d:
  114. o.chargeinst_name = d['chargeinst_name']
  115. if 'chargeoff_inst' in d:
  116. o.chargeoff_inst = d['chargeoff_inst']
  117. if 'chargeoffinst_name' in d:
  118. o.chargeoffinst_name = d['chargeoffinst_name']
  119. if 'city' in d:
  120. o.city = d['city']
  121. if 'extend' in d:
  122. o.extend = d['extend']
  123. if 'province' in d:
  124. o.province = d['province']
  125. if 'status' in d:
  126. o.status = d['status']
  127. return o