/** * Declares an association between this object and a ChildGroupPersonType object. * * @param ChildGroupPersonType $v * @return $this|\ECP\GroupEvePerson The current object (for fluent API support) * @throws PropelException */ public function setGroupPersonType(ChildGroupPersonType $v = null) { if ($v === null) { $this->setGrouppersontypeid(NULL); } else { $this->setGrouppersontypeid($v->getId()); } $this->aGroupPersonType = $v; // Add binding for other direction of this n:n relationship. // If this object has already been added to the ChildGroupPersonType object, it will not be re-added. if ($v !== null) { $v->addGroupEvePerson($this); } return $this; }
/** * Filter the query by a related \ECP\GroupPersonType object * * @param \ECP\GroupPersonType|ObjectCollection $groupPersonType 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 ChildGroupPersonQuery The current query, for fluid interface */ public function filterByGroupPersonType($groupPersonType, $comparison = null) { if ($groupPersonType instanceof \ECP\GroupPersonType) { return $this->addUsingAlias(GroupPersonTableMap::COL_GROUPPERSONTYPEID, $groupPersonType->getId(), $comparison); } elseif ($groupPersonType instanceof ObjectCollection) { if (null === $comparison) { $comparison = Criteria::IN; } return $this->addUsingAlias(GroupPersonTableMap::COL_GROUPPERSONTYPEID, $groupPersonType->toKeyValue('PrimaryKey', 'Id'), $comparison); } else { throw new PropelException('filterByGroupPersonType() only accepts arguments of type \\ECP\\GroupPersonType or Collection'); } }
/** * Exclude object from result * * @param ChildGroupPersonType $groupPersonType Object to remove from the list of results * * @return $this|ChildGroupPersonTypeQuery The current query, for fluid interface */ public function prune($groupPersonType = null) { if ($groupPersonType) { $this->addUsingAlias(GroupPersonTypeTableMap::COL_ID, $groupPersonType->getId(), Criteria::NOT_EQUAL); } return $this; }