/** * Filter the query by a related \ECP\CompositionRow object * * @param \ECP\CompositionRow|ObjectCollection $compositionRow 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 ChildFitEntryQuery The current query, for fluid interface */ public function filterByCompositionRow($compositionRow, $comparison = null) { if ($compositionRow instanceof \ECP\CompositionRow) { return $this->addUsingAlias(FitEntryTableMap::COL_COMPOSITIONROWID, $compositionRow->getId(), $comparison); } elseif ($compositionRow instanceof ObjectCollection) { if (null === $comparison) { $comparison = Criteria::IN; } return $this->addUsingAlias(FitEntryTableMap::COL_COMPOSITIONROWID, $compositionRow->toKeyValue('PrimaryKey', 'Id'), $comparison); } else { throw new PropelException('filterByCompositionRow() only accepts arguments of type \\ECP\\CompositionRow or Collection'); } }
/** * @param ChildCompositionRow $compositionRow The ChildCompositionRow object to add. */ protected function doAddCompositionRow(ChildCompositionRow $compositionRow) { $this->collCompositionRows[] = $compositionRow; $compositionRow->setCompositionEntity($this); }
/** * Filter the query by a related \ECP\CompositionRow object * * @param \ECP\CompositionRow|ObjectCollection $compositionRow the related object to use as filter * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return ChildCompositionEntityQuery The current query, for fluid interface */ public function filterByCompositionRow($compositionRow, $comparison = null) { if ($compositionRow instanceof \ECP\CompositionRow) { return $this->addUsingAlias(CompositionEntityTableMap::COL_ID, $compositionRow->getCompositionentityid(), $comparison); } elseif ($compositionRow instanceof ObjectCollection) { return $this->useCompositionRowQuery()->filterByPrimaryKeys($compositionRow->getPrimaryKeys())->endUse(); } else { throw new PropelException('filterByCompositionRow() only accepts arguments of type \\ECP\\CompositionRow or Collection'); } }
/** * Exclude object from result * * @param ChildCompositionRow $compositionRow Object to remove from the list of results * * @return $this|ChildCompositionRowQuery The current query, for fluid interface */ public function prune($compositionRow = null) { if ($compositionRow) { $this->addUsingAlias(CompositionRowTableMap::COL_ID, $compositionRow->getId(), Criteria::NOT_EQUAL); } return $this; }
/** * 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->aCompositionRow) { $this->aCompositionRow->removeFitEntry($this); } if (null !== $this->aFitEntryType) { $this->aFitEntryType->removeFitEntry($this); } $this->id = null; $this->compositionrowid = null; $this->ind3x = null; $this->fitentrytypeid = null; $this->itemid = null; $this->ammoid = null; $this->amount = null; $this->alreadyInSave = false; $this->clearAllReferences(); $this->resetModified(); $this->setNew(true); $this->setDeleted(false); }