/** * Declares an association between this object and a ChildCompanies object. * * @param ChildCompanies $v * @return $this|\Games The current object (for fluent API support) * @throws PropelException */ public function setCompaniesRelatedByDeveloperId(ChildCompanies $v = null) { if ($v === null) { $this->setDeveloperId(NULL); } else { $this->setDeveloperId($v->getId()); } $this->aCompaniesRelatedByDeveloperId = $v; // Add binding for other direction of this n:n relationship. // If this object has already been added to the ChildCompanies object, it will not be re-added. if ($v !== null) { $v->addGamesRelatedByDeveloperId($this); } return $this; }
/** * Filter the query by a related \Companies object * * @param \Companies|ObjectCollection $companies 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 ChildGamesQuery The current query, for fluid interface */ public function filterByCompaniesRelatedByDeveloperId($companies, $comparison = null) { if ($companies instanceof \Companies) { return $this->addUsingAlias(GamesTableMap::COL_DEVELOPER_ID, $companies->getId(), $comparison); } elseif ($companies instanceof ObjectCollection) { if (null === $comparison) { $comparison = Criteria::IN; } return $this->addUsingAlias(GamesTableMap::COL_DEVELOPER_ID, $companies->toKeyValue('PrimaryKey', 'Id'), $comparison); } else { throw new PropelException('filterByCompaniesRelatedByDeveloperId() only accepts arguments of type \\Companies or Collection'); } }
/** * Exclude object from result * * @param ChildCompanies $companies Object to remove from the list of results * * @return $this|ChildCompaniesQuery The current query, for fluid interface */ public function prune($companies = null) { if ($companies) { $this->addUsingAlias(CompaniesTableMap::COL_ID, $companies->getId(), Criteria::NOT_EQUAL); } return $this; }