Esempio n. 1
0
 /**
  * Add feature
  * 
  * @param VIB\Bundle\BioBundle\Entity\DNA\Abstracts\Feature $feature
  * @param boolean $recurse 
  */
 public function addFeature(Feature $feature, $recurse = true)
 {
     $this->features[] = $feature;
     if ($recurse === true) {
         $feature->setSequence($this, false);
     }
 }
Esempio n. 2
0
 /**
  * Set feature
  * 
  * @param VIB\Bundle\BioBundle\Entity\DNA\Abstracts\Feature $feature 
  * @param boolean $recurse 
  */
 public function setFeature(Feature $feature, $recurse = true)
 {
     if ($recurse === true) {
         if ($feature != null) {
             $feature->addAlias($this, false);
         } elseif ($this->feature != null) {
             $this->feature->removeAlias($this, false);
         }
     }
     $this->feature = $feature;
 }
Esempio n. 3
0
 /**
  * Add child
  * 
  * @param VIB\Bundle\BioBundle\Entity\DNA\Abstracts\Feature $child 
  * @param boolean $recurse 
  */
 public function addChild(Feature $child, $recurse = true)
 {
     $this->children[] = $child;
     if ($recurse === true) {
         $child->addParent($this, false);
     }
 }