Example #1
0
 /**
  * Filter the query by a related \Haus23\Dtp\Model\Ruleset object
  *
  * @param \Haus23\Dtp\Model\Ruleset|ObjectCollection $ruleset 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 ChildChampionshipQuery The current query, for fluid interface
  */
 public function filterByRuleset($ruleset, $comparison = null)
 {
     if ($ruleset instanceof \Haus23\Dtp\Model\Ruleset) {
         return $this->addUsingAlias(ChampionshipTableMap::COL_RULESET_ID, $ruleset->getId(), $comparison);
     } elseif ($ruleset instanceof ObjectCollection) {
         if (null === $comparison) {
             $comparison = Criteria::IN;
         }
         return $this->addUsingAlias(ChampionshipTableMap::COL_RULESET_ID, $ruleset->toKeyValue('PrimaryKey', 'Id'), $comparison);
     } else {
         throw new PropelException('filterByRuleset() only accepts arguments of type \\Haus23\\Dtp\\Model\\Ruleset or Collection');
     }
 }
Example #2
0
 /**
  * Exclude object from result
  *
  * @param   ChildRuleset $ruleset Object to remove from the list of results
  *
  * @return $this|ChildRulesetQuery The current query, for fluid interface
  */
 public function prune($ruleset = null)
 {
     if ($ruleset) {
         $this->addUsingAlias(RulesetTableMap::COL_ID, $ruleset->getId(), Criteria::NOT_EQUAL);
     }
     return $this;
 }
Example #3
0
 /**
  * Clears the current object, sets all attributes to their default values and removes
  * outgoing references as well as back-references (from other objects to this one. Results probably in a database
  * change of those foreign objects when you call `save` there).
  */
 public function clear()
 {
     if (null !== $this->aRuleset) {
         $this->aRuleset->removeChampionship($this);
     }
     $this->id = null;
     $this->name = null;
     $this->shortname = null;
     $this->start_date = null;
     $this->published = null;
     $this->completed = null;
     $this->ruleset_id = null;
     $this->alreadyInSave = false;
     $this->clearAllReferences();
     $this->applyDefaultValues();
     $this->resetModified();
     $this->setNew(true);
     $this->setDeleted(false);
 }