Embed.php 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206
  1. <?php
  2. /* For licensing terms, see /license.txt */
  3. namespace Chamilo\PluginBundle\Entity\EmbedRegistry;
  4. use Chamilo\CoreBundle\Entity\Course;
  5. use Chamilo\CoreBundle\Entity\Session;
  6. use Doctrine\ORM\Mapping as ORM;
  7. /**
  8. * Class EmbedRegistry.
  9. *
  10. * @package Chamilo\PluginBundle\Entity\EmbedRegistry
  11. *
  12. * @ORM\Entity()
  13. * @ORM\Table(name="plugin_embed_registry_embed")
  14. */
  15. class Embed
  16. {
  17. /**
  18. * @var int
  19. *
  20. * @ORM\Column(name="id", type="integer")
  21. * @ORM\Id
  22. * @ORM\GeneratedValue
  23. */
  24. private $id;
  25. /**
  26. * @var string
  27. *
  28. * @ORM\Column(name="title", type="text")
  29. */
  30. private $title;
  31. /**
  32. * @var \DateTime
  33. *
  34. * @ORM\Column(name="display_start_date", type="datetime")
  35. */
  36. private $displayStartDate;
  37. /**
  38. * @var \DateTime
  39. *
  40. * @ORM\Column(name="display_end_date", type="datetime")
  41. */
  42. private $displayEndDate;
  43. /**
  44. * @var string
  45. *
  46. * @ORM\Column(name="html_code", type="text")
  47. */
  48. private $htmlCode;
  49. /**
  50. * @var Course
  51. *
  52. * @ORM\ManyToOne(targetEntity="Chamilo\CoreBundle\Entity\Course")
  53. * @ORM\JoinColumn(name="c_id", referencedColumnName="id", nullable=false)
  54. */
  55. private $course;
  56. /**
  57. * @var Session|null
  58. *
  59. * @ORM\ManyToOne(targetEntity="Chamilo\CoreBundle\Entity\Session")
  60. * @ORM\JoinColumn(name="session_id", referencedColumnName="id")
  61. */
  62. private $session;
  63. /**
  64. * @return int
  65. */
  66. public function getId()
  67. {
  68. return $this->id;
  69. }
  70. /**
  71. * @param int $id
  72. *
  73. * @return Embed
  74. */
  75. public function setId($id)
  76. {
  77. $this->id = $id;
  78. return $this;
  79. }
  80. /**
  81. * @return string
  82. */
  83. public function getTitle()
  84. {
  85. return $this->title;
  86. }
  87. /**
  88. * @param $title
  89. *
  90. * @return Embed
  91. */
  92. public function setTitle($title)
  93. {
  94. $this->title = $title;
  95. return $this;
  96. }
  97. /**
  98. * @return \DateTime
  99. */
  100. public function getDisplayStartDate()
  101. {
  102. return $this->displayStartDate;
  103. }
  104. /**
  105. * @param \DateTime $displayStartDate
  106. *
  107. * @return Embed
  108. */
  109. public function setDisplayStartDate(\DateTime $displayStartDate)
  110. {
  111. $this->displayStartDate = $displayStartDate;
  112. return $this;
  113. }
  114. /**
  115. * @return \DateTime
  116. */
  117. public function getDisplayEndDate()
  118. {
  119. return $this->displayEndDate;
  120. }
  121. /**
  122. * @param \DateTime $displayEndDate
  123. *
  124. * @return Embed
  125. */
  126. public function setDisplayEndDate(\DateTime $displayEndDate)
  127. {
  128. $this->displayEndDate = $displayEndDate;
  129. return $this;
  130. }
  131. /**
  132. * @return string
  133. */
  134. public function getHtmlCode()
  135. {
  136. return $this->htmlCode;
  137. }
  138. /**
  139. * @param string $htmlCode
  140. *
  141. * @return Embed
  142. */
  143. public function setHtmlCode($htmlCode)
  144. {
  145. $this->htmlCode = $htmlCode;
  146. return $this;
  147. }
  148. /**
  149. * @return Course
  150. */
  151. public function getCourse()
  152. {
  153. return $this->course;
  154. }
  155. /**
  156. * @param Course $course
  157. *
  158. * @return Embed
  159. */
  160. public function setCourse(Course $course)
  161. {
  162. $this->course = $course;
  163. return $this;
  164. }
  165. /**
  166. * @return Session|null
  167. */
  168. public function getSession()
  169. {
  170. return $this->session;
  171. }
  172. /**
  173. * @param Session|null $session
  174. *
  175. * @return Embed
  176. */
  177. public function setSession(Session $session = null)
  178. {
  179. $this->session = $session;
  180. return $this;
  181. }
  182. }