示例#1
0
 /**
  * Filter the query by a related \iuf\junia\model\Judge object
  *
  * @param \iuf\junia\model\Judge|ObjectCollection $judge 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 ChildPerformanceScoreQuery The current query, for fluid interface
  */
 public function filterByJudge($judge, $comparison = null)
 {
     if ($judge instanceof \iuf\junia\model\Judge) {
         return $this->addUsingAlias(PerformanceScoreTableMap::COL_JUDGE_ID, $judge->getId(), $comparison);
     } elseif ($judge instanceof ObjectCollection) {
         if (null === $comparison) {
             $comparison = Criteria::IN;
         }
         return $this->addUsingAlias(PerformanceScoreTableMap::COL_JUDGE_ID, $judge->toKeyValue('PrimaryKey', 'Id'), $comparison);
     } else {
         throw new PropelException('filterByJudge() only accepts arguments of type \\iuf\\junia\\model\\Judge or Collection');
     }
 }
示例#2
0
文件: JudgeQuery.php 项目: iuf/junia
 /**
  * Exclude object from result
  *
  * @param   ChildJudge $judge Object to remove from the list of results
  *
  * @return $this|ChildJudgeQuery The current query, for fluid interface
  */
 public function prune($judge = null)
 {
     if ($judge) {
         $this->addUsingAlias(JudgeTableMap::COL_ID, $judge->getId(), Criteria::NOT_EQUAL);
     }
     return $this;
 }
示例#3
0
 /**
  * Declares an association between this object and a ChildJudge object.
  *
  * @param  ChildJudge $v
  * @return $this|\iuf\junia\model\PerformanceScore The current object (for fluent API support)
  * @throws PropelException
  */
 public function setJudge(ChildJudge $v = null)
 {
     if ($v === null) {
         $this->setJudgeId(NULL);
     } else {
         $this->setJudgeId($v->getId());
     }
     $this->aJudge = $v;
     // Add binding for other direction of this n:n relationship.
     // If this object has already been added to the ChildJudge object, it will not be re-added.
     if ($v !== null) {
         $v->addPerformanceScore($this);
     }
     return $this;
 }