/** * Filter the query by a related \keeko\core\model\Action object * * @param \keeko\core\model\Action|ObjectCollection $action 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 ChildApiQuery The current query, for fluid interface */ public function filterByAction($action, $comparison = null) { if ($action instanceof \keeko\core\model\Action) { return $this->addUsingAlias(ApiTableMap::COL_ACTION_ID, $action->getId(), $comparison); } elseif ($action instanceof ObjectCollection) { if (null === $comparison) { $comparison = Criteria::IN; } return $this->addUsingAlias(ApiTableMap::COL_ACTION_ID, $action->toKeyValue('PrimaryKey', 'Id'), $comparison); } else { throw new PropelException('filterByAction() only accepts arguments of type \\keeko\\core\\model\\Action or Collection'); } }