Beispiel #1
0
	/**
	 * Exclude object from result
	 *
	 * @param     PeriodeNote $periodeNote Object to remove from the list of results
	 *
	 * @return    PeriodeNoteQuery The current query, for fluid interface
	 */
	public function prune($periodeNote = null)
	{
		if ($periodeNote) {
			$this->addCond('pruneCond0', $this->getAliasedColName(PeriodeNotePeer::NUM_PERIODE), $periodeNote->getNumPeriode(), Criteria::NOT_EQUAL);
			$this->addCond('pruneCond1', $this->getAliasedColName(PeriodeNotePeer::ID_CLASSE), $periodeNote->getIdClasse(), Criteria::NOT_EQUAL);
			$this->combine(array('pruneCond0', 'pruneCond1'), Criteria::LOGICAL_OR);
		}

		return $this;
	}
Beispiel #2
0
	/**
	 * Filter the query by a related PeriodeNote object
	 *
	 * @param     PeriodeNote $periodeNote  the related object to use as filter
	 * @param     string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
	 *
	 * @return    ClasseQuery The current query, for fluid interface
	 */
	public function filterByPeriodeNote($periodeNote, $comparison = null)
	{
		if ($periodeNote instanceof PeriodeNote) {
			return $this
				->addUsingAlias(ClassePeer::ID, $periodeNote->getIdClasse(), $comparison);
		} elseif ($periodeNote instanceof PropelCollection) {
			return $this
				->usePeriodeNoteQuery()
				->filterByPrimaryKeys($periodeNote->getPrimaryKeys())
				->endUse();
		} else {
			throw new PropelException('filterByPeriodeNote() only accepts arguments of type PeriodeNote or PropelCollection');
		}
	}