Ejemplo n.º 1
0
	/**
	 * Filter the query by a related ResponsableEleve object
	 *
	 * @param     ResponsableEleve $responsableEleve  the related object to use as filter
	 * @param     string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
	 *
	 * @return    AdresseQuery The current query, for fluid interface
	 */
	public function filterByResponsableEleve($responsableEleve, $comparison = null)
	{
		if ($responsableEleve instanceof ResponsableEleve) {
			return $this
				->addUsingAlias(AdressePeer::ADR_ID, $responsableEleve->getAdresseId(), $comparison);
		} elseif ($responsableEleve instanceof PropelCollection) {
			return $this
				->useResponsableEleveQuery()
				->filterByPrimaryKeys($responsableEleve->getPrimaryKeys())
				->endUse();
		} else {
			throw new PropelException('filterByResponsableEleve() only accepts arguments of type ResponsableEleve or PropelCollection');
		}
	}