src/CoreBundle/Entity/SelfStudy.php line 13

Open in your IDE?
  1. <?php
  2. namespace CoreBundle\Entity;
  3. use Doctrine\Common\Collections\ArrayCollection;
  4. use Doctrine\Common\Collections\Collection;
  5. use Doctrine\ORM\Mapping as ORM;
  6. /**
  7. * @ORM\Table("self_study")
  8. * @ORM\Entity
  9. */
  10. class SelfStudy
  11. {
  12. /**
  13. * @var int
  14. *
  15. * @ORM\Column(name="id", type="integer")
  16. * @ORM\Id
  17. * @ORM\GeneratedValue(strategy="AUTO")
  18. */
  19. private $id;
  20. /**
  21. * @var string
  22. *
  23. * @ORM\Column(name="display_name", type="string", length=255)
  24. */
  25. private $displayName;
  26. /**
  27. * @var ClassroomType
  28. *
  29. * @ORM\OneToOne(targetEntity="CoreBundle\Entity\ClassroomType")
  30. * @ORM\JoinColumn(name="classroom_type", referencedColumnName="id")
  31. */
  32. private $classroomType;
  33. /**
  34. * @var ArrayCollection|SelfStudyCategory[]
  35. *
  36. * @ORM\OneToMany(targetEntity="CoreBundle\Entity\SelfStudyCategory", mappedBy="selfStudy")
  37. */
  38. private $selfStudyCategories;
  39. /**
  40. * @var ArrayCollection|SelfStudyTypicalExamProblem[]
  41. *
  42. * @ORM\ManyToMany(targetEntity="CoreBundle\Entity\SelfStudyTypicalExamProblem", mappedBy="selfStudyList")
  43. */
  44. private $typicalExamProblems;
  45. /**
  46. * @var ArrayCollection|SelfStudyExamQuiz[]
  47. *
  48. * @ORM\OneToMany(targetEntity="CoreBundle\Entity\SelfStudyExamQuiz", mappedBy="selfStudy")
  49. */
  50. private $selfStudyExamQuizzes;
  51. /**
  52. * @var bool
  53. *
  54. * @ORM\Column(name="has_exam_card", type="boolean", options={"default": true})
  55. */
  56. private bool $hasExamCard = true;
  57. /**
  58. * @var string
  59. *
  60. * @ORM\Column(name="typical_exam_problem_teaser", type="string", length=1000, nullable=true, options={"default": ""})
  61. */
  62. private $typicalExamProblemTeaser;
  63. public function __construct()
  64. {
  65. $this->selfStudyCategories = new ArrayCollection();
  66. $this->typicalExamProblems = new ArrayCollection();
  67. }
  68. public function getId(): int
  69. {
  70. return $this->id;
  71. }
  72. public function getDisplayName(): string
  73. {
  74. return $this->displayName;
  75. }
  76. public function getClassroomType(): ClassroomType
  77. {
  78. return $this->classroomType;
  79. }
  80. public function getTypicalExamProblems(): Collection
  81. {
  82. return $this->typicalExamProblems;
  83. }
  84. public function getSelfStudyCategories(): Collection
  85. {
  86. return $this->selfStudyCategories;
  87. }
  88. public function getTypicalExamProblemTeaser(): ?string
  89. {
  90. return $this->typicalExamProblemTeaser;
  91. }
  92. public function hasExamCard(): bool
  93. {
  94. return $this->hasExamCard;
  95. }
  96. }