src/model/Base/Skill.php
public function getSkillGroups(Criteria $criteria = null, ConnectionInterface $con = null)
    {
        $partial = $this->collSkillGroupsPartial && !$this->isNew();
        if (null === $this->collSkillGroups || null !== $criteria  || $partial) {
            if ($this->isNew() && null === $this->collSkillGroups) {
                // return empty collection
                $this->initSkillGroups();
            } else {
                $collSkillGroups = ChildSkillGroupQuery::create(null, $criteria)
                    ->filterBySkill($this)
                    ->find($con);

                if (null !== $criteria) {
                    if (false !== $this->collSkillGroupsPartial && count($collSkillGroups)) {
                        $this->initSkillGroups(false);

                        foreach ($collSkillGroups as $obj) {
                            if (false == $this->collSkillGroups->contains($obj)) {
                                $this->collSkillGroups->append($obj);
                            }
                        }

                        $this->collSkillGroupsPartial = true;
                    }

                    return $collSkillGroups;
                }

                if ($partial && $this->collSkillGroups) {
                    foreach ($this->collSkillGroups as $obj) {
                        if ($obj->isNew()) {
                            $collSkillGroups[] = $obj;
                        }
                    }
                }

                $this->collSkillGroups = $collSkillGroups;
                $this->collSkillGroupsPartial = false;
            }
        }

        return $this->collSkillGroups;
    }
public function getSkillGroups(Criteria $criteria = null, ConnectionInterface $con = null)
    {
        $partial = $this->collSkillGroupsPartial && !$this->isNew();
        if (null === $this->collSkillGroups || null !== $criteria  || $partial) {
            if ($this->isNew() && null === $this->collSkillGroups) {
                // return empty collection
                $this->initSkillGroups();
            } else {
                $collSkillGroups = ChildSkillGroupQuery::create(null, $criteria)
                    ->filterBySkill($this)
                    ->find($con);

                if (null !== $criteria) {
                    if (false !== $this->collSkillGroupsPartial && count($collSkillGroups)) {
                        $this->initSkillGroups(false);

                        foreach ($collSkillGroups as $obj) {
                            if (false == $this->collSkillGroups->contains($obj)) {
                                $this->collSkillGroups->append($obj);
                            }
                        }

                        $this->collSkillGroupsPartial = true;
                    }

                    return $collSkillGroups;
                }

                if ($partial && $this->collSkillGroups) {
                    foreach ($this->collSkillGroups as $obj) {
                        if ($obj->isNew()) {
                            $collSkillGroups[] = $obj;
                        }
                    }
                }

                $this->collSkillGroups = $collSkillGroups;
                $this->collSkillGroupsPartial = false;
            }
        }

        return $this->collSkillGroups;
    }
public function getSkillGroups ( Criteria $ criteria = null , ConnectionInterface $ con = null ) { $ partial = $ this -> collSkillGroupsPartial && ! $ this -> isNew ( ) ; if ( null === $ this -> collSkillGroups || null !== $ criteria || $ partial ) { if ( $ this -> isNew ( ) && null === $ this -> collSkillGroups ) { // return empty collection $ this -> initSkillGroups ( ) ; } else { $ collSkillGroups = ChildSkillGroupQuery :: create ( null , $ criteria ) -> filterBySkill ( $ this ) -> find ( $ con ) ; if ( null !== $ criteria ) { if ( false !== $ this -> collSkillGroupsPartial && count ( $ collSkillGroups ) ) { $ this -> initSkillGroups ( false ) ; foreach ( $ collSkillGroups as $ obj ) { if ( false == $ this -> collSkillGroups -> contains ( $ obj ) ) { $ this -> collSkillGroups -> append ( $ obj ) ; } } $ this -> collSkillGroupsPartial = true ; } return $ collSkillGroups ; } if ( $ partial && $ this -> collSkillGroups ) { foreach ( $ this -> collSkillGroups as $ obj ) { if ( $ obj -> isNew ( ) ) { $ collSkillGroups [ ] = $ obj ; } } } $ this -> collSkillGroups = $ collSkillGroups ; $ this -> collSkillGroupsPartial = false ; } } return $ this -> collSkillGroups ; }
Gets an array of ChildSkillGroup objects which contain a foreign key that references this object.

If the $criteria is not null, it is used to always fetch the results from the database.
Otherwise the results are fetched from the database the first time, then cached.
Next time the same method is called without $criteria, the cached collection is returned.
If this ChildSkill is new, it will return
an empty collection or the current collection; the criteria is ignored on a new object.

@param      Criteria $criteria optional Criteria object to narrow the query
@param      ConnectionInterface $con optional connection object
@return ObjectCollection|ChildSkillGroup[] List of ChildSkillGroup objects
@throws PropelException
Gets an array of ChildSkillGroup objects which contain a foreign key that references this object .