AlipaySocialBaseContentlibStandardvideoSendModel.py 8.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265
  1. #!/usr/bin/env python
  2. # -*- coding: utf-8 -*-
  3. import json
  4. from alipay.aop.api.constant.ParamConstants import *
  5. class AlipaySocialBaseContentlibStandardvideoSendModel(object):
  6. def __init__(self):
  7. self._action_type = None
  8. self._ext_info = None
  9. self._public_id = None
  10. self._source_author = None
  11. self._source_category = None
  12. self._source_cover = None
  13. self._source_id = None
  14. self._source_publish_date = None
  15. self._source_summary = None
  16. self._source_title = None
  17. self._video_id = None
  18. self._video_length = None
  19. self._video_publish_type = None
  20. self._video_size = None
  21. self._video_tags = None
  22. self._video_url = None
  23. @property
  24. def action_type(self):
  25. return self._action_type
  26. @action_type.setter
  27. def action_type(self, value):
  28. self._action_type = value
  29. @property
  30. def ext_info(self):
  31. return self._ext_info
  32. @ext_info.setter
  33. def ext_info(self, value):
  34. self._ext_info = value
  35. @property
  36. def public_id(self):
  37. return self._public_id
  38. @public_id.setter
  39. def public_id(self, value):
  40. self._public_id = value
  41. @property
  42. def source_author(self):
  43. return self._source_author
  44. @source_author.setter
  45. def source_author(self, value):
  46. self._source_author = value
  47. @property
  48. def source_category(self):
  49. return self._source_category
  50. @source_category.setter
  51. def source_category(self, value):
  52. self._source_category = value
  53. @property
  54. def source_cover(self):
  55. return self._source_cover
  56. @source_cover.setter
  57. def source_cover(self, value):
  58. self._source_cover = value
  59. @property
  60. def source_id(self):
  61. return self._source_id
  62. @source_id.setter
  63. def source_id(self, value):
  64. self._source_id = value
  65. @property
  66. def source_publish_date(self):
  67. return self._source_publish_date
  68. @source_publish_date.setter
  69. def source_publish_date(self, value):
  70. self._source_publish_date = value
  71. @property
  72. def source_summary(self):
  73. return self._source_summary
  74. @source_summary.setter
  75. def source_summary(self, value):
  76. self._source_summary = value
  77. @property
  78. def source_title(self):
  79. return self._source_title
  80. @source_title.setter
  81. def source_title(self, value):
  82. self._source_title = value
  83. @property
  84. def video_id(self):
  85. return self._video_id
  86. @video_id.setter
  87. def video_id(self, value):
  88. self._video_id = value
  89. @property
  90. def video_length(self):
  91. return self._video_length
  92. @video_length.setter
  93. def video_length(self, value):
  94. self._video_length = value
  95. @property
  96. def video_publish_type(self):
  97. return self._video_publish_type
  98. @video_publish_type.setter
  99. def video_publish_type(self, value):
  100. self._video_publish_type = value
  101. @property
  102. def video_size(self):
  103. return self._video_size
  104. @video_size.setter
  105. def video_size(self, value):
  106. self._video_size = value
  107. @property
  108. def video_tags(self):
  109. return self._video_tags
  110. @video_tags.setter
  111. def video_tags(self, value):
  112. self._video_tags = value
  113. @property
  114. def video_url(self):
  115. return self._video_url
  116. @video_url.setter
  117. def video_url(self, value):
  118. self._video_url = value
  119. def to_alipay_dict(self):
  120. params = dict()
  121. if self.action_type:
  122. if hasattr(self.action_type, 'to_alipay_dict'):
  123. params['action_type'] = self.action_type.to_alipay_dict()
  124. else:
  125. params['action_type'] = self.action_type
  126. if self.ext_info:
  127. if hasattr(self.ext_info, 'to_alipay_dict'):
  128. params['ext_info'] = self.ext_info.to_alipay_dict()
  129. else:
  130. params['ext_info'] = self.ext_info
  131. if self.public_id:
  132. if hasattr(self.public_id, 'to_alipay_dict'):
  133. params['public_id'] = self.public_id.to_alipay_dict()
  134. else:
  135. params['public_id'] = self.public_id
  136. if self.source_author:
  137. if hasattr(self.source_author, 'to_alipay_dict'):
  138. params['source_author'] = self.source_author.to_alipay_dict()
  139. else:
  140. params['source_author'] = self.source_author
  141. if self.source_category:
  142. if hasattr(self.source_category, 'to_alipay_dict'):
  143. params['source_category'] = self.source_category.to_alipay_dict()
  144. else:
  145. params['source_category'] = self.source_category
  146. if self.source_cover:
  147. if hasattr(self.source_cover, 'to_alipay_dict'):
  148. params['source_cover'] = self.source_cover.to_alipay_dict()
  149. else:
  150. params['source_cover'] = self.source_cover
  151. if self.source_id:
  152. if hasattr(self.source_id, 'to_alipay_dict'):
  153. params['source_id'] = self.source_id.to_alipay_dict()
  154. else:
  155. params['source_id'] = self.source_id
  156. if self.source_publish_date:
  157. if hasattr(self.source_publish_date, 'to_alipay_dict'):
  158. params['source_publish_date'] = self.source_publish_date.to_alipay_dict()
  159. else:
  160. params['source_publish_date'] = self.source_publish_date
  161. if self.source_summary:
  162. if hasattr(self.source_summary, 'to_alipay_dict'):
  163. params['source_summary'] = self.source_summary.to_alipay_dict()
  164. else:
  165. params['source_summary'] = self.source_summary
  166. if self.source_title:
  167. if hasattr(self.source_title, 'to_alipay_dict'):
  168. params['source_title'] = self.source_title.to_alipay_dict()
  169. else:
  170. params['source_title'] = self.source_title
  171. if self.video_id:
  172. if hasattr(self.video_id, 'to_alipay_dict'):
  173. params['video_id'] = self.video_id.to_alipay_dict()
  174. else:
  175. params['video_id'] = self.video_id
  176. if self.video_length:
  177. if hasattr(self.video_length, 'to_alipay_dict'):
  178. params['video_length'] = self.video_length.to_alipay_dict()
  179. else:
  180. params['video_length'] = self.video_length
  181. if self.video_publish_type:
  182. if hasattr(self.video_publish_type, 'to_alipay_dict'):
  183. params['video_publish_type'] = self.video_publish_type.to_alipay_dict()
  184. else:
  185. params['video_publish_type'] = self.video_publish_type
  186. if self.video_size:
  187. if hasattr(self.video_size, 'to_alipay_dict'):
  188. params['video_size'] = self.video_size.to_alipay_dict()
  189. else:
  190. params['video_size'] = self.video_size
  191. if self.video_tags:
  192. if hasattr(self.video_tags, 'to_alipay_dict'):
  193. params['video_tags'] = self.video_tags.to_alipay_dict()
  194. else:
  195. params['video_tags'] = self.video_tags
  196. if self.video_url:
  197. if hasattr(self.video_url, 'to_alipay_dict'):
  198. params['video_url'] = self.video_url.to_alipay_dict()
  199. else:
  200. params['video_url'] = self.video_url
  201. return params
  202. @staticmethod
  203. def from_alipay_dict(d):
  204. if not d:
  205. return None
  206. o = AlipaySocialBaseContentlibStandardvideoSendModel()
  207. if 'action_type' in d:
  208. o.action_type = d['action_type']
  209. if 'ext_info' in d:
  210. o.ext_info = d['ext_info']
  211. if 'public_id' in d:
  212. o.public_id = d['public_id']
  213. if 'source_author' in d:
  214. o.source_author = d['source_author']
  215. if 'source_category' in d:
  216. o.source_category = d['source_category']
  217. if 'source_cover' in d:
  218. o.source_cover = d['source_cover']
  219. if 'source_id' in d:
  220. o.source_id = d['source_id']
  221. if 'source_publish_date' in d:
  222. o.source_publish_date = d['source_publish_date']
  223. if 'source_summary' in d:
  224. o.source_summary = d['source_summary']
  225. if 'source_title' in d:
  226. o.source_title = d['source_title']
  227. if 'video_id' in d:
  228. o.video_id = d['video_id']
  229. if 'video_length' in d:
  230. o.video_length = d['video_length']
  231. if 'video_publish_type' in d:
  232. o.video_publish_type = d['video_publish_type']
  233. if 'video_size' in d:
  234. o.video_size = d['video_size']
  235. if 'video_tags' in d:
  236. o.video_tags = d['video_tags']
  237. if 'video_url' in d:
  238. o.video_url = d['video_url']
  239. return o