/** * Exclude object from result * * @param ChildVehicle $vehicle Object to remove from the list of results * * @return $this|ChildVehicleQuery The current query, for fluid interface */ public function prune($vehicle = null) { if ($vehicle) { $this->addUsingAlias(VehicleTableMap::COL_ID, $vehicle->getId(), Criteria::NOT_EQUAL); } return $this; }
/** * @param ChildVehicle $vehicle The ChildVehicle object to add. */ protected function doAddVehicle(ChildVehicle $vehicle) { $this->collVehicles[] = $vehicle; $vehicle->setMake($this); }
/** * Filter the query by a related \Anand\Vehicle object * * @param \Anand\Vehicle|ObjectCollection $vehicle the related object to use as filter * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return ChildMakeQuery The current query, for fluid interface */ public function filterByVehicle($vehicle, $comparison = null) { if ($vehicle instanceof \Anand\Vehicle) { return $this->addUsingAlias(MakeTableMap::COL_ID, $vehicle->getMakeId(), $comparison); } elseif ($vehicle instanceof ObjectCollection) { return $this->useVehicleQuery()->filterByPrimaryKeys($vehicle->getPrimaryKeys())->endUse(); } else { throw new PropelException('filterByVehicle() only accepts arguments of type \\Anand\\Vehicle or Collection'); } }