Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class CodeDirectorySpecialities
- {
- use Timestampable;
- /**
- * @var integer
- *
- * @ORM\Column(name="id", type="integer")
- * @ORM\Id
- * @ORM\GeneratedValue(strategy="AUTO")
- */
- private $id;
- /**
- * @var string
- *
- * @ORM\Column(name="specialities", type="string", length=255)
- */
- private $specialities;
- /**
- * @ORM\ManyToMany(targetEntity="Artel\ProfileBundle\Entity\Skill", mappedBy="specialities", cascade={"persist"})
- */
- protected $skills;
- /**
- * Constructor
- */
- public function __construct()
- {
- $this->skills = new \Doctrine\Common\Collections\ArrayCollection();
- }
- /**
- * Get id
- *
- * @return integer
- */
- public function setId($id)
- {
- $this->id = $id;
- return $this;
- }
- /**
- * Get id
- *
- * @return integer
- */
- public function getId()
- {
- return $this->id;
- }
- /**
- * Set specialities
- *
- * @param string $specialities
- *
- * @return CodeDirectorySpecialities
- */
- public function setSpecialities($specialities)
- {
- $this->specialities = $specialities;
- return $this;
- }
- /**
- * Get specialities
- *
- * @return string
- */
- public function getSpecialities()
- {
- return $this->specialities;
- }
- /**
- * Add skill
- *
- * @param \Artel\ProfileBundle\Entity\Skill $skill
- *
- * @return CodeDirectorySpecialities
- */
- public function addSkill(\Artel\ProfileBundle\Entity\Skill $skill)
- {
- $this->skills[] = $skill;
- return $this;
- }
- /**
- * Remove skill
- *
- * @param \Artel\ProfileBundle\Entity\Skill $skill
- */
- public function removeSkill(\Artel\ProfileBundle\Entity\Skill $skill)
- {
- $this->skills->removeElement($skill);
- }
- /**
- * Get skills
- *
- * @return \Doctrine\Common\Collections\Collection
- */
- public function getSkills()
- {
- return $this->skills;
- }
- public function __toString()
- {
- return $this->specialities;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment