/** * Exclude object from result * * @param ChildCategoryDocument $categoryDocument Object to remove from the list of results * * @return ChildCategoryDocumentQuery The current query, for fluid interface */ public function prune($categoryDocument = null) { if ($categoryDocument) { $this->addUsingAlias(CategoryDocumentTableMap::ID, $categoryDocument->getId(), Criteria::NOT_EQUAL); } return $this; }
/** * Declares an association between this object and a ChildCategoryDocument object. * * @param ChildCategoryDocument $v * @return \Thelia\Model\CategoryDocumentI18n The current object (for fluent API support) * @throws PropelException */ public function setCategoryDocument(ChildCategoryDocument $v = null) { if ($v === null) { $this->setId(NULL); } else { $this->setId($v->getId()); } $this->aCategoryDocument = $v; // Add binding for other direction of this n:n relationship. // If this object has already been added to the ChildCategoryDocument object, it will not be re-added. if ($v !== null) { $v->addCategoryDocumentI18n($this); } return $this; }
/** * Filter the query by a related \Thelia\Model\CategoryDocument object * * @param \Thelia\Model\CategoryDocument|ObjectCollection $categoryDocument The related object(s) to use as filter * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return ChildCategoryDocumentI18nQuery The current query, for fluid interface */ public function filterByCategoryDocument($categoryDocument, $comparison = null) { if ($categoryDocument instanceof \Thelia\Model\CategoryDocument) { return $this->addUsingAlias(CategoryDocumentI18nTableMap::ID, $categoryDocument->getId(), $comparison); } elseif ($categoryDocument instanceof ObjectCollection) { if (null === $comparison) { $comparison = Criteria::IN; } return $this->addUsingAlias(CategoryDocumentI18nTableMap::ID, $categoryDocument->toKeyValue('PrimaryKey', 'Id'), $comparison); } else { throw new PropelException('filterByCategoryDocument() only accepts arguments of type \\Thelia\\Model\\CategoryDocument or Collection'); } }
/** * Filter the query by a related \Thelia\Model\CategoryDocument object * * @param \Thelia\Model\CategoryDocument|ObjectCollection $categoryDocument 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 filterByCategoryDocument($categoryDocument, $comparison = null) { if ($categoryDocument instanceof \Thelia\Model\CategoryDocument) { return $this->addUsingAlias(CategoryTableMap::ID, $categoryDocument->getCategoryId(), $comparison); } elseif ($categoryDocument instanceof ObjectCollection) { return $this->useCategoryDocumentQuery()->filterByPrimaryKeys($categoryDocument->getPrimaryKeys())->endUse(); } else { throw new PropelException('filterByCategoryDocument() only accepts arguments of type \\Thelia\\Model\\CategoryDocument or Collection'); } }
protected function getMediaModelInstance($t2_object_id) { $obj = new CategoryDocument(); return $obj->setCategoryId($t2_object_id); }