/** * Filter the query by a related \GameLink object * * @param \GameLink|ObjectCollection $gameLink the related object to use as filter * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return ChildGameQuery The current query, for fluid interface */ public function filterByGameLink($gameLink, $comparison = null) { if ($gameLink instanceof \GameLink) { return $this->addUsingAlias(GameTableMap::COL_ID, $gameLink->getGameId(), $comparison); } elseif ($gameLink instanceof ObjectCollection) { return $this->useGameLinkQuery()->filterByPrimaryKeys($gameLink->getPrimaryKeys())->endUse(); } else { throw new PropelException('filterByGameLink() only accepts arguments of type \\GameLink or Collection'); } }