/** * Filter the query by a related \Models\Shared object * * @param \Models\Shared|ObjectCollection $shared the related object to use as filter * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return ChildCategoryQuery The current query, for fluid interface */ public function filterByShared($shared, $comparison = null) { if ($shared instanceof \Models\Shared) { return $this->where("'category' = ?", $shared->getWhatType(), 2)->addUsingAlias(CategoryTableMap::COL_ID, $shared->getWhatId(), $comparison); } else { throw new PropelException('filterByShared() only accepts arguments of type \\Models\\Shared'); } }
/** * @param ChildShared $shared The ChildShared object to add. */ protected function doAddShared(ChildShared $shared) { $this->collShareds[] = $shared; $shared->setNote($this); }
/** * Exclude object from result * * @param ChildShared $shared Object to remove from the list of results * * @return $this|ChildSharedQuery The current query, for fluid interface */ public function prune($shared = null) { if ($shared) { $this->addUsingAlias(SharedTableMap::COL_ID, $shared->getId(), Criteria::NOT_EQUAL); } return $this; }