src/JuridicusBundle/Entity/Pruefer.php line 15

Open in your IDE?
  1. <?php
  2. namespace JF\JuridicusBundle\Entity;
  3. use Doctrine\ORM\Mapping as ORM;
  4. use Symfony\Component\Validator\Constraints as Assert;
  5. use Symfony\Bridge\Doctrine\Validator\Constraints\UniqueEntity;
  6. use JF\JuridicusBundle\Validator\Constraints as JfAssert;
  7. use JF\JuridicusBundle\Entity\Pruefung;
  8. /**
  9.  * Prüfer
  10.  *
  11.  * @JfAssert\UniquePruefer
  12.  */
  13. class Pruefer extends InitModeEntity
  14. {
  15.     const CLASSNAME __CLASS__;
  16.     /**
  17.      * @var string[]
  18.      */
  19.     private static $adel_options = array( 'von der''van den''vom''von''van''de' );
  20.     /**
  21.      *
  22.      * @return string[]
  23.      */
  24.     public static function getAdelOptions()
  25.     {
  26.         return self::$adel_options;
  27.     }
  28.     /**
  29.      * @var integer
  30.      */
  31.     private $id;
  32.     /**
  33.      * @var string
  34.      * @Assert\Length(max="63")
  35.      */
  36.     private $vorname;
  37.     /**
  38.      * @var string
  39.      * @Assert\Length(max="12")
  40.      */
  41.     private $adel;
  42.     /**
  43.      * @var string
  44.      * @Assert\NotBlank
  45.      * @Assert\Length(max="63")
  46.      */
  47.     private $nachname;
  48.     /**
  49.      * @var string
  50.      */
  51.     private $email;
  52.     /**
  53.      * @var string
  54.      */
  55.     private $anschrift;
  56.     
  57.     /**
  58.      * @var string
  59.      */
  60.     private $strasse;
  61.     /**
  62.      * @var string
  63.      */
  64.     private $hausnummer;
  65.     /**
  66.      * @var string
  67.      */
  68.     private $plz;
  69.     /**
  70.      * @var string
  71.      */
  72.     private $ort;
  73.     /**
  74.      * @var string
  75.      * @Assert\Length(max="255")
  76.      */
  77.     private $works_at;
  78.     /**
  79.      * @var string
  80.      * @Assert\Length(max="255")
  81.      */
  82.     private $parsed_from;
  83.     /**
  84.      * @var string
  85.      * @Assert\NotBlank
  86.      * @Assert\Length(max="6")
  87.      */
  88.     private $quelle;
  89.     /**
  90.      * @var \DateTimeInterface|null
  91.      * @Assert\Type(\DateTimeInterface::class)
  92.      */
  93.     private $created_at;
  94.     /**
  95.      * @var \Doctrine\Common\Collections\Collection
  96.      */
  97.     private $aliases;
  98.     /**
  99.      * @var \JF\JuridicusBundle\Entity\Titel
  100.      */
  101.     private $titel;
  102.     /**
  103.      * @var string
  104.      */
  105.     private $titel_string;
  106.     /**
  107.      * @var \JF\JuridicusBundle\Entity\Dienststellung
  108.      */
  109.     private $dienststellung;
  110.     /**
  111.      * @var string
  112.      */
  113.     private $dienststellung_string;
  114.     /**
  115.      * @var \JF\JuridicusBundle\Entity\User
  116.      * @Assert\Valid
  117.      */
  118.     private $creator;
  119.     /**
  120.      * @var \JF\JuridicusBundle\Entity\Pruefer
  121.      * @Assert\Valid
  122.      */
  123.     private $alias_for;
  124.     /**
  125.      * @var integer
  126.      */
  127.     private $ordnr;
  128.     /**
  129.      * @var string
  130.      * @Assert\Length(max="64")
  131.      */
  132.     private $rechtsgebiete;
  133.     /**
  134.      * @var \DateTime
  135.      */
  136.     private $protokoll_datum;
  137.     /**
  138.      * @var \DateTime
  139.      */
  140.     private $appeared_first_at;
  141.     /**
  142.      * @var string
  143.      */
  144.     private $slug;
  145.     /**
  146.      * @var string
  147.      */
  148.     private $full_text null;
  149.     /**
  150.      * @var string
  151.      */
  152.     private $full_text_with_ort null;
  153.     /**
  154.      * @var boolean
  155.      */
  156.     private $pdf_need_update true;
  157.     /**
  158.      * @var integer
  159.      */
  160.     private $pdf_need_update_examen;
  161.     /**
  162.      * @var \Doctrine\Common\Collections\Collection
  163.      */
  164.     private $pruefer_pruefungen;
  165.     /**
  166.      * @var \Doctrine\Common\Collections\Collection
  167.      */
  168.     private $protokoll_infothek_pruefer;
  169.     /**
  170.      * @var \Doctrine\Common\Collections\Collection
  171.      */
  172.     private $protokoll_html;
  173.     /**
  174.      * @var \Doctrine\Common\Collections\Collection
  175.      */
  176.     private $emails;
  177.     /**
  178.      * @var \Doctrine\Common\Collections\Collection
  179.      */
  180.     private $downloads;
  181.     /**
  182.      * @var \Doctrine\Common\Collections\Collection
  183.      */
  184.     private $pruefungsaemter;
  185.     /**
  186.      * @var \Doctrine\Common\Collections\Collection
  187.      */
  188.     private $pdf_protokoll_juridicus;
  189.     /**
  190.      * @var \Doctrine\Common\Collections\Collection
  191.      */
  192.     private $pdf_protokollmappe_pruefer;
  193.    /**
  194.      * Constructor
  195.      */
  196.     public function __construct()
  197.     {
  198.         $this->aliases = new \Doctrine\Common\Collections\ArrayCollection();
  199.         $this->pruefer_pruefungen = new \Doctrine\Common\Collections\ArrayCollection();
  200.         $this->protokoll_infothek_pruefer = new \Doctrine\Common\Collections\ArrayCollection();
  201.         $this->protokoll_html = new \Doctrine\Common\Collections\ArrayCollection();
  202.         $this->emails = new \Doctrine\Common\Collections\ArrayCollection();
  203.         $this->downloads = new \Doctrine\Common\Collections\ArrayCollection();
  204.         $this->pruefungsaemter = new \Doctrine\Common\Collections\ArrayCollection();
  205.         $this->pdf_protokoll_juridicus = new \Doctrine\Common\Collections\ArrayCollection();
  206.         $this->pdf_protokollmappe_pruefer = new \Doctrine\Common\Collections\ArrayCollection();
  207.     }
  208.     /**
  209.      * Get id
  210.      *
  211.      * @return integer
  212.      */
  213.     public function getId()
  214.     {
  215.         return $this->id;
  216.     }
  217.     /**
  218.      * Set vorname
  219.      *
  220.      * @param string $vorname
  221.      * @return Pruefer
  222.      */
  223.     public function setVorname($vorname)
  224.     {
  225.         $this->vorname $vorname;
  226.         return $this;
  227.     }
  228.     /**
  229.      * Get vorname
  230.      *
  231.      * @return string
  232.      */
  233.     public function getVorname()
  234.     {
  235.         return $this->vorname;
  236.     }
  237.     /**
  238.      * Set nachname
  239.      *
  240.      * @param string $nachname
  241.      * @return Pruefer
  242.      */
  243.     public function setNachname($nachname)
  244.     {
  245.         $this->nachname $nachname;
  246.         return $this;
  247.     }
  248.     /**
  249.      * Get nachname
  250.      *
  251.      * @return string
  252.      */
  253.     public function getNachname()
  254.     {
  255.         return $this->nachname;
  256.     }
  257.     /**
  258.      * Set works_at
  259.      *
  260.      * @param string $worksAt
  261.      * @return Pruefer
  262.      */
  263.     public function setWorksAt($worksAt)
  264.     {
  265.         $this->works_at $worksAt;
  266.         return $this;
  267.     }
  268.     /**
  269.      * Get works_at
  270.      *
  271.      * @return string
  272.      */
  273.     public function getWorksAt()
  274.     {
  275.         return $this->works_at;
  276.     }
  277.     /**
  278.      * Set parsed_from
  279.      *
  280.      * @param string $parsedFrom
  281.      * @return Pruefer
  282.      */
  283.     public function setParsedFrom($parsedFrom)
  284.     {
  285.         $this->parsed_from $parsedFrom;
  286.         return $this;
  287.     }
  288.     /**
  289.      * Get parsed_from
  290.      *
  291.      * @return string
  292.      */
  293.     public function getParsedFrom()
  294.     {
  295.         return $this->parsed_from;
  296.     }
  297.     /**
  298.      * Set quelle
  299.      *
  300.      * @param string $quelle
  301.      * @return Pruefer
  302.      */
  303.     public function setQuelle($quelle)
  304.     {
  305.         $this->quelle $quelle;
  306.         return $this;
  307.     }
  308.     /**
  309.      * Get quelle
  310.      *
  311.      * @return string
  312.      */
  313.     public function getQuelle()
  314.     {
  315.         return $this->quelle;
  316.     }
  317.     /**
  318.      * Set created_at
  319.      *
  320.      * @param \DateTime $createdAt
  321.      * @return Pruefer
  322.      */
  323.     public function setCreatedAt($createdAt)
  324.     {
  325.         $this->created_at $createdAt;
  326.         return $this;
  327.     }
  328.     /**
  329.      * Get created_at
  330.      *
  331.      * @return \DateTime
  332.      */
  333.     public function getCreatedAt()
  334.     {
  335.         return $this->created_at;
  336.     }
  337.     /**
  338.      * @ORM\PrePersist
  339.      */
  340.     public function setCreatedAtValue()
  341.     {
  342.         if (!$this->init_mode AND !isset($this->created_at)) {
  343.             $this->setCreatedAt(new \DateTime());
  344.         }
  345.     }
  346.     /**
  347.      * Add aliase [INVERSE SIDE]
  348.      *
  349.      * @param \JF\JuridicusBundle\Entity\Pruefer $aliases
  350.      * @return Pruefer
  351.      */
  352.     public function addAliase(Pruefer $aliases)
  353.     {
  354.         $this->aliases[] = $aliases;
  355.         $aliases->setAliasFor($this);
  356.         return $this;
  357.     }
  358.     /**
  359.      * Remove aliases [INVERSE SIDE]
  360.      *
  361.      * @param \JF\JuridicusBundle\Entity\Pruefer $aliases
  362.      */
  363.     public function removeAliase(Pruefer $aliases)
  364.     {
  365.         $this->aliases->removeElement($aliases);
  366.         $aliases->setAliasFor(null);
  367.     }
  368.     /**
  369.      * Get aliases
  370.      *
  371.      * @return \Doctrine\Common\Collections\Collection
  372.      */
  373.     public function getAliases()
  374.     {
  375.         return $this->aliases;
  376.     }
  377.     /**
  378.      * Set titel [OWNING SIDE]
  379.      *
  380.      * @param \JF\JuridicusBundle\Entity\Titel $titel
  381.      * @return Pruefer
  382.      */
  383.     public function setTitel(Titel $titel null)
  384.     {
  385.         $this->titel $titel;
  386.         return $this;
  387.     }
  388.     /**
  389.      * Get titel
  390.      *
  391.      * @return \JF\JuridicusBundle\Entity\Titel
  392.      */
  393.     public function getTitel()
  394.     {
  395.         return $this->titel;
  396.     }
  397.      /**
  398.      * Set titelString
  399.      *
  400.      * @param string
  401.      * @return Pruefer
  402.      */
  403.     public function setTitelString($titelString)
  404.     {
  405.         $this->titel_string $titelString;
  406.         return $this;
  407.     }
  408.     /**
  409.      * Get titelString
  410.      *
  411.      * @return string
  412.      */
  413.     public function getTitelString()
  414.     {
  415.         return $this->titel_string;
  416.     }
  417.     /**
  418.      * Set creator [OWNING SIDE]
  419.      *
  420.      * @param \JF\JuridicusBundle\Entity\User $creator
  421.      * @return Pruefer
  422.      */
  423.     public function setCreator(User $creator null)
  424.     {
  425.         $this->creator $creator;
  426.         return $this;
  427.     }
  428.     /**
  429.      * Get creator
  430.      *
  431.      * @return \JF\JuridicusBundle\Entity\User
  432.      */
  433.     public function getCreator()
  434.     {
  435.         return $this->creator;
  436.     }
  437.     /**
  438.      * Set alias_for [OWNING SIDE]
  439.      *
  440.      * @param \JF\JuridicusBundle\Entity\Pruefer $aliasFor
  441.      * @return Pruefer
  442.      */
  443.     public function setAliasFor(Pruefer $aliasFor null)
  444.     {
  445.         $this->alias_for $aliasFor;
  446.         return $this;
  447.     }
  448.     /**
  449.      * Get alias_for
  450.      *
  451.      * @return \JF\JuridicusBundle\Entity\Pruefer
  452.      */
  453.     public function getAliasFor()
  454.     {
  455.         return $this->alias_for;
  456.     }
  457.     /**
  458.      * Set slug
  459.      *
  460.      * @param string $slug
  461.      * @return Pruefer
  462.      */
  463.     public function setSlug($slug)
  464.     {
  465.         $this->slug $slug;
  466.         return $this;
  467.     }
  468.     /**
  469.      * Get slug
  470.      *
  471.      * @return string
  472.      */
  473.     public function getSlug()
  474.     {
  475.         return $this->slug;
  476.     }
  477.     /**
  478.      * Add emails [INVERSE SIDE]
  479.      *
  480.      * @param \JF\JuridicusBundle\Entity\Email $emails
  481.      * @return Pruefer
  482.      */
  483.     public function addEmail(Email $emails)
  484.     {
  485.         $this->emails[] = $emails;
  486.         return $this;
  487.     }
  488.     /**
  489.      * Remove emails [INVERSE SIDE]
  490.      *
  491.      * @param \JF\JuridicusBundle\Entity\Email $emails
  492.      */
  493.     public function removeEmail(Email $emails)
  494.     {
  495.         $this->emails->removeElement($emails);
  496.     }
  497.     /**
  498.      * Get emails
  499.      *
  500.      * @return \Doctrine\Common\Collections\Collection
  501.      */
  502.     public function getEmails()
  503.     {
  504.         return $this->emails;
  505.     }
  506.     /**
  507.      * Add downloads [INVERSE SIDE]
  508.      *
  509.      * @param \JF\JuridicusBundle\Entity\Download $downloads
  510.      * @return Pruefer
  511.      */
  512.     public function addDownload(Download $downloads)
  513.     {
  514.         $this->downloads[] = $downloads;
  515.         return $this;
  516.     }
  517.     /**
  518.      * Remove downloads [INVERSE SIDE]
  519.      *
  520.      * @param \JF\JuridicusBundle\Entity\Download $downloads
  521.      */
  522.     public function removeDownload(Download $downloads)
  523.     {
  524.         $this->downloads->removeElement($downloads);
  525.     }
  526.     /**
  527.      * Get downloads
  528.      *
  529.      * @return \Doctrine\Common\Collections\Collection
  530.      */
  531.     public function getDownloads()
  532.     {
  533.         return $this->downloads;
  534.     }
  535.     /**
  536.      * Set rechtsgebiete
  537.      *
  538.      * @param string $rechtsgebiete
  539.      * @return Pruefer
  540.      */
  541.     public function setRechtsgebiete($rechtsgebiete)
  542.     {
  543.         $this->rechtsgebiete $rechtsgebiete;
  544.         return $this;
  545.     }
  546.     /**
  547.      * Get rechtsgebiete
  548.      *
  549.      * @return string
  550.      */
  551.     public function getRechtsgebiete()
  552.     {
  553.         return $this->rechtsgebiete;
  554.     }
  555.     /**
  556.      * Set appeared_first_at
  557.      *
  558.      * @param \DateTime $appearedFirstAt
  559.      * @return Pruefer
  560.      */
  561.     public function setAppearedFirstAt(\DateTime $appearedFirstAt)
  562.     {
  563.         $this->appeared_first_at $appearedFirstAt;
  564.         return $this;
  565.     }
  566.     /**
  567.      * Get appeared_first_at
  568.      *
  569.      * @return \DateTime
  570.      */
  571.     public function getAppearedFirstAt()
  572.     {
  573.         return $this->appeared_first_at;
  574.     }
  575.     /**
  576.      * Checks equality
  577.      *
  578.      * @param Pruefer
  579.      * @return boolean
  580.      */
  581.     public function equalsPruefer $p )
  582.     {
  583.         return TRUE
  584.             AND $this->vorname == $p->vorname
  585.             AND $this->nachname == $p->nachname
  586.             AND $this->adel == $p->adel
  587.             AND $this->titel->equals$p->titel )
  588.             AND $this->dienststellung->equals$p->dienststellung )
  589.         ;
  590.     }
  591.     /**
  592.      * Set adel
  593.      *
  594.      * @param string $adel
  595.      * @return Pruefer
  596.      */
  597.     public function setAdel($adel)
  598.     {
  599.         $this->adel $adel;
  600.         return $this;
  601.     }
  602.     /**
  603.      * Get adel
  604.      *
  605.      * @return string
  606.      */
  607.     public function getAdel()
  608.     {
  609.         return $this->adel;
  610.     }
  611.     /**
  612.      * Set ordnr
  613.      *
  614.      * @param integer $ordnr
  615.      * @return Pruefer
  616.      */
  617.     public function setOrdnr($ordnr)
  618.     {
  619.         $this->ordnr $ordnr;
  620.         return $this;
  621.     }
  622.     /**
  623.      * Get ordnr
  624.      *
  625.      * @return integer
  626.      */
  627.     public function getOrdnr()
  628.     {
  629.         return $this->ordnr;
  630.     }
  631.     /**
  632.      * Set protokoll_datum
  633.      *
  634.      * @param \DateTime $protokollDatum
  635.      * @return Pruefer
  636.      */
  637.     public function setProtokollDatum($protokollDatum)
  638.     {
  639.         $this->protokoll_datum $protokollDatum;
  640.         return $this;
  641.     }
  642.     /**
  643.      * Get protokoll_datum
  644.      *
  645.      * @return \DateTime
  646.      */
  647.     public function getProtokollDatum()
  648.     {
  649.         return $this->protokoll_datum;
  650.     }
  651.     /**
  652.      * Add pruefer_pruefungen [INVERSE SIDE]
  653.      *
  654.      * @param \JF\JuridicusBundle\Entity\PrueferPruefung $prueferPruefungen
  655.      * @return Pruefer
  656.      */
  657.     public function addPrueferPruefungen(PrueferPruefung $prueferPruefungen)
  658.     {
  659.         $this->pruefer_pruefungen[] = $prueferPruefungen;
  660.         return $this;
  661.     }
  662.     /**
  663.      * Remove pruefer_pruefungen [INVERSE SIDE]
  664.      *
  665.      * @param \JF\JuridicusBundle\Entity\PrueferPruefung $prueferPruefungen
  666.      */
  667.     public function removePrueferPruefungen(PrueferPruefung $prueferPruefungen)
  668.     {
  669.         $this->pruefer_pruefungen->removeElement($prueferPruefungen);
  670.     }
  671.     /**
  672.      * Get pruefer_pruefungen
  673.      *
  674.      * @return \Doctrine\Common\Collections\Collection
  675.      */
  676.     public function getPrueferPruefungen()
  677.     {
  678.         return $this->pruefer_pruefungen;
  679.     }
  680.     /**
  681.      * Add protokoll_infothek_pruefer [INVERSE SIDE]
  682.      *
  683.      * @param \JF\JuridicusBundle\Entity\ProtokollInfothekPruefer $protokollInfothekPruefer
  684.      * @return Pruefer
  685.      */
  686.     public function addProtokollInfothekPruefer(ProtokollInfothekPruefer $protokollInfothekPruefer)
  687.     {
  688.         $this->protokoll_infothek_pruefer[] = $protokollInfothekPruefer;
  689.         return $this;
  690.     }
  691.     /**
  692.      * Remove protokoll_infothek_pruefer [INVERSE SIDE]
  693.      *
  694.      * @param \JF\JuridicusBundle\Entity\ProtokollInfothekPruefer $protokollInfothekPruefer
  695.      */
  696.     public function removeProtokollInfothekPruefer(ProtokollInfothekPruefer $protokollInfothekPruefer)
  697.     {
  698.         $this->protokoll_infothek_pruefer->removeElement($protokollInfothekPruefer);
  699.     }
  700.     /**
  701.      * Get protokoll_infothek_pruefer
  702.      *
  703.      * @return \Doctrine\Common\Collections\Collection
  704.      */
  705.     public function getProtokollInfothekPruefer()
  706.     {
  707.         return $this->protokoll_infothek_pruefer;
  708.     }
  709.     /**
  710.      * Set dienststellung [OWNING SIDE]
  711.      *
  712.      * @param \JF\JuridicusBundle\Entity\Dienststellung $dienststellung
  713.      * @return Pruefer
  714.      */
  715.     public function setDienststellung(Dienststellung $dienststellung null)
  716.     {
  717.         $this->dienststellung $dienststellung;
  718.         return $this;
  719.     }
  720.     /**
  721.      * Get dienststellung
  722.      *
  723.      * @return \JF\JuridicusBundle\Entity\Dienststellung
  724.      */
  725.     public function getDienststellung()
  726.     {
  727.         return $this->dienststellung;
  728.     }
  729.     /**
  730.      * Set dienststellungString
  731.      *
  732.      * @param string $dienststellungString
  733.      * @return Pruefer
  734.      */
  735.     public function setDienststellungString($dienststellungString)
  736.     {
  737.         $this->dienststellung_string $dienststellungString;
  738.         return $this;
  739.     }
  740.     /**
  741.      * Get dienststellungString
  742.      *
  743.      * @return string
  744.      */
  745.     public function getDienststellungString()
  746.     {
  747.         return $this->dienststellung_string;
  748.     }
  749.     /**
  750.      * Add pruefungsaemter
  751.      *
  752.      * @param \JF\JuridicusBundle\Entity\Pruefungsamt $pruefungsaemter
  753.      * @return Pruefer
  754.      */
  755.     public function addPruefungsaemter(Pruefungsamt $pruefungsaemter)
  756.     {
  757.         $this->pruefungsaemter[] = $pruefungsaemter;
  758.         $pruefungsaemter->addPruefer($this);
  759.         return $this;
  760.     }
  761.     /**
  762.      * Remove pruefungsaemter
  763.      *
  764.      * @param \JF\JuridicusBundle\Entity\Pruefungsamt $pruefungsaemter
  765.      */
  766.     public function removePruefungsaemter(Pruefungsamt $pruefungsaemter)
  767.     {
  768.         $this->pruefungsaemter->removeElement($pruefungsaemter);
  769.         $pruefungsaemter->removePruefer($this);
  770.     }
  771.     /**
  772.      * Get pruefungsaemter
  773.      *
  774.      * @return \Doctrine\Common\Collections\Collection
  775.      */
  776.     public function getPruefungsaemter()
  777.     {
  778.         return $this->pruefungsaemter;
  779.     }
  780.     /**
  781.      * Add protokoll_html [INVERSE SIDE]
  782.      *
  783.      * @param \JF\JuridicusBundle\Entity\ProtokollHtml $protokollHtml
  784.      * @return Pruefer
  785.      */
  786.     public function addProtokollHtml(ProtokollHtml $protokollHtml)
  787.     {
  788.         $this->protokoll_html[] = $protokollHtml;
  789.         return $this;
  790.     }
  791.     /**
  792.      * Remove protokoll_html [INVERSE SIDE]
  793.      *
  794.      * @param \JF\JuridicusBundle\Entity\ProtokollHtml $protokollHtml
  795.      */
  796.     public function removeProtokollHtml(ProtokollHtml $protokollHtml)
  797.     {
  798.         $this->protokoll_html->removeElement($protokollHtml);
  799.     }
  800.     /**
  801.      * Get protokoll_html
  802.      *
  803.      * @return \Doctrine\Common\Collections\Collection
  804.      */
  805.     public function getProtokollHtml()
  806.     {
  807.         return $this->protokoll_html;
  808.     }
  809.     /**
  810.      * Add pdf_protokoll_juridicus [INVERSE SIDE]
  811.      *
  812.      * @param \JF\JuridicusBundle\Entity\PdfProtokollJuridicus $pdfProtokollJuridicus
  813.      * @return Pruefer
  814.      */
  815.     public function addPdfProtokollJuridicu(PdfProtokollJuridicus $pdfProtokollJuridicus)
  816.     {
  817.         $this->pdf_protokoll_juridicus[] = $pdfProtokollJuridicus;
  818.         return $this;
  819.     }
  820.     /**
  821.      * Remove pdf_protokoll_juridicus [INVERSE SIDE]
  822.      *
  823.      * @param \JF\JuridicusBundle\Entity\PdfProtokollJuridicus $pdfProtokollJuridicus
  824.      */
  825.     public function removePdfProtokollJuridicu(PdfProtokollJuridicus $pdfProtokollJuridicus)
  826.     {
  827.         $this->pdf_protokoll_juridicus->removeElement($pdfProtokollJuridicus);
  828.     }
  829.     /**
  830.      * Get pdf_protokoll_juridicus
  831.      *
  832.      * @return \Doctrine\Common\Collections\Collection
  833.      */
  834.     public function getPdfProtokollJuridicus()
  835.     {
  836.         return $this->pdf_protokoll_juridicus;
  837.     }
  838.     /**
  839.      * Add pdf_protokollmappe_pruefer [INVERSE SIDE]
  840.      *
  841.      * @param \JF\JuridicusBundle\Entity\PdfProtokollmappePruefer $pdfProtokollmappePruefer
  842.      * @return Pruefer
  843.      */
  844.     public function addPdfProtokollmappePruefer(PdfProtokollmappePruefer $pdfProtokollmappePruefer)
  845.     {
  846.         $this->pdf_protokollmappe_pruefer[] = $pdfProtokollmappePruefer;
  847.         return $this;
  848.     }
  849.     /**
  850.      * Remove pdf_protokollmappe_pruefer [INVERSE SIDE]
  851.      *
  852.      * @param \JF\JuridicusBundle\Entity\PdfProtokollmappePruefer $pdfProtokollmappePruefer
  853.      */
  854.     public function removePdfProtokollmappePruefer(PdfProtokollmappePruefer $pdfProtokollmappePruefer)
  855.     {
  856.         $this->pdf_protokollmappe_pruefer->removeElement($pdfProtokollmappePruefer);
  857.     }
  858.     /**
  859.      * Get pdf_protokollmappe_pruefer
  860.      *
  861.      * @return \Doctrine\Common\Collections\Collection
  862.      */
  863.     public function getPdfProtokollmappePruefer()
  864.     {
  865.         return $this->pdf_protokollmappe_pruefer;
  866.     }
  867.     /**
  868.      * Get different representations for SEO
  869.      * @return string[]
  870.      */
  871.     public function getSeoVariants()
  872.     {
  873.         $return = array();
  874.         if (empty($this->adel)) {
  875.             $return['adel_name'] = $this->nachname;
  876.         } else {
  877.             $return['adel_name'] = sprintf('%s %s'$this->adel$this->nachname);
  878.         }
  879.         if (empty($this->vorname)) {
  880.             $return['vorname_adel_name'] = $return['adel_name'];
  881.             $return['adel_name,_vorname'] = $return['adel_name'];
  882.         } else {
  883.             $return['vorname_adel_name'] = sprintf('%s %s'$this->vorname,
  884.                 $return['adel_name']);
  885.             $return['adel_name,_vorname'] = sprintf('%s, %s',
  886.                 $return['adel_name'], $this->vorname);
  887.         }
  888.         if (empty($this->titel)) {
  889.             $return['titel_vorname_adel_name'] = $return['vorname_adel_name'];
  890.         } else {
  891.             $return['titel_vorname_adel_name'] = sprintf('%s %s',
  892.                 $this->titel->getVisibleName(), $return['vorname_adel_name']);
  893.         }
  894.         if (empty($this->dienststellung)) {
  895.             $return['titel_vorname_adel_name,_dienststellung'] = $return['titel_vorname_adel_name'];
  896.             $return['titel_vorname_adel_name_dienststellung'] = $return['titel_vorname_adel_name'];
  897.         } else {
  898.             $return['titel_vorname_adel_name,_dienststellung'] = sprintf('%s, %s',
  899.                 $return['titel_vorname_adel_name'],
  900.                 $this->dienststellung->getVisibleName()
  901.             );
  902.             $return['titel_vorname_adel_name_dienststellung'] = sprintf('%s %s',
  903.                 $return['titel_vorname_adel_name'],
  904.                 $this->dienststellung->getVisibleName()
  905.             );
  906.         }
  907.         return $return;
  908.     }
  909.     /**
  910.      *
  911.      * @return string
  912.      */
  913.     public function getCssClass()
  914.     {
  915.         if ($this->getPdfProtokollJuridicus()->count() > 0) {
  916.             return 'protokoll';
  917.         } else {
  918.             return 'no-protokoll';
  919.         }
  920.     }
  921.     /**
  922.      *
  923.      * @return string
  924.      */
  925.     public function getFullText()
  926.     {
  927.         if (isset($this->full_text)) {
  928.             return $this->full_text;
  929.         }
  930.         $this->full_text '';
  931.         if (!empty($this->nachname)) {
  932.             $this->full_text .= $this->nachname;
  933.         }
  934.         $this->full_text $this->nachname;
  935.         if (!empty($this->vorname)) {
  936.             $this->full_text .= ', ' $this->vorname;
  937.             if (!empty($this->adel)) {
  938.                 $this->full_text .= ' ' $this->adel;
  939.             }
  940.         } else if (!empty($this->adel)) {
  941.             $this->full_text .= ', ' $this->adel;
  942.         }
  943.         if (isset($this->titel)) {
  944.             $this->full_text .= ', ' $this->titel->getVisibleName();
  945.         }
  946.         if (isset($this->dienststellung)) {
  947.             $this->full_text .= ', ' $this->dienststellung->getVisibleName();
  948.         }
  949.         return $this->full_text;
  950.     }
  951.     /**
  952.      *
  953.      * @return string
  954.      */
  955.     public function getFullTextWithOrt()
  956.     {
  957.         if (isset($this->full_text_with_ort)) {
  958.             return $this->full_text_with_ort;
  959.         }
  960.         $this->full_text_with_ort $this->nachname;
  961.         if (isset($this->adel)) {
  962.             $this->full_text_with_ort sprintf('%s %s'$this->adel$this->full_text_with_ort);
  963.         }
  964.         if (isset($this->vorname)) {
  965.             $this->full_text_with_ort sprintf('%s %s'$this->vorname$this->full_text_with_ort);
  966.         }
  967.         if (isset($this->titel)) {
  968.             $this->full_text_with_ort sprintf('%s %s'$this->titel->getVisibleName(), $this->full_text_with_ort);
  969.         }
  970.         if (isset($this->dienststellung)) {
  971.             $this->full_text_with_ort sprintf('%s %s'$this->dienststellung->getVisibleName(), $this->full_text_with_ort);
  972.         }
  973.         if (isset($this->works_at)) {
  974.             $this->full_text_with_ort sprintf('%s, %s'$this->full_text_with_ort$this->works_at);
  975.         }
  976.         return $this->full_text_with_ort;
  977.     }
  978.     /**
  979.      * getOldDyn - dynamisch erzeugter Link des alten Systems
  980.      *
  981.      * @return string
  982.      */
  983.     public function getOldDyn()
  984.     {
  985.         $href sprintf'%s_%s_%s_%s_%s_pruefer_protokolle_pruefung_jura_examen',
  986.             $this->getNachname(),
  987.             $this->getVorname() ? $this->getVorname() : '',
  988.             $this->getAdel() ? $this->getAdel() : '',
  989.             $this->getTitel() ? $this->getTitel()->getName() : '',
  990.             $this->getDienststellung() ? $this->getDienststellung()->getName() : ''
  991.         );
  992.         $remove = array('.',' ','´','`','\'');
  993.         return str_replace($remove'-'$href).'.php';
  994.     }
  995.      /**
  996.       * getProtokollCountForExamen
  997.       *
  998.       * @param integer examen
  999.       * @return integer
  1000.       */
  1001.       public function getProtokollCountForExamen($examen)
  1002.       {
  1003.           $alias $this->getAliasFor();
  1004.           if ($alias) {
  1005.               return $alias->getProtokollCountForExamen($examen);
  1006.           }
  1007.         foreach($this->getPdfProtokollmappePruefer() as $mappe)    {
  1008.             if ($mappe->getExamen() == $examen)    {
  1009.                 return $mappe->getAnzahlProtokolle();
  1010.             }
  1011.         }
  1012.         return 0;
  1013.       }
  1014.     /**
  1015.       * getProtokollCount
  1016.       *
  1017.       * @return array
  1018.       */
  1019.       public function getProtokollCount()
  1020.       {
  1021.           $alias $this->getAliasFor();
  1022.           if ($alias)    {
  1023.               return $alias->getProtokollCount();
  1024.           }
  1025.           $return = array('gesamt' => 0);
  1026.           foreach(Pruefung::getTypKeys() as $typ)     {
  1027.               $return[$typ] = 0;
  1028.           }
  1029.         foreach($this->getPdfProtokollmappePruefer() as $mappe)    {
  1030.             $return[$mappe->getExamen()] = $mappe->getAnzahlProtokolle();
  1031.             $return['gesamt'] += $mappe->getAnzahlProtokolle();
  1032.          }
  1033.         return $return;
  1034.       }
  1035.     /**
  1036.      * String Representation
  1037.      *
  1038.      * @return string
  1039.      */
  1040.     public function __toString()
  1041.     {
  1042.         $p $this->getFullText();
  1043.         return isset($p) ? $p 'Neuer Prüfer';
  1044.     }
  1045.     /**
  1046.      * Set pdf_need_update
  1047.      *
  1048.      * @param boolean $pdfNeedUpdate
  1049.      * @return Pruefer
  1050.      */
  1051.     public function setPdfNeedUpdate($pdfNeedUpdate)
  1052.     {
  1053.         $this->pdf_need_update $pdfNeedUpdate;
  1054.         return $this;
  1055.     }
  1056.     /**
  1057.      * Get pdf_need_update
  1058.      *
  1059.      * @return boolean
  1060.      */
  1061.     public function getPdfNeedUpdate()
  1062.     {
  1063.         return $this->pdf_need_update;
  1064.     }
  1065.     /**
  1066.      * Set pdf_need_update_examen
  1067.      *
  1068.      * @param integer $pdfNeedUpdateExamen
  1069.      * @return Pruefer
  1070.      */
  1071.     public function setPdfNeedUpdateExamen($pdfNeedUpdateExamen)
  1072.     {
  1073.         $this->pdf_need_update_examen $pdfNeedUpdateExamen;
  1074.         return $this;
  1075.     }
  1076.     /**
  1077.      * Get pdf_need_update_examen
  1078.      *
  1079.      * @return integer
  1080.      */
  1081.     public function getPdfNeedUpdateExamen()
  1082.     {
  1083.         return $this->pdf_need_update_examen;
  1084.     }
  1085.     
  1086.     // NEU 27.02.2023
  1087.     
  1088.     /**
  1089.      * Set email
  1090.      *
  1091.      * @param string $email
  1092.      * @return Pruefer
  1093.      */
  1094.     public function setEmail($email)
  1095.     {
  1096.         $this->email $email;
  1097.         return $this;
  1098.     }
  1099.     /**
  1100.      * Get email
  1101.      *
  1102.      * @return string
  1103.      */
  1104.     public function getEmail()
  1105.     {
  1106.         return $this->email;
  1107.     }
  1108.     
  1109.     /**
  1110.      * Set anschrift
  1111.      *
  1112.      * @param string $strasse
  1113.      * @return Pruefer
  1114.      */
  1115.     public function setAnschrift($anschrift)
  1116.     {
  1117.         $this->anschrift $anschrift;
  1118.         return $this;
  1119.     }
  1120.     /**
  1121.      * Get anschrift
  1122.      *
  1123.      * @return string
  1124.      */
  1125.     public function getAnschrift()
  1126.     {
  1127.         return $this->anschrift;
  1128.     }
  1129.     
  1130.     /**
  1131.      * Set strasse
  1132.      *
  1133.      * @param string $strasse
  1134.      * @return Pruefer
  1135.      */
  1136.     public function setStrasse($strasse)
  1137.     {
  1138.         $this->strasse $strasse;
  1139.         return $this;
  1140.     }
  1141.     /**
  1142.      * Get strasse
  1143.      *
  1144.      * @return string
  1145.      */
  1146.     public function getStrasse()
  1147.     {
  1148.         return $this->strasse;
  1149.     }
  1150.     
  1151.     /**
  1152.      * Set hausnummer
  1153.      *
  1154.      * @param string $hausnummer
  1155.      * @return Pruefer
  1156.      */
  1157.     public function setHausnummer($hausnummer)
  1158.     {
  1159.         $this->hausnummer $hausnummer;
  1160.         return $this;
  1161.     }
  1162.     /**
  1163.      * Get hausnummer
  1164.      *
  1165.      * @return string
  1166.      */
  1167.     public function getHausnummer()
  1168.     {
  1169.         return $this->hausnummer;
  1170.     }
  1171.     
  1172.     /**
  1173.      * Set ort
  1174.      *
  1175.      * @param string $ort
  1176.      * @return Kunde
  1177.      */
  1178.     public function setOrt($ort)
  1179.     {
  1180.         $this->ort $ort;
  1181.         return $this;
  1182.     }
  1183.     /**
  1184.      * Get ort
  1185.      *
  1186.      * @return string
  1187.      */
  1188.     public function getOrt()
  1189.     {
  1190.         return $this->ort;
  1191.     }
  1192.     
  1193.         /**
  1194.      * Set plz
  1195.      *
  1196.      * @param string $plz
  1197.      * @return Kunde
  1198.      */
  1199.     public function setPlz($plz)
  1200.     {
  1201.         $this->plz $plz;
  1202.         return $this;
  1203.     }
  1204.     /**
  1205.      * Get plz
  1206.      *
  1207.      * @return string
  1208.      */
  1209.     public function getPlz()
  1210.     {
  1211.         return $this->plz;
  1212.     }
  1213. }