src/DTO/NewsDTO.php line 419

Open in your IDE?
  1. <?php
  2. namespace App\DTO;
  3. use DateTime;
  4. use JsonSerializable;
  5. class NewsDTO implements JsonSerializable
  6. {
  7. /**
  8. * @var integer
  9. */
  10. private $newsID;
  11. /**
  12. * @var string
  13. */
  14. private $token;
  15. /**
  16. * @var string
  17. */
  18. private $newsHeadline;
  19. /**
  20. * @var string
  21. */
  22. private $newsHeader;
  23. /**
  24. * @var string
  25. */
  26. private $observations;
  27. /**
  28. * @var string
  29. */
  30. private $category;
  31. /**
  32. * @var DateTime
  33. */
  34. private $newsPublicationDate;
  35. /**
  36. * @var DateTime
  37. */
  38. private $newsDateCreation;
  39. /**
  40. * @var string
  41. */
  42. private $newsSettingsCompany;
  43. /**
  44. * @var string
  45. */
  46. private $newsAuthor;
  47. /**
  48. * @var string
  49. */
  50. private $language;
  51. /**
  52. * @var string
  53. */
  54. private $document1;
  55. /**
  56. * @var string
  57. */
  58. private $document2;
  59. /**
  60. * @var string
  61. */
  62. private $document3;
  63. /**
  64. * @var boolean
  65. */
  66. private $enabled;
  67. /**
  68. * @var string
  69. */
  70. private $urlPublishing;
  71. /**
  72. * @var float
  73. */
  74. private $price;
  75. /**
  76. * @var string
  77. */
  78. private $slug;
  79. /**
  80. * @var string
  81. */
  82. private $metaDescription;
  83. /**
  84. * @var string
  85. */
  86. private $metaTitle;
  87. /**
  88. * @return mixed
  89. */
  90. public function getNewsID()
  91. {
  92. return $this->newsID;
  93. }
  94. /**
  95. * @param mixed $newsID
  96. */
  97. public function setNewsID($newsID)
  98. {
  99. $this->newsID = $newsID;
  100. }
  101. /**
  102. * @return string
  103. */
  104. public function getToken()
  105. {
  106. return $this->token;
  107. }
  108. /**
  109. * @param string $token
  110. */
  111. public function setToken($token)
  112. {
  113. $this->token = $token;
  114. }
  115. /**
  116. * @return mixed
  117. */
  118. public function getNewsHeadline()
  119. {
  120. return $this->newsHeadline;
  121. }
  122. /**
  123. * @param mixed $newsHeadline
  124. */
  125. public function setNewsHeadline($newsHeadline)
  126. {
  127. $this->newsHeadline = $newsHeadline;
  128. }
  129. /**
  130. * @return mixed
  131. */
  132. public function getNewsHeader()
  133. {
  134. return $this->newsHeader;
  135. }
  136. /**
  137. * @param mixed $newsHeader
  138. */
  139. public function setNewsHeader($newsHeader)
  140. {
  141. $this->newsHeader = $newsHeader;
  142. }
  143. /**
  144. * @return string
  145. */
  146. public function getObservations()
  147. {
  148. return $this->observations;
  149. }
  150. /**
  151. * @param string $observations
  152. */
  153. public function setObservations($observations)
  154. {
  155. $this->observations = $observations;
  156. }
  157. /**
  158. * @return string
  159. */
  160. public function getCategory()
  161. {
  162. return $this->category;
  163. }
  164. /**
  165. * @param string $category
  166. */
  167. public function setCategory($category)
  168. {
  169. $this->category = $category;
  170. }
  171. /**
  172. * @return DateTime
  173. */
  174. public function getNewsPublicationDate()
  175. {
  176. return $this->newsPublicationDate;
  177. }
  178. /**
  179. * @param DateTime $newsPublicationDate
  180. */
  181. public function setNewsPublicationDate($newsPublicationDate)
  182. {
  183. $this->newsPublicationDate = $newsPublicationDate;
  184. }
  185. /**
  186. * @return DateTime
  187. */
  188. public function getNewsDateCreation()
  189. {
  190. return $this->newsDateCreation;
  191. }
  192. /**
  193. * @param DateTime $newsDateCreation
  194. */
  195. public function setNewsDateCreation($newsDateCreation)
  196. {
  197. $this->newsDateCreation = $newsDateCreation;
  198. }
  199. /**
  200. * @return mixed
  201. */
  202. public function getNewsSettingsCompany()
  203. {
  204. return $this->newsSettingsCompany;
  205. }
  206. /**
  207. * @param mixed $newsSettingsCompany
  208. */
  209. public function setNewsSettingsCompany($newsSettingsCompany)
  210. {
  211. $this->newsSettingsCompany = $newsSettingsCompany;
  212. }
  213. /**
  214. * @return mixed
  215. */
  216. public function getNewsAuthor()
  217. {
  218. return $this->newsAuthor;
  219. }
  220. /**
  221. * @param mixed $newsAuthor
  222. */
  223. public function setNewsAuthor($newsAuthor)
  224. {
  225. $this->newsAuthor = $newsAuthor;
  226. }
  227. /**
  228. * @return string
  229. */
  230. public function getLanguage()
  231. {
  232. return $this->language;
  233. }
  234. /**
  235. * @param string $language
  236. */
  237. public function setLanguage($language)
  238. {
  239. $this->language = $language;
  240. }
  241. /**
  242. * @return string
  243. */
  244. public function getDocument1()
  245. {
  246. return $this->document1;
  247. }
  248. /**
  249. * @param string $document1
  250. */
  251. public function setDocument1($document1)
  252. {
  253. $this->document1 = $document1;
  254. }
  255. /**
  256. * @return string
  257. */
  258. public function getDocument2()
  259. {
  260. return $this->document2;
  261. }
  262. /**
  263. * @param string $document2
  264. */
  265. public function setDocument2($document2)
  266. {
  267. $this->document2 = $document2;
  268. }
  269. /**
  270. * @return string
  271. */
  272. public function getDocument3()
  273. {
  274. return $this->document3;
  275. }
  276. /**
  277. * @param string $document3
  278. */
  279. public function setDocument3($document3)
  280. {
  281. $this->document3 = $document3;
  282. }
  283. /**
  284. * @return bool
  285. */
  286. public function isEnabled()
  287. {
  288. return $this->enabled;
  289. }
  290. /**
  291. * @param bool $enabled
  292. */
  293. public function setEnabled($enabled)
  294. {
  295. $this->enabled = $enabled;
  296. }
  297. /**
  298. * @return string
  299. */
  300. public function getUrlPublishing()
  301. {
  302. return $this->urlPublishing;
  303. }
  304. /**
  305. * @param string $urlPublishing
  306. */
  307. public function setUrlPublishing($urlPublishing)
  308. {
  309. $this->urlPublishing = $urlPublishing;
  310. }
  311. /**
  312. * @return float
  313. */
  314. public function getPrice()
  315. {
  316. return $this->price;
  317. }
  318. /**
  319. * @param float $price
  320. */
  321. public function setPrice($price)
  322. {
  323. $this->price = $price;
  324. }
  325. public function getSlug(): string{
  326. return $this->slug;
  327. }
  328. public function setSlug($slug){
  329. $this->slug = $slug;
  330. }
  331. public function getMetaDescription(): string{
  332. return $this->metaDescription;
  333. }
  334. public function setMetaDescription($metaDescription){
  335. $this->metaDescription = $metaDescription;
  336. }
  337. public function getMetaTitle(): string{
  338. return $this->metaTitle;
  339. }
  340. public function setMetaTitle($metaTitle){
  341. $this->metaTitle = $metaTitle;
  342. }
  343. /**
  344. * Specify data which should be serialized to JSON
  345. * @link https://php.net/manual/en/jsonserializable.jsonserialize.php
  346. * @return mixed data which can be serialized by <b>json_encode</b>,
  347. * which is a value of any type other than a resource.
  348. * @since 5.4.0
  349. */
  350. public function jsonSerialize()
  351. {
  352. // TODO: Implement jsonSerialize() method.
  353. $collection = array();
  354. $collection["newsID"] = $this->newsID;
  355. $collection["token"] = $this->token;
  356. $collection["newsHeadline"] = $this->newsHeadline;
  357. $collection["newsHeader"] = $this->newsHeader;
  358. $collection["observations"] = $this->observations;
  359. $collection["category"] = $this->category;
  360. $collection["newsPublicationDate"] = $this->newsPublicationDate;
  361. $collection["newsDateCreation"] = $this->newsDateCreation;
  362. $collection["newsSettingsCompany"] = $this->newsSettingsCompany;
  363. $collection["newsAuthor"] = $this->newsAuthor;
  364. $collection["document1"] = $this->document1;
  365. $collection["document2"] = $this->document2;
  366. $collection["document3"] = $this->document3;
  367. $collection["language"] = $this->language;
  368. $collection["enabled"] = $this->enabled;
  369. $collection["urlPublishing"] = $this->urlPublishing;
  370. $collection["price"] = $this->price;
  371. $collection["slug"] = $this->slug;
  372. $collection["metaDescription"] = $this->metaDescription;
  373. $collection["metaTitle"] = $this->metaTitle;
  374. return $collection;
  375. }
  376. }