Esempio n. 1
0
 /**
  * Method called to associate a ChildTemplates object to this object
  * through the ChildTemplates foreign key attribute.
  *
  * @param  ChildTemplates $l ChildTemplates
  * @return $this|\Templatenames The current object (for fluent API support)
  */
 public function addTemplates(ChildTemplates $l)
 {
     if ($this->collTemplatess === null) {
         $this->initTemplatess();
         $this->collTemplatessPartial = true;
     }
     if (!$this->collTemplatess->contains($l)) {
         $this->doAddTemplates($l);
         if ($this->templatessScheduledForDeletion and $this->templatessScheduledForDeletion->contains($l)) {
             $this->templatessScheduledForDeletion->remove($this->templatessScheduledForDeletion->search($l));
         }
     }
     return $this;
 }