<?php
namespace App\Entity;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\Common\Collections\Collection;
use Doctrine\ORM\Mapping as ORM;
use App\BackendBundle\Model\Job\RequirementCollection;
use App\BackendBundle\Model\Job\RequirementTypeCollection;
class Job {
/**
* @var integer
*/
private $id;
/**
* @var string
*/
private $name;
/**
* @var string
*/
private $description;
/**
* @var boolean
*/
private $isScholasticProfession = 0;
/**
* @var string
*/
private $scholasticDuration;
/**
* @var integer
*/
private $lbrNr;
/**
* @var int|null
*/
private $mlbrnr;
/**
* @var string
*/
private $operationsAndTasks;
/**
* @var string
*/
private $selfEmployed;
/**
* @var string|null
*/
private $bicID;
/**
* @var string
*/
private $bicAnforderungen;
/**
* @var string
*/
private $bicAlternativen;
/**
* @var string
*/
private $bicLehreMatura;
/**
* @var string
*/
private $bicAusbildungBerufschule;
/**
* @var string
*/
private $bicMoeglichkeiten;
/**
* @var \App\Entity\Media
*/
private $image;
/**
* @var \App\Entity\Media
*/
private $teaserImage;
/**
* @var \App\Entity\Gallery
*/
private $gallery;
/**
* @var \Doctrine\Common\Collections\Collection
*/
private $jobSectors;
/**
* @var \Doctrine\Common\Collections\Collection
*/
private $jobExpertTerms;
/**
* @var \Doctrine\Common\Collections\Collection
*/
private $jobEducationalPaths;
/**
* @var \Doctrine\Common\Collections\Collection
*/
private $companyProfiles;
/**
* @var \Doctrine\Common\Collections\Collection
*/
private $jobWorkFields;
/**
* @var \Doctrine\Common\Collections\Collection
*/
private $jobSchools;
/**
* @var \Doctrine\Common\Collections\Collection
*/
private $jobRedirects;
/**
* @var \Doctrine\Common\Collections\Collection
*/
private $schoolSubjectMappings;
/**
* @var \App\Entity\JobSalary
*/
private $salary;
/**
* @var \App\Entity\JobPDF
*/
private $jobPDF;
/**
* @var \Doctrine\Common\Collections\Collection
*/
private $searchTags;
/**
* @var \Doctrine\Common\Collections\Collection
*/
private $interestFields;
/**
* @var \Doctrine\Common\Collections\Collection
*/
private $jobLinkMappings;
/**
* @var \Doctrine\Common\Collections\Collection
*/
private $jobRequirementMappings;
/**
* @var boolean
*/
private $showSchoolSubjects = 0;
/**
* @var \DateTime
*/
private $updateAt;
/**
* Constructor
*/
public function __construct() {
$this->companyProfiles = new \Doctrine\Common\Collections\ArrayCollection();
$this->jobEducationalPaths = new \Doctrine\Common\Collections\ArrayCollection();
$this->jobExpertTerms = new \Doctrine\Common\Collections\ArrayCollection();
$this->jobLinkMappings = new \Doctrine\Common\Collections\ArrayCollection();
$this->jobRequirementMappings = new \Doctrine\Common\Collections\ArrayCollection();
$this->jobRedirects = new \Doctrine\Common\Collections\ArrayCollection();
$this->jobSchools = new ArrayCollection();
$this->jobSectors = new \Doctrine\Common\Collections\ArrayCollection();
$this->jobWorkFields = new \Doctrine\Common\Collections\ArrayCollection();
$this->interestFields = new \Doctrine\Common\Collections\ArrayCollection();
$this->schoolSubjectMappings = new ArrayCollection();
$this->searchTags = new ArrayCollection();
}
/**
* Get id
*
* @return integer
*/
public function getId() {
return $this->id;
}
/**
* Set name
*
* @param string $name
*
* @return Job
*/
public function setName($name) {
$this->name = $name;
return $this;
}
/**
* Get name
*
* @return string
*/
public function getName() {
return $this->name;
}
/**
* Set description
*
* @param string $description
*
* @return Job
*/
public function setDescription($description) {
$this->description = $description;
return $this;
}
/**
* Get description
*
* @return string
*/
public function getDescription() {
return $this->description;
}
/**
* Set isScholasticProfession
*
* @param boolean $isScholasticProfession
*
* @return Job
*/
public function setIsScholasticProfession($isScholasticProfession) {
$this->isScholasticProfession = $isScholasticProfession;
return $this;
}
/**
* Get isScholasticProfession
*
* @return boolean
*/
public function getIsScholasticProfession() {
return $this->isScholasticProfession;
}
/**
* Set showSchoolSubjects
*
* @param boolean $showSchoolSubjects
*
* @return Job
*/
public function setShowSchoolSubjects($showSchoolSubjects) {
$this->showSchoolSubjects = $showSchoolSubjects;
return $this;
}
/**
* Get showSchoolSubjects
*
* @return boolean
*/
public function getShowSchoolSubjects() {
return $this->showSchoolSubjects;
}
/**
* Set scholasticDuration
*
* @param string $scholasticDuration
*
* @return Job
*/
public function setScholasticDuration($scholasticDuration) {
$this->scholasticDuration = $scholasticDuration;
return $this;
}
/**
* Get scholasticDuration
*
* @return \App\Entity\JobScholasticDuration|null
*/
public function getScholasticDuration() {
return $this->scholasticDuration;
}
/**
* Set lbrNr
*
* @param integer $lbrNr
*
* @return Job
*/
public function setLbrNr($lbrNr) {
$this->lbrNr = $lbrNr;
return $this;
}
/**
* Get lbrNr
*
* @return integer
*/
public function getLbrNr() {
return $this->lbrNr;
}
/**
* Set operationsAndTasks
*
* @param string $operationsAndTasks
*
* @return Job
*/
public function setOperationsAndTasks($operationsAndTasks) {
$this->operationsAndTasks = $operationsAndTasks;
return $this;
}
/**
* Get operationsAndTasks
*
* @return string
*/
public function getOperationsAndTasks() {
return $this->operationsAndTasks;
}
/**
* Set selfEmployed
*
* @param string $selfEmployed
*
* @return Job
*/
public function setSelfEmployed($selfEmployed) {
$this->selfEmployed = $selfEmployed;
return $this;
}
/**
* Get selfEmployed
*
* @return string
*/
public function getSelfEmployed() {
return $this->selfEmployed;
}
/**
* Set bicAnforderungen
*
* @param string $bicAnforderungen
*
* @return Job
*/
public function setBicAnforderungen($bicAnforderungen) {
$this->bicAnforderungen = $bicAnforderungen;
return $this;
}
/**
* Get bicAnforderungen
*
* @return string
*/
public function getBicAnforderungen() {
return $this->bicAnforderungen;
}
/**
* Set bicAlternativen
*
* @param string $bicAlternativen
*
* @return Job
*/
public function setBicAlternativen($bicAlternativen) {
$this->bicAlternativen = $bicAlternativen;
return $this;
}
/**
* Get bicAlternativen
*
* @return string
*/
public function getBicAlternativen() {
return $this->bicAlternativen;
}
/**
* Set bicLehreMatura
*
* @param string $bicLehreMatura
*
* @return Job
*/
public function setBicLehreMatura($bicLehreMatura) {
$this->bicLehreMatura = $bicLehreMatura;
return $this;
}
/**
* Get bicLehreMatura
*
* @return string
*/
public function getBicLehreMatura() {
return $this->bicLehreMatura;
}
/**
* Set bicAusbildungBerufschule
*
* @param string $bicAusbildungBerufschule
*
* @return Job
*/
public function setBicAusbildungBerufschule($bicAusbildungBerufschule) {
$this->bicAusbildungBerufschule = $bicAusbildungBerufschule;
return $this;
}
/**
* Get bicAusbildungBerufschule
*
* @return string
*/
public function getBicAusbildungBerufschule() {
return $this->bicAusbildungBerufschule;
}
/**
* Set bicMoeglichkeiten
*
* @param string $bicMoeglichkeiten
*
* @return Job
*/
public function setBicMoeglichkeiten($bicMoeglichkeiten) {
$this->bicMoeglichkeiten = $bicMoeglichkeiten;
return $this;
}
/**
* Get bicMoeglichkeiten
*
* @return string
*/
public function getBicMoeglichkeiten() {
return $this->bicMoeglichkeiten;
}
public function getUpdateAt() {
return $this->updateAt;
}
public function setUpdateAt($updateAt) {
$this->updateAt = $updateAt;
}
/**
* Set image
*
* @param \App\Entity\Media $image
*
* @return Job
*/
public function setImage(\App\Entity\Media $image = null) {
$this->image = $image;
return $this;
}
/**
* Get image
*
* @return \App\Entity\Media
*/
public function getImage() {
return $this->image;
}
/**
* Set teaserImage
*
* @param \App\Entity\Media $teaserImage
*
* @return Job
*/
public function setTeaserImage(\App\Entity\Media $teaserImage = null) {
$this->teaserImage = $teaserImage;
return $this;
}
/**
* Get teaserImage
*
* @return \App\Entity\Media
*/
public function getTeaserImage() {
return $this->teaserImage;
}
/**
* Set gallery
*
* @param \App\Entity\Gallery $gallery
*
* @return Job
*/
public function setGallery(\App\Entity\Gallery $gallery = null) {
$this->gallery = $gallery;
return $this;
}
/**
* Get gallery
*
* @return \App\Entity\Gallery
*/
public function getGallery() {
return $this->gallery;
}
/**
* Add jobSector
*
* @param \App\Entity\JobSector $jobSector
*
* @return Job
*/
public function addJobSector(\App\Entity\JobSector $jobSector) {
$this->jobSectors[] = $jobSector;
return $this;
}
/**
* Remove jobSector
*
* @param \App\Entity\JobSector $jobSector
*/
public function removeJobSector(\App\Entity\JobSector $jobSector) {
$this->jobSectors->removeElement($jobSector);
}
/**
* Get jobSectors
*
* @return \Doctrine\Common\Collections\Collection
*/
public function getJobSectors() {
return $this->jobSectors;
}
/**
* Add jobExpertTerm
*
* @param \App\Entity\JobExpertTerm $jobExpertTerm
*
* @return Job
*/
public function addJobExpertTerm(\App\Entity\JobExpertTerm $jobExpertTerm) {
$this->jobExpertTerms[] = $jobExpertTerm;
return $this;
}
/**
* Remove jobExpertTerm
*
* @param \App\Entity\JobExpertTerm $jobExpertTerm
*/
public function removeJobExpertTerm(\App\Entity\JobExpertTerm $jobExpertTerm) {
$this->jobExpertTerms->removeElement($jobExpertTerm);
}
/**
* Get jobExpertTerms
*
* @return \Doctrine\Common\Collections\Collection
*/
public function getJobExpertTerms() {
return $this->jobExpertTerms;
}
/**
* Add interestField
*
* @param \App\Entity\InterestField $interestField
*
* @return Job
*/
public function addInterestField(\App\Entity\InterestField $interestField) {
$this->interestFields[] = $interestField;
return $this;
}
/**
* Remove interestField
*
* @param \App\Entity\InterestField $interestField
*/
public function removeInterestField(\App\Entity\InterestField $interestField) {
$this->interestFields->removeElement($interestField);
}
/**
* Get interestField
*
* @return \Doctrine\Common\Collections\Collection
*/
public function getInterestFields() {
return $this->interestFields;
}
/**
* Add jobEducationalPath
*
* @param \App\Entity\JobEducationalPath $jobEducationalPath
*
* @return Job
*/
public function addJobEducationalPath(\App\Entity\JobEducationalPath $jobEducationalPath) {
$this->jobEducationalPaths[] = $jobEducationalPath;
return $this;
}
/**
* Remove jobEducationalPath
*
* @param \App\Entity\JobEducationalPath $jobEducationalPath
*/
public function removeJobEducationalPath(\App\Entity\JobEducationalPath $jobEducationalPath) {
$this->jobEducationalPaths->removeElement($jobEducationalPath);
}
/**
* Get jobEducationalPaths
*
* @return \Doctrine\Common\Collections\Collection
*/
public function getJobEducationalPaths() {
return $this->jobEducationalPaths;
}
/**
* Add companyProfile
*
* @param \App\Entity\CompanyProfile $companyProfile
*
* @return Job
*/
public function addCompanyProfile(\App\Entity\CompanyProfile $companyProfile) {
$this->companyProfiles[] = $companyProfile;
return $this;
}
/**
* Remove companyProfile
*
* @param \App\Entity\CompanyProfile $companyProfile
*/
public function removeCompanyProfile(\App\Entity\CompanyProfile $companyProfile) {
$this->companyProfiles->removeElement($companyProfile);
}
/**
* Get companyProfiles
*
* @return \Doctrine\Common\Collections\Collection
*/
public function getCompanyProfiles() {
return $this->companyProfiles;
}
/**
* Add jobWorkField
*
* @param \App\Entity\JobWorkField $jobWorkField
*
* @return Job
*/
public function addJobWorkField(\App\Entity\JobWorkField $jobWorkField) {
$this->jobWorkFields[] = $jobWorkField;
return $this;
}
/**
* Remove jobWorkField
*
* @param \App\Entity\JobWorkField $jobWorkField
*/
public function removeJobWorkField(\App\Entity\JobWorkField $jobWorkField) {
$this->jobWorkFields->removeElement($jobWorkField);
}
/**
* Get jobWorkFields
*
* @return \Doctrine\Common\Collections\Collection
*/
public function getJobWorkFields() {
return $this->jobWorkFields;
}
/**
* Set bicID.
*
* @param string|null $bicID
*
* @return Job
*/
public function setBicID($bicID = null) {
$this->bicID = $bicID;
return $this;
}
/**
* Get bicID.
*
* @return string|null
*/
public function getBicID() {
return $this->bicID;
}
/**
* Set mlbrnr.
*
* @param int|null $mlbrnr
*
* @return Job
*/
public function setMlbrnr($mlbrnr = null) {
$this->mlbrnr = $mlbrnr;
return $this;
}
/**
* Add jobSchool.
*
* @param \App\Entity\JobSchool $jobSchool
*
* @return Job
*/
public function addJobSchool(\App\Entity\JobSchool $jobSchool) {
$this->jobSchools[] = $jobSchool;
return $this;
}
/**
* Remove jobSchool.
*
* @param \App\Entity\JobSchool $jobSchool
*
* @return boolean TRUE if this collection contained the specified element, FALSE otherwise.
*/
public function removeJobSchool(\App\Entity\JobSchool $jobSchool) {
return $this->jobSchools->removeElement($jobSchool);
}
/**
* Get jobSchools.
*
* @return \Doctrine\Common\Collections\Collection
*/
public function getJobSchools() {
return $this->jobSchools;
}
/**
* Add jobSchoolSubjectMapping.
*
* @param \App\Entity\JobSchoolSubjectMapping $jobSchoolSubjectMapping
*
* @return Job
*/
public function addSchoolSubjectMapping(\App\Entity\JobSchoolSubjectMapping $jobSchoolSubjectMapping) {
$this->schoolSubjectMappings[] = $jobSchoolSubjectMapping;
return $this;
}
/**
* Remove jobSchoolSubjectMapping.
*
* @param \App\Entity\JobSchoolSubjectMapping $jobSchoolSubjectMapping
*
* @return boolean TRUE if this collection contained the specified element, FALSE otherwise.
*/
public function removeSchoolSubjectMapping(\App\Entity\JobSchoolSubjectMapping $jobSchoolSubjectMapping) {
return $this->schoolSubjectMappings->removeElement($jobSchoolSubjectMapping);
}
/**
* Get jobSchoolSubjectMappings.
*
* @return \Doctrine\Common\Collections\Collection
*/
public function getSchoolSubjectMappings() {
return $this->schoolSubjectMappings;
}
/**
* Get mlbrnr.
*
* @return int|null
*/
public function getMlbrnr() {
return $this->mlbrnr;
}
public function getNameReduced() {
$nameWoLehrberuf = preg_replace('/\(Lehrberuf\)/', '', $this->name);
$nameWoModul = preg_replace('/\(Modullehrberuf\)/', '', $nameWoLehrberuf);
return $nameWoModul;
}
// Lehrausbildung
public function isEducationalTraining() {
if (!empty($this->lbrNr)) {
return true;
}
/* @var $jobPath JobEducationalPaths */
foreach ($this->jobEducationalPaths as $jobPath) {
if ($jobPath->getId() == 1) {
return true;
}
}
return false;
}
// Fachausbildung
public function isProfessionalTraining() {
/* @var $jobPath JobEducationalPaths */
foreach ($this->jobEducationalPaths as $jobPath) {
if ($jobPath->getId() == 2) {
return true;
}
}
return false;
}
public function isAcademicTraining() {
/* @var $jobPath JobEducationalPaths */
foreach ($this->jobEducationalPaths as $jobPath) {
if ($jobPath->getId() == 3) {
return true;
}
}
return false;
}
public function isOtherTraining() {
/* @var $jobPath JobEducationalPaths */
foreach ($this->jobEducationalPaths as $jobPath) {
if ($jobPath->getId() == 4) {
return true;
}
}
return false;
}
/**
* Set salary.
*
* @param \App\Entity\JobSalary|null $salary
*
* @return Job
*/
public function setSalary(\App\Entity\JobSalary $salary = null) {
$this->salary = $salary;
return $this;
}
/**
* Get salary.
*
* @return \App\Entity\JobSalary|null
*/
public function getSalary() {
return $this->salary;
}
/**
* Set jobPDF.
*
* @param \App\Entity\JobPDF|null $jobPDF
*
* @return Job
*/
public function setJobPDF(\App\Entity\JobPDF $jobPDF = null) {
$this->jobPDF = $jobPDF;
return $this;
}
/**
* Get jobPDF.
*
* @return \App\Entity\JobPDF|null
*/
public function getJobPDF() {
return $this->jobPDF;
}
/**
* Add searchTag.
*
* @param \App\Entity\SearchTag $searchTag
*
* @return Job
*/
public function addSearchTag(\App\Entity\SearchTag $searchTag) {
$this->searchTags[] = $searchTag;
return $this;
}
/**
* Remove searchTag.
*
* @param \App\Entity\SearchTag $searchTag
*
* @return boolean TRUE if this collection contained the specified element, FALSE otherwise.
*/
public function removeSearchTag(\App\Entity\SearchTag $searchTag) {
return $this->searchTags->removeElement($searchTag);
}
/**
* Get searchTags.
*
* @return \Doctrine\Common\Collections\Collection
*/
public function getSearchTags() {
return $this->searchTags;
}
/**
* Add jobRequirementMapping.
*
* @param \App\Entity\JobRequirementMapping $jobRequirementMapping
*
* @return Job
*/
public function addJobRequirementMapping(\App\Entity\JobRequirementMapping $jobRequirementMapping) {
$this->jobRequirementMappings[] = $jobRequirementMapping;
return $this;
}
/**
* Remove jobRequirementMapping.
*
* @param \App\Entity\JobRequirementMapping $jobRequirementMapping
*
* @return boolean TRUE if this collection contained the specified element, FALSE otherwise.
*/
public function removeJobRequirementMapping(\App\Entity\JobRequirementMapping $jobRequirementMapping) {
return $this->jobRequirementMappings->removeElement($jobRequirementMapping);
}
/**
* Get jobRequirementMappings.
*
* @return \Doctrine\Common\Collections\Collection
*/
public function getJobRequirementMappings() {
return $this->jobRequirementMappings;
}
/**
* Add jobRedirect.
*
* @param \App\Entity\JobRedirect $jobRedirect
*
* @return Job
*/
public function addJobRedirect(\App\Entity\JobRedirect $jobRedirect) {
$this->jobRedirects[] = $jobRedirect;
return $this;
}
/**
* Remove jobRedirect.
*
* @param \App\Entity\JobRedirect $jobRedirect
*
* @return boolean TRUE if this collection contained the specified element, FALSE otherwise.
*/
public function removeJobRedirect(\App\Entity\JobRedirect $jobRedirect) {
return $this->jobRedirects->removeElement($jobRedirect);
}
/**
* Get jobRedirects.
*
* @return \Doctrine\Common\Collections\Collection
*/
public function getJobRedirects() {
return $this->jobRedirects;
}
/**
* Add jobLinkMapping.
*
* @param \App\Entity\JobLinkMappings $jobLinkMapping
*
* @return Job
*/
public function addJobLinkMapping(\App\Entity\JobLinkMapping $jobLinkMapping) {
$this->jobLinkMappings[] = $jobLinkMapping;
return $this;
}
/**
* Remove jobLinkMapping.
*
* @param \App\Entity\JobLinkMappings $jobLinkMapping
*
* @return boolean TRUE if this collection contained the specified element, FALSE otherwise.
*/
public function removeJobLinkMapping(\App\Entity\JobLinkMapping $jobLinkMapping) {
return $this->jobLinkMappings->removeElement($jobLinkMapping);
}
/**
* Get jobLinkMappings.
*
* @return \Doctrine\Common\Collections\Collection
*/
public function getJobLinkMappings() {
return $this->jobLinkMappings;
}
public function __toString() {
return $this->name;
}
}