CQuizQuestionRelCategory.php 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171
  1. <?php
  2. namespace Entity;
  3. use Doctrine\ORM\Mapping as ORM;
  4. /**
  5. * CQuizQuestionRelCategory
  6. *
  7. * @ORM\Table(name="c_quiz_question_rel_category")
  8. * @ORM\Entity(repositoryClass="Entity\Repository\CQuizQuestionRelCategoryRepository")
  9. */
  10. class CQuizQuestionRelCategory
  11. {
  12. /**
  13. * @var integer
  14. *
  15. * @ORM\Column(name="iid", type="integer", precision=0, scale=0, nullable=false, unique=false)
  16. * @ORM\Id
  17. * @ORM\GeneratedValue(strategy="IDENTITY")
  18. */
  19. private $iid;
  20. /**
  21. * @var integer
  22. *
  23. * @ORM\Column(name="c_id", type="integer", precision=0, scale=0, nullable=false, unique=false)
  24. * @ORM\Id
  25. * @ORM\GeneratedValue(strategy="NONE")
  26. */
  27. private $cId;
  28. /**
  29. * @var integer
  30. *
  31. * @ORM\Column(name="question_id", type="integer", precision=0, scale=0, nullable=false, unique=false)
  32. * @ORM\Id
  33. * @ORM\GeneratedValue(strategy="NONE")
  34. */
  35. private $questionId;
  36. /**
  37. * @var integer
  38. *
  39. * @ORM\Column(name="category_id", type="integer", precision=0, scale=0, nullable=false, unique=false)
  40. */
  41. private $categoryId;
  42. /** Relationships */
  43. /**
  44. * @ORM\ManyToOne(targetEntity="CQuizCategory")
  45. * @ORM\JoinColumn(name="category_id", referencedColumnName="iid")
  46. */
  47. private $category;
  48. /**
  49. * @ORM\ManyToOne(targetEntity="CQuizQuestion")
  50. * @ORM\JoinColumn(name="question_id", referencedColumnName="iid")
  51. */
  52. private $question;
  53. public function __construct(CQuizCategory $category, CQuizQuestion $question)
  54. {
  55. $this->category = $category;
  56. $this->question = $question;
  57. }
  58. public function getCategory()
  59. {
  60. return $this->category;
  61. }
  62. public function getQuestion()
  63. {
  64. return $this->question;
  65. }
  66. /**
  67. * Set id
  68. *
  69. * @param integer $id
  70. * @return CQuizQuestionCategory
  71. */
  72. public function setIid($id)
  73. {
  74. $this->iid = $id;
  75. return $this;
  76. }
  77. /**
  78. * Get id
  79. *
  80. * @return integer
  81. */
  82. public function getIid()
  83. {
  84. return $this->iid;
  85. }
  86. /**
  87. * Set cId
  88. *
  89. * @param integer $cId
  90. * @return CQuizQuestionRelCategory
  91. */
  92. public function setCId($cId)
  93. {
  94. $this->cId = $cId;
  95. return $this;
  96. }
  97. /**
  98. * Get cId
  99. *
  100. * @return integer
  101. */
  102. public function getCId()
  103. {
  104. return $this->cId;
  105. }
  106. /**
  107. * Set questionId
  108. *
  109. * @param integer $questionId
  110. * @return CQuizQuestionRelCategory
  111. */
  112. public function setQuestionId($questionId)
  113. {
  114. $this->questionId = $questionId;
  115. return $this;
  116. }
  117. /**
  118. * Get questionId
  119. *
  120. * @return integer
  121. */
  122. public function getQuestionId()
  123. {
  124. return $this->questionId;
  125. }
  126. /**
  127. * Set categoryId
  128. *
  129. * @param integer $categoryId
  130. * @return CQuizQuestionRelCategory
  131. */
  132. public function setCategoryId($categoryId)
  133. {
  134. $this->categoryId = $categoryId;
  135. return $this;
  136. }
  137. /**
  138. * Get categoryId
  139. *
  140. * @return integer
  141. */
  142. public function getCategoryId()
  143. {
  144. return $this->categoryId;
  145. }
  146. }