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