osuny_api 1.0.0 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (287) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +33 -23
  3. data/README.md +513 -58
  4. data/Rakefile +8 -7
  5. data/docs/CategoriesIdBody2.md +1 -1
  6. data/docs/CategoriesIdBody3.md +7 -0
  7. data/docs/CategoriesIdBody4.md +7 -0
  8. data/docs/CategoriesUpsertBody2.md +1 -1
  9. data/docs/CategoriesUpsertBody3.md +7 -0
  10. data/docs/CategoriesUpsertBody4.md +7 -0
  11. data/docs/CommunicationBlockAgendaData.md +3 -0
  12. data/docs/CommunicationBlockCallToActionData.md +1 -1
  13. data/docs/CommunicationBlockChapterData.md +1 -1
  14. data/docs/CommunicationBlockChapterDataImage.md +9 -0
  15. data/docs/CommunicationBlockExhibitions.md +14 -0
  16. data/docs/CommunicationBlockExhibitionsData.md +20 -0
  17. data/docs/CommunicationBlockFeaturesDataElements.md +1 -1
  18. data/docs/CommunicationBlockFilesDataElements.md +2 -2
  19. data/docs/CommunicationBlockGalleryDataElements.md +1 -1
  20. data/docs/CommunicationBlockImageData.md +1 -1
  21. data/docs/CommunicationBlockJobs.md +14 -0
  22. data/docs/CommunicationBlockJobsData.md +18 -0
  23. data/docs/CommunicationBlockKeyFiguresDataElements.md +1 -1
  24. data/docs/CommunicationBlockLinksData.md +2 -0
  25. data/docs/CommunicationBlockLinksDataElements.md +1 -2
  26. data/docs/CommunicationBlockLocationsData.md +1 -1
  27. data/docs/CommunicationBlockOrganizationsData.md +2 -0
  28. data/docs/CommunicationBlockOrganizationsDataElements.md +2 -1
  29. data/docs/CommunicationBlockPagesData.md +2 -1
  30. data/docs/CommunicationBlockPapersData.md +1 -1
  31. data/docs/CommunicationBlockPostsData.md +1 -1
  32. data/docs/CommunicationBlockProgramsData.md +1 -1
  33. data/docs/CommunicationBlockProgramsDataElements.md +7 -0
  34. data/docs/CommunicationBlockProjectsData.md +1 -1
  35. data/docs/CommunicationBlockSoundData.md +1 -1
  36. data/docs/CommunicationBlockTestimonialsData.md +1 -0
  37. data/docs/CommunicationBlockTestimonialsDataElements.md +1 -1
  38. data/docs/CommunicationMedia.md +17 -0
  39. data/docs/CommunicationMediaLocalization.md +13 -0
  40. data/docs/CommunicationMediaOriginalBlob.md +10 -0
  41. data/docs/CommunicationMediasBody.md +8 -0
  42. data/docs/CommunicationWebsite.md +1 -0
  43. data/docs/CommunicationWebsiteAgendaCategoryApi.md +8 -3
  44. data/docs/CommunicationWebsiteAgendaCategoryLocalization.md +6 -0
  45. data/docs/CommunicationWebsiteAgendaEventApi.md +8 -3
  46. data/docs/CommunicationWebsiteAgendaEventLocalization.md +1 -0
  47. data/docs/CommunicationWebsiteApi.md +11 -3
  48. data/docs/CommunicationWebsiteMediaApi.md +61 -0
  49. data/docs/CommunicationWebsitePageApi.md +8 -3
  50. data/docs/CommunicationWebsitePageCategoryApi.md +8 -3
  51. data/docs/CommunicationWebsitePageCategoryLocalization.md +6 -0
  52. data/docs/CommunicationWebsitePageLocalization.md +2 -0
  53. data/docs/CommunicationWebsitePermalink.md +8 -0
  54. data/docs/CommunicationWebsitePortfolioCategory.md +15 -0
  55. data/docs/CommunicationWebsitePortfolioCategoryApi.md +334 -0
  56. data/docs/CommunicationWebsitePortfolioCategoryLocalization.md +23 -0
  57. data/docs/CommunicationWebsitePortfolioProject.md +15 -0
  58. data/docs/CommunicationWebsitePortfolioProjectApi.md +334 -0
  59. data/docs/CommunicationWebsitePortfolioProjectLocalization.md +23 -0
  60. data/docs/CommunicationWebsitePost.md +1 -0
  61. data/docs/CommunicationWebsitePostApi.md +8 -3
  62. data/docs/CommunicationWebsitePostCategory.md +14 -0
  63. data/docs/CommunicationWebsitePostCategoryApi.md +334 -0
  64. data/docs/CommunicationWebsitePostCategoryLocalization.md +23 -0
  65. data/docs/CommunicationWebsitePostLocalization.md +1 -1
  66. data/docs/OneOfcommunicationWebsitePortfolioCategoryLocalizationBlocksItems.md +6 -0
  67. data/docs/OneOfcommunicationWebsitePortfolioProjectLocalizationBlocksItems.md +6 -0
  68. data/docs/OneOfcommunicationWebsitePostCategoryLocalizationBlocksItems.md +6 -0
  69. data/docs/PortfolioCategoriesBody.md +7 -0
  70. data/docs/PortfolioProjectsBody.md +7 -0
  71. data/docs/PostsCategoriesBody.md +7 -0
  72. data/docs/ProjectsIdBody.md +7 -0
  73. data/docs/ProjectsUpsertBody.md +7 -0
  74. data/docs/UniversityOrganization.md +0 -1
  75. data/docs/UniversityOrganizationApi.md +11 -3
  76. data/docs/UniversityOrganizationCategoryApi.md +15 -7
  77. data/docs/UniversityOrganizationCategoryLocalization.md +6 -0
  78. data/docs/UniversityOrganizationLocalization.md +2 -0
  79. data/generate.sh +0 -0
  80. data/lib/osuny_api/api/communication_website_agenda_category_api.rb +7 -1
  81. data/lib/osuny_api/api/communication_website_agenda_event_api.rb +7 -1
  82. data/lib/osuny_api/api/communication_website_api.rb +7 -1
  83. data/lib/osuny_api/api/communication_website_media_api.rb +76 -0
  84. data/lib/osuny_api/api/communication_website_page_api.rb +7 -1
  85. data/lib/osuny_api/api/communication_website_page_category_api.rb +7 -1
  86. data/lib/osuny_api/api/communication_website_portfolio_category_api.rb +380 -0
  87. data/lib/osuny_api/api/communication_website_portfolio_project_api.rb +380 -0
  88. data/lib/osuny_api/api/communication_website_post_api.rb +7 -1
  89. data/lib/osuny_api/api/communication_website_post_category_api.rb +380 -0
  90. data/lib/osuny_api/api/university_organization_api.rb +7 -1
  91. data/lib/osuny_api/api/university_organization_category_api.rb +11 -5
  92. data/lib/osuny_api/api_client.rb +1 -1
  93. data/lib/osuny_api/api_error.rb +1 -1
  94. data/lib/osuny_api/configuration.rb +1 -1
  95. data/lib/osuny_api/models/agenda_categories_body.rb +1 -1
  96. data/lib/osuny_api/models/agenda_events_body.rb +1 -1
  97. data/lib/osuny_api/models/categories_id_body.rb +1 -1
  98. data/lib/osuny_api/models/categories_id_body_1.rb +1 -1
  99. data/lib/osuny_api/models/categories_id_body_2.rb +1 -1
  100. data/lib/osuny_api/models/categories_id_body_3.rb +211 -0
  101. data/lib/osuny_api/models/categories_id_body_4.rb +211 -0
  102. data/lib/osuny_api/models/categories_upsert_body.rb +1 -1
  103. data/lib/osuny_api/models/categories_upsert_body_1.rb +1 -1
  104. data/lib/osuny_api/models/categories_upsert_body_2.rb +1 -1
  105. data/lib/osuny_api/models/categories_upsert_body_3.rb +213 -0
  106. data/lib/osuny_api/models/categories_upsert_body_4.rb +213 -0
  107. data/lib/osuny_api/models/communication_block_agenda.rb +1 -1
  108. data/lib/osuny_api/models/communication_block_agenda_data.rb +31 -4
  109. data/lib/osuny_api/models/communication_block_agenda_data_elements.rb +1 -1
  110. data/lib/osuny_api/models/communication_block_call_to_action.rb +1 -1
  111. data/lib/osuny_api/models/communication_block_call_to_action_data.rb +1 -1
  112. data/lib/osuny_api/models/communication_block_call_to_action_data_elements.rb +1 -1
  113. data/lib/osuny_api/models/communication_block_categories.rb +1 -1
  114. data/lib/osuny_api/models/communication_block_categories_data.rb +3 -3
  115. data/lib/osuny_api/models/communication_block_chapter.rb +1 -1
  116. data/lib/osuny_api/models/communication_block_chapter_data.rb +1 -1
  117. data/lib/osuny_api/models/communication_block_chapter_data_image.rb +227 -0
  118. data/lib/osuny_api/models/communication_block_contact.rb +1 -1
  119. data/lib/osuny_api/models/communication_block_contact_data.rb +1 -1
  120. data/lib/osuny_api/models/communication_block_contact_data_elements.rb +1 -1
  121. data/lib/osuny_api/models/communication_block_contact_data_time_slot_morning.rb +1 -1
  122. data/lib/osuny_api/models/communication_block_datatable.rb +1 -1
  123. data/lib/osuny_api/models/communication_block_datatable_data.rb +1 -1
  124. data/lib/osuny_api/models/communication_block_datatable_data_elements.rb +1 -1
  125. data/lib/osuny_api/models/communication_block_definitions.rb +1 -1
  126. data/lib/osuny_api/models/communication_block_definitions_data.rb +1 -1
  127. data/lib/osuny_api/models/communication_block_definitions_data_elements.rb +1 -1
  128. data/lib/osuny_api/models/communication_block_embed.rb +1 -1
  129. data/lib/osuny_api/models/communication_block_embed_data.rb +1 -1
  130. data/lib/osuny_api/models/communication_block_exhibitions.rb +312 -0
  131. data/lib/osuny_api/models/communication_block_exhibitions_data.rb +384 -0
  132. data/lib/osuny_api/models/communication_block_features.rb +1 -1
  133. data/lib/osuny_api/models/communication_block_features_data.rb +1 -1
  134. data/lib/osuny_api/models/communication_block_features_data_elements.rb +1 -1
  135. data/lib/osuny_api/models/communication_block_files.rb +1 -1
  136. data/lib/osuny_api/models/communication_block_files_data.rb +1 -1
  137. data/lib/osuny_api/models/communication_block_files_data_elements.rb +1 -1
  138. data/lib/osuny_api/models/communication_block_gallery.rb +1 -1
  139. data/lib/osuny_api/models/communication_block_gallery_data.rb +1 -1
  140. data/lib/osuny_api/models/communication_block_gallery_data_elements.rb +1 -1
  141. data/lib/osuny_api/models/communication_block_image.rb +1 -1
  142. data/lib/osuny_api/models/communication_block_image_data.rb +1 -1
  143. data/lib/osuny_api/models/communication_block_jobs.rb +312 -0
  144. data/lib/osuny_api/models/communication_block_jobs_data.rb +354 -0
  145. data/lib/osuny_api/models/communication_block_key_figures.rb +1 -1
  146. data/lib/osuny_api/models/communication_block_key_figures_data.rb +1 -1
  147. data/lib/osuny_api/models/communication_block_key_figures_data_elements.rb +1 -1
  148. data/lib/osuny_api/models/communication_block_license.rb +1 -1
  149. data/lib/osuny_api/models/communication_block_license_data.rb +1 -1
  150. data/lib/osuny_api/models/communication_block_links.rb +1 -1
  151. data/lib/osuny_api/models/communication_block_links_data.rb +54 -2
  152. data/lib/osuny_api/models/communication_block_links_data_elements.rb +2 -11
  153. data/lib/osuny_api/models/communication_block_locations.rb +1 -1
  154. data/lib/osuny_api/models/communication_block_locations_data.rb +1 -1
  155. data/lib/osuny_api/models/communication_block_organizations.rb +1 -1
  156. data/lib/osuny_api/models/communication_block_organizations_data.rb +22 -4
  157. data/lib/osuny_api/models/communication_block_organizations_data_elements.rb +14 -5
  158. data/lib/osuny_api/models/communication_block_pages.rb +1 -1
  159. data/lib/osuny_api/models/communication_block_pages_data.rb +11 -2
  160. data/lib/osuny_api/models/communication_block_papers.rb +1 -1
  161. data/lib/osuny_api/models/communication_block_papers_data.rb +1 -1
  162. data/lib/osuny_api/models/communication_block_persons.rb +1 -1
  163. data/lib/osuny_api/models/communication_block_persons_data.rb +1 -1
  164. data/lib/osuny_api/models/communication_block_persons_data_elements.rb +1 -1
  165. data/lib/osuny_api/models/communication_block_posts.rb +1 -1
  166. data/lib/osuny_api/models/communication_block_posts_data.rb +1 -1
  167. data/lib/osuny_api/models/communication_block_programs.rb +1 -1
  168. data/lib/osuny_api/models/communication_block_programs_data.rb +1 -1
  169. data/lib/osuny_api/models/communication_block_programs_data_elements.rb +206 -0
  170. data/lib/osuny_api/models/communication_block_projects.rb +1 -1
  171. data/lib/osuny_api/models/communication_block_projects_data.rb +1 -1
  172. data/lib/osuny_api/models/communication_block_sound.rb +1 -1
  173. data/lib/osuny_api/models/communication_block_sound_data.rb +1 -1
  174. data/lib/osuny_api/models/communication_block_testimonials.rb +1 -1
  175. data/lib/osuny_api/models/communication_block_testimonials_data.rb +45 -2
  176. data/lib/osuny_api/models/communication_block_testimonials_data_elements.rb +1 -1
  177. data/lib/osuny_api/models/communication_block_timeline.rb +1 -1
  178. data/lib/osuny_api/models/communication_block_timeline_data.rb +1 -1
  179. data/lib/osuny_api/models/communication_block_timeline_data_elements.rb +1 -1
  180. data/lib/osuny_api/models/communication_block_title.rb +1 -1
  181. data/lib/osuny_api/models/communication_block_title_data.rb +1 -1
  182. data/lib/osuny_api/models/communication_block_video.rb +1 -1
  183. data/lib/osuny_api/models/communication_block_video_data.rb +1 -1
  184. data/lib/osuny_api/models/communication_block_volumes.rb +1 -1
  185. data/lib/osuny_api/models/communication_media.rb +339 -0
  186. data/lib/osuny_api/models/communication_media_localization.rb +265 -0
  187. data/lib/osuny_api/models/communication_media_original_blob.rb +237 -0
  188. data/lib/osuny_api/models/communication_medias_body.rb +215 -0
  189. data/lib/osuny_api/models/communication_website.rb +46 -2
  190. data/lib/osuny_api/models/communication_website_agenda_category.rb +1 -1
  191. data/lib/osuny_api/models/communication_website_agenda_category_localization.rb +62 -2
  192. data/lib/osuny_api/models/communication_website_agenda_category_localization_featured_image.rb +1 -1
  193. data/lib/osuny_api/models/communication_website_agenda_event.rb +1 -1
  194. data/lib/osuny_api/models/communication_website_agenda_event_localization.rb +13 -2
  195. data/lib/osuny_api/models/communication_website_agenda_event_localization_add_to_calendar_urls.rb +1 -1
  196. data/lib/osuny_api/models/communication_website_agenda_event_time_slot.rb +1 -1
  197. data/lib/osuny_api/models/communication_website_agenda_event_time_slot_localization.rb +1 -1
  198. data/lib/osuny_api/models/communication_website_deuxfleurs.rb +1 -1
  199. data/lib/osuny_api/models/communication_website_features.rb +1 -1
  200. data/lib/osuny_api/models/communication_website_git.rb +1 -1
  201. data/lib/osuny_api/models/communication_website_localization.rb +1 -1
  202. data/lib/osuny_api/models/communication_website_page.rb +1 -1
  203. data/lib/osuny_api/models/communication_website_page_category.rb +1 -1
  204. data/lib/osuny_api/models/communication_website_page_category_localization.rb +62 -2
  205. data/lib/osuny_api/models/communication_website_page_localization.rb +23 -2
  206. data/lib/osuny_api/models/communication_website_permalink.rb +215 -0
  207. data/lib/osuny_api/models/communication_website_portfolio_category.rb +284 -0
  208. data/lib/osuny_api/models/communication_website_portfolio_category_localization.rb +362 -0
  209. data/lib/osuny_api/models/communication_website_portfolio_project.rb +285 -0
  210. data/lib/osuny_api/models/communication_website_portfolio_project_localization.rb +362 -0
  211. data/lib/osuny_api/models/communication_website_post.rb +13 -2
  212. data/lib/osuny_api/models/communication_website_post_category.rb +274 -0
  213. data/lib/osuny_api/models/communication_website_post_category_localization.rb +362 -0
  214. data/lib/osuny_api/models/communication_website_post_localization.rb +10 -9
  215. data/lib/osuny_api/models/communication_website_showcase.rb +1 -1
  216. data/lib/osuny_api/models/communication_website_showcase_tags.rb +1 -1
  217. data/lib/osuny_api/models/events_id_body.rb +1 -1
  218. data/lib/osuny_api/models/events_upsert_body.rb +1 -1
  219. data/lib/osuny_api/models/one_ofcommunication_website_agenda_category_localization_blocks_items.rb +1 -1
  220. data/lib/osuny_api/models/one_ofcommunication_website_agenda_event_localization_blocks_items.rb +1 -1
  221. data/lib/osuny_api/models/one_ofcommunication_website_page_category_localization_blocks_items.rb +1 -1
  222. data/lib/osuny_api/models/one_ofcommunication_website_page_localization_blocks_items.rb +1 -1
  223. data/lib/osuny_api/models/one_ofcommunication_website_portfolio_category_localization_blocks_items.rb +197 -0
  224. data/lib/osuny_api/models/one_ofcommunication_website_portfolio_project_localization_blocks_items.rb +197 -0
  225. data/lib/osuny_api/models/one_ofcommunication_website_post_category_localization_blocks_items.rb +197 -0
  226. data/lib/osuny_api/models/one_ofcommunication_website_post_localization_blocks_items.rb +1 -1
  227. data/lib/osuny_api/models/one_ofuniversity_organization_category_localization_blocks_items.rb +1 -1
  228. data/lib/osuny_api/models/one_ofuniversity_organization_localization_blocks_items.rb +1 -1
  229. data/lib/osuny_api/models/organizations_categories_body.rb +1 -1
  230. data/lib/osuny_api/models/organizations_id_body.rb +1 -1
  231. data/lib/osuny_api/models/organizations_upsert_body.rb +1 -1
  232. data/lib/osuny_api/models/pages_categories_body.rb +1 -1
  233. data/lib/osuny_api/models/pages_id_body.rb +1 -1
  234. data/lib/osuny_api/models/pages_upsert_body.rb +1 -1
  235. data/lib/osuny_api/models/portfolio_categories_body.rb +211 -0
  236. data/lib/osuny_api/models/portfolio_projects_body.rb +211 -0
  237. data/lib/osuny_api/models/posts_categories_body.rb +211 -0
  238. data/lib/osuny_api/models/posts_id_body.rb +1 -1
  239. data/lib/osuny_api/models/posts_upsert_body.rb +1 -1
  240. data/lib/osuny_api/models/projects_id_body.rb +211 -0
  241. data/lib/osuny_api/models/projects_upsert_body.rb +213 -0
  242. data/lib/osuny_api/models/university_organization.rb +4 -13
  243. data/lib/osuny_api/models/university_organization_category.rb +1 -1
  244. data/lib/osuny_api/models/university_organization_category_localization.rb +62 -2
  245. data/lib/osuny_api/models/university_organization_localization.rb +21 -2
  246. data/lib/osuny_api/models/university_organizations_body.rb +1 -1
  247. data/lib/osuny_api/models/website_id_pages_body.rb +1 -1
  248. data/lib/osuny_api/models/website_id_posts_body.rb +1 -1
  249. data/lib/osuny_api/version.rb +2 -2
  250. data/lib/osuny_api.rb +34 -3
  251. data/osuny_api.gemspec +2 -1
  252. data/spec/api/communication_website_media_api_spec.rb +46 -0
  253. data/spec/api/communication_website_portfolio_category_api_spec.rb +108 -0
  254. data/spec/api/communication_website_portfolio_project_api_spec.rb +108 -0
  255. data/spec/api/communication_website_post_category_api_spec.rb +108 -0
  256. data/spec/models/categories_id_body_3_spec.rb +40 -0
  257. data/spec/models/categories_id_body_4_spec.rb +40 -0
  258. data/spec/models/categories_upsert_body_3_spec.rb +40 -0
  259. data/spec/models/categories_upsert_body_4_spec.rb +40 -0
  260. data/spec/models/communication_block_chapter_data_image_spec.rb +52 -0
  261. data/spec/models/communication_block_exhibitions_data_spec.rb +130 -0
  262. data/spec/models/communication_block_exhibitions_spec.rb +86 -0
  263. data/spec/models/communication_block_jobs_data_spec.rb +114 -0
  264. data/spec/models/communication_block_jobs_spec.rb +86 -0
  265. data/spec/models/communication_block_programs_data_elements_spec.rb +40 -0
  266. data/spec/models/communication_media_localization_spec.rb +76 -0
  267. data/spec/models/communication_media_original_blob_spec.rb +58 -0
  268. data/spec/models/communication_media_spec.rb +104 -0
  269. data/spec/models/communication_medias_body_spec.rb +46 -0
  270. data/spec/models/communication_website_permalink_spec.rb +46 -0
  271. data/spec/models/communication_website_portfolio_category_localization_spec.rb +136 -0
  272. data/spec/models/communication_website_portfolio_category_spec.rb +88 -0
  273. data/spec/models/communication_website_portfolio_project_localization_spec.rb +136 -0
  274. data/spec/models/communication_website_portfolio_project_spec.rb +88 -0
  275. data/spec/models/communication_website_post_category_localization_spec.rb +136 -0
  276. data/spec/models/communication_website_post_category_spec.rb +82 -0
  277. data/spec/models/one_ofcommunication_website_portfolio_category_localization_blocks_items_spec.rb +34 -0
  278. data/spec/models/one_ofcommunication_website_portfolio_project_localization_blocks_items_spec.rb +34 -0
  279. data/spec/models/one_ofcommunication_website_post_category_localization_blocks_items_spec.rb +34 -0
  280. data/spec/models/portfolio_categories_body_spec.rb +40 -0
  281. data/spec/models/portfolio_projects_body_spec.rb +40 -0
  282. data/spec/models/posts_categories_body_spec.rb +40 -0
  283. data/spec/models/projects_id_body_spec.rb +40 -0
  284. data/spec/models/projects_upsert_body_spec.rb +40 -0
  285. metadata +266 -116
  286. data/pkg/osuny_api-0.2.6.gem +0 -0
  287. data/pkg/osuny_api-1.0.0.gem +0 -0
