コード例 #1
0
ファイル: Objective.php プロジェクト: stopfstedt/ilios
 /**
  * @param ObjectiveInterface $child
  */
 public function removeChild(ObjectiveInterface $child)
 {
     $this->children->removeElement($child);
 }
コード例 #2
0
ファイル: Course.php プロジェクト: stopfstedt/ilios
 /**
  * When and objective is remove from a course it needs to remove any relationships
  * to children that belong to sessions in that course
  */
 public function removeObjective(ObjectiveInterface $objective)
 {
     if ($this->objectives->contains($objective)) {
         $this->objectives->removeElement($objective);
         $objective->removeCourse($this);
         foreach ($this->getSessions() as $session) {
             foreach ($session->getObjectives() as $sessionObjective) {
                 $sessionObjective->removeParent($objective);
             }
         }
     }
 }
コード例 #3
0
ファイル: MeshDescriptor.php プロジェクト: stopfstedt/ilios
 /**
  * @inheritdoc
  */
 public function removeObjective(ObjectiveInterface $objective)
 {
     if ($this->objectives->contains($objective)) {
         $this->objectives->removeElement($objective);
         $objective->removeMeshDescriptor($this);
     }
 }