Ejemplo n.º 1
0
 /**
  * Filter the query by a related \gossi\trixionary\model\Position object
  *
  * @param \gossi\trixionary\model\Position|ObjectCollection $position The related object(s) to use as filter
  * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
  *
  * @throws \Propel\Runtime\Exception\PropelException
  *
  * @return ChildSkillQuery The current query, for fluid interface
  */
 public function filterByEndPosition($position, $comparison = null)
 {
     if ($position instanceof \gossi\trixionary\model\Position) {
         return $this->addUsingAlias(SkillTableMap::COL_END_POSITION_ID, $position->getId(), $comparison);
     } elseif ($position instanceof ObjectCollection) {
         if (null === $comparison) {
             $comparison = Criteria::IN;
         }
         return $this->addUsingAlias(SkillTableMap::COL_END_POSITION_ID, $position->toKeyValue('PrimaryKey', 'Id'), $comparison);
     } else {
         throw new PropelException('filterByEndPosition() only accepts arguments of type \\gossi\\trixionary\\model\\Position or Collection');
     }
 }
Ejemplo n.º 2
0
 /**
  * Exclude object from result
  *
  * @param   ChildPosition $position Object to remove from the list of results
  *
  * @return $this|ChildPositionQuery The current query, for fluid interface
  */
 public function prune($position = null)
 {
     if ($position) {
         $this->addUsingAlias(PositionTableMap::COL_ID, $position->getId(), Criteria::NOT_EQUAL);
     }
     return $this;
 }