@@ -0,0 +1,215 @@
1
+ =begin
2
+ #Osuny
3
+
4
+ #No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
5
+
6
+ OpenAPI spec version: v1
7
+
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+ Swagger Codegen version: 3.0.77
10
+ =end
11
+
12
+ require 'date'
13
+
14
+ module OsunyApi
15
+ class CommunicationWebsitePermalink
16
+ attr_accessor :id
17
+
18
+ attr_accessor :path
19
+
20
+ # Attribute mapping from ruby-style variable name to JSON key.
21
+ def self.attribute_map
22
+ {
23
+ :'id' => :'id',
24
+ :'path' => :'path'
25
+ }
26
+ end
27
+
28
+ # Attribute type mapping.
29
+ def self.openapi_types
30
+ {
31
+ :'id' => :'Object',
32
+ :'path' => :'Object'
33
+ }
34
+ end
35
+
36
+ # List of attributes with nullable: true
37
+ def self.openapi_nullable
38
+ Set.new([
39
+ ])
40
+ end
41
+
42
+ # Initializes the object
43
+ # @param [Hash] attributes Model attributes in the form of hash
44
+ def initialize(attributes = {})
45
+ if (!attributes.is_a?(Hash))
46
+ fail ArgumentError, "The input argument (attributes) must be a hash in `OsunyApi::CommunicationWebsitePermalink` initialize method"
47
+ end
48
+
49
+ # check to see if the attribute exists and convert string to symbol for hash key
50
+ attributes = attributes.each_with_object({}) { |(k, v), h|
51
+ if (!self.class.attribute_map.key?(k.to_sym))
52
+ fail ArgumentError, "`#{k}` is not a valid attribute in `OsunyApi::CommunicationWebsitePermalink`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
53
+ end
54
+ h[k.to_sym] = v
55
+ }
56
+
57
+ if attributes.key?(:'id')
58
+ self.id = attributes[:'id']
59
+ end
60
+
61
+ if attributes.key?(:'path')
62
+ self.path = attributes[:'path']
63
+ end
64
+ end
65
+
66
+ # Show invalid properties with the reasons. Usually used together with valid?
67
+ # @return Array for valid properties with the reasons
68
+ def list_invalid_properties
69
+ invalid_properties = Array.new
70
+ invalid_properties
71
+ end
72
+
73
+ # Check to see if the all the properties in the model are valid
74
+ # @return true if the model is valid
75
+ def valid?
76
+ true
77
+ end
78
+
79
+ # Checks equality by comparing each attribute.
80
+ # @param [Object] Object to be compared
81
+ def ==(o)
82
+ return true if self.equal?(o)
83
+ self.class == o.class &&
84
+ id == o.id &&
85
+ path == o.path
86
+ end
87
+
88
+ # @see the `==` method
89
+ # @param [Object] Object to be compared
90
+ def eql?(o)
91
+ self == o
92
+ end
93
+
94
+ # Calculates hash code according to all attributes.
95
+ # @return [Integer] Hash code
96
+ def hash
97
+ [id, path].hash
98
+ end
99
+
100
+ # Builds the object from hash
101
+ # @param [Hash] attributes Model attributes in the form of hash
102
+ # @return [Object] Returns the model itself
103
+ def self.build_from_hash(attributes)
104
+ new.build_from_hash(attributes)
105
+ end
106
+
107
+ # Builds the object from hash
108
+ # @param [Hash] attributes Model attributes in the form of hash
109
+ # @return [Object] Returns the model itself
110
+ def build_from_hash(attributes)
111
+ return nil unless attributes.is_a?(Hash)
112
+ self.class.openapi_types.each_pair do |key, type|
113
+ if type =~ /\AArray<(.*)>/i
114
+ # check to ensure the input is an array given that the attribute
115
+ # is documented as an array but the input is not
116
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
117
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
118
+ end
119
+ elsif !attributes[self.class.attribute_map[key]].nil?
120
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
121
+ elsif attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
122
+ self.send("#{key}=", nil)
123
+ end
124
+ end
125
+
126
+ self
127
+ end
128
+
129
+ # Deserializes the data based on type
130
+ # @param string type Data type
131
+ # @param string value Value to be deserialized
132
+ # @return [Object] Deserialized data
133
+ def _deserialize(type, value)
134
+ case type.to_sym
135
+ when :DateTime
136
+ DateTime.parse(value)
137
+ when :Date
138
+ Date.parse(value)
139
+ when :String
140
+ value.to_s
141
+ when :Integer
142
+ value.to_i
143
+ when :Float
144
+ value.to_f
145
+ when :Boolean
146
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
147
+ true
148
+ else
149
+ false
150
+ end
151
+ when :Object
152
+ # generic object (usually a Hash), return directly
153
+ value
154
+ when /\AArray<(?<inner_type>.+)>\z/
155
+ inner_type = Regexp.last_match[:inner_type]
156
+ value.map { |v| _deserialize(inner_type, v) }
157
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
158
+ k_type = Regexp.last_match[:k_type]
159
+ v_type = Regexp.last_match[:v_type]
160
+ {}.tap do |hash|
161
+ value.each do |k, v|
162
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
163
+ end
164
+ end
165
+ else # model
166
+ OsunyApi.const_get(type).build_from_hash(value)
167
+ end
168
+ end
169
+
170
+ # Returns the string representation of the object
171
+ # @return [String] String presentation of the object
172
+ def to_s
173
+ to_hash.to_s
174
+ end
175
+
176
+ # to_body is an alias to to_hash (backward compatibility)
177
+ # @return [Hash] Returns the object in the form of hash
178
+ def to_body
179
+ to_hash
180
+ end
181
+
182
+ # Returns the object in the form of hash
183
+ # @return [Hash] Returns the object in the form of hash
184
+ def to_hash
185
+ hash = {}
186
+ self.class.attribute_map.each_pair do |attr, param|
187
+ value = self.send(attr)
188
+ if value.nil?
189
+ is_nullable = self.class.openapi_nullable.include?(attr)
190
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
191
+ end
192
+
193
+ hash[param] = _to_hash(value)
194
+ end
195
+ hash
196
+ end
197
+
198
+ # Outputs non-array value in the form of hash
199
+ # For object, use to_hash. Otherwise, just return the value
200
+ # @param [Object] value Any valid value
201
+ # @return [Hash] Returns the value in the form of hash
202
+ def _to_hash(value)
203
+ if value.is_a?(Array)
204
+ value.compact.map { |v| _to_hash(v) }
205
+ elsif value.is_a?(Hash)
206
+ {}.tap do |hash|
207
+ value.each { |k, v| hash[k] = _to_hash(v) }
208
+ end
209
+ elsif value.respond_to? :to_hash
210
+ value.to_hash
211
+ else
212
+ value
213
+ end
214
+ end end
215
+ end
@@ -0,0 +1,284 @@
1
+ =begin
2
+ #Osuny
3
+
4
+ #No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
5
+
6
+ OpenAPI spec version: v1
7
+
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+ Swagger Codegen version: 3.0.77
10
+ =end
11
+
12
+ require 'date'
13
+
14
+ module OsunyApi
15
+ class CommunicationWebsitePortfolioCategory
16
+ attr_accessor :id
17
+
18
+ attr_accessor :migration_identifier
19
+
20
+ attr_accessor :parent_id
21
+
22
+ attr_accessor :position
23
+
24
+ attr_accessor :is_taxonomy
25
+
26
+ attr_accessor :bodyclass
27
+
28
+ # Localizations of the category. The key is the language's ISO 639-1 code.
29
+ attr_accessor :localizations
30
+
31
+ attr_accessor :created_at
32
+
33
+ attr_accessor :updated_at
34
+
35
+ # Attribute mapping from ruby-style variable name to JSON key.
36
+ def self.attribute_map
37
+ {
38
+ :'id' => :'id',
39
+ :'migration_identifier' => :'migration_identifier',
40
+ :'parent_id' => :'parent_id',
41
+ :'position' => :'position',
42
+ :'is_taxonomy' => :'is_taxonomy',
43
+ :'bodyclass' => :'bodyclass',
44
+ :'localizations' => :'localizations',
45
+ :'created_at' => :'created_at',
46
+ :'updated_at' => :'updated_at'
47
+ }
48
+ end
49
+
50
+ # Attribute type mapping.
51
+ def self.openapi_types
52
+ {
53
+ :'id' => :'Object',
54
+ :'migration_identifier' => :'Object',
55
+ :'parent_id' => :'Object',
56
+ :'position' => :'Object',
57
+ :'is_taxonomy' => :'Object',
58
+ :'bodyclass' => :'Object',
59
+ :'localizations' => :'Object',
60
+ :'created_at' => :'Object',
61
+ :'updated_at' => :'Object'
62
+ }
63
+ end
64
+
65
+ # List of attributes with nullable: true
66
+ def self.openapi_nullable
67
+ Set.new([
68
+ :'migration_identifier',
69
+ :'parent_id',
70
+ :'bodyclass',
71
+ ])
72
+ end
73
+
74
+ # Initializes the object
75
+ # @param [Hash] attributes Model attributes in the form of hash
76
+ def initialize(attributes = {})
77
+ if (!attributes.is_a?(Hash))
78
+ fail ArgumentError, "The input argument (attributes) must be a hash in `OsunyApi::CommunicationWebsitePortfolioCategory` initialize method"
79
+ end
80
+
81
+ # check to see if the attribute exists and convert string to symbol for hash key
82
+ attributes = attributes.each_with_object({}) { |(k, v), h|
83
+ if (!self.class.attribute_map.key?(k.to_sym))
84
+ fail ArgumentError, "`#{k}` is not a valid attribute in `OsunyApi::CommunicationWebsitePortfolioCategory`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
85
+ end
86
+ h[k.to_sym] = v
87
+ }
88
+
89
+ if attributes.key?(:'id')
90
+ self.id = attributes[:'id']
91
+ end
92
+
93
+ if attributes.key?(:'migration_identifier')
94
+ self.migration_identifier = attributes[:'migration_identifier']
95
+ end
96
+
97
+ if attributes.key?(:'parent_id')
98
+ self.parent_id = attributes[:'parent_id']
99
+ end
100
+
101
+ if attributes.key?(:'position')
102
+ self.position = attributes[:'position']
103
+ end
104
+
105
+ if attributes.key?(:'is_taxonomy')
106
+ self.is_taxonomy = attributes[:'is_taxonomy']
107
+ end
108
+
109
+ if attributes.key?(:'bodyclass')
110
+ self.bodyclass = attributes[:'bodyclass']
111
+ end
112
+
113
+ if attributes.key?(:'localizations')
114
+ if (value = attributes[:'localizations']).is_a?(Hash)
115
+ self.localizations = value
116
+ end
117
+ end
118
+
119
+ if attributes.key?(:'created_at')
120
+ self.created_at = attributes[:'created_at']
121
+ end
122
+
123
+ if attributes.key?(:'updated_at')
124
+ self.updated_at = attributes[:'updated_at']
125
+ end
126
+ end
127
+
128
+ # Show invalid properties with the reasons. Usually used together with valid?
129
+ # @return Array for valid properties with the reasons
130
+ def list_invalid_properties
131
+ invalid_properties = Array.new
132
+ invalid_properties
133
+ end
134
+
135
+ # Check to see if the all the properties in the model are valid
136
+ # @return true if the model is valid
137
+ def valid?
138
+ true
139
+ end
140
+
141
+ # Checks equality by comparing each attribute.
142
+ # @param [Object] Object to be compared
143
+ def ==(o)
144
+ return true if self.equal?(o)
145
+ self.class == o.class &&
146
+ id == o.id &&
147
+ migration_identifier == o.migration_identifier &&
148
+ parent_id == o.parent_id &&
149
+ position == o.position &&
150
+ is_taxonomy == o.is_taxonomy &&
151
+ bodyclass == o.bodyclass &&
152
+ localizations == o.localizations &&
153
+ created_at == o.created_at &&
154
+ updated_at == o.updated_at
155
+ end
156
+
157
+ # @see the `==` method
158
+ # @param [Object] Object to be compared
159
+ def eql?(o)
160
+ self == o
161
+ end
162
+
163
+ # Calculates hash code according to all attributes.
164
+ # @return [Integer] Hash code
165
+ def hash
166
+ [id, migration_identifier, parent_id, position, is_taxonomy, bodyclass, localizations, created_at, updated_at].hash
167
+ end
168
+
169
+ # Builds the object from hash
170
+ # @param [Hash] attributes Model attributes in the form of hash
171
+ # @return [Object] Returns the model itself
172
+ def self.build_from_hash(attributes)
173
+ new.build_from_hash(attributes)
174
+ end
175
+
176
+ # Builds the object from hash
177
+ # @param [Hash] attributes Model attributes in the form of hash
178
+ # @return [Object] Returns the model itself
179
+ def build_from_hash(attributes)
180
+ return nil unless attributes.is_a?(Hash)
181
+ self.class.openapi_types.each_pair do |key, type|
182
+ if type =~ /\AArray<(.*)>/i
183
+ # check to ensure the input is an array given that the attribute
184
+ # is documented as an array but the input is not
185
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
186
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
187
+ end
188
+ elsif !attributes[self.class.attribute_map[key]].nil?
189
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
190
+ elsif attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
191
+ self.send("#{key}=", nil)
192
+ end
193
+ end
194
+
195
+ self
196
+ end
197
+
198
+ # Deserializes the data based on type
199
+ # @param string type Data type
200
+ # @param string value Value to be deserialized
201
+ # @return [Object] Deserialized data
202
+ def _deserialize(type, value)
203
+ case type.to_sym
204
+ when :DateTime
205
+ DateTime.parse(value)
206
+ when :Date
207
+ Date.parse(value)
208
+ when :String
209
+ value.to_s
210
+ when :Integer
211
+ value.to_i
212
+ when :Float
213
+ value.to_f
214
+ when :Boolean
215
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
216
+ true
217
+ else
218
+ false
219
+ end
220
+ when :Object
221
+ # generic object (usually a Hash), return directly
222
+ value
223
+ when /\AArray<(?<inner_type>.+)>\z/
224
+ inner_type = Regexp.last_match[:inner_type]
225
+ value.map { |v| _deserialize(inner_type, v) }
226
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
227
+ k_type = Regexp.last_match[:k_type]
228
+ v_type = Regexp.last_match[:v_type]
229
+ {}.tap do |hash|
230
+ value.each do |k, v|
231
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
232
+ end
233
+ end
234
+ else # model
235
+ OsunyApi.const_get(type).build_from_hash(value)
236
+ end
237
+ end
238
+
239
+ # Returns the string representation of the object
240
+ # @return [String] String presentation of the object
241
+ def to_s
242
+ to_hash.to_s
243
+ end
244
+
245
+ # to_body is an alias to to_hash (backward compatibility)
246
+ # @return [Hash] Returns the object in the form of hash
247
+ def to_body
248
+ to_hash
249
+ end
250
+
251
+ # Returns the object in the form of hash
252
+ # @return [Hash] Returns the object in the form of hash
253
+ def to_hash
254
+ hash = {}
255
+ self.class.attribute_map.each_pair do |attr, param|
256
+ value = self.send(attr)
257
+ if value.nil?
258
+ is_nullable = self.class.openapi_nullable.include?(attr)
259
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
260
+ end
261
+
262
+ hash[param] = _to_hash(value)
263
+ end
264
+ hash
265
+ end
266
+
267
+ # Outputs non-array value in the form of hash
268
+ # For object, use to_hash. Otherwise, just return the value
269
+ # @param [Object] value Any valid value
270
+ # @return [Hash] Returns the value in the form of hash
271
+ def _to_hash(value)
272
+ if value.is_a?(Array)
273
+ value.compact.map { |v| _to_hash(v) }
274
+ elsif value.is_a?(Hash)
275
+ {}.tap do |hash|
276
+ value.each { |k, v| hash[k] = _to_hash(v) }
277
+ end
278
+ elsif value.respond_to? :to_hash
279
+ value.to_hash
280
+ else
281
+ value
282
+ end
283
+ end end
284
+ end