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