/** * Clears the current object, sets all attributes to their default values and removes * outgoing references as well as back-references (from other objects to this one. Results probably in a database * change of those foreign objects when you call `save` there). */ public function clear() { if (null !== $this->aResourceType) { $this->aResourceType->removeResourceTypeI18n($this); } $this->resource_type_id = null; $this->locale = null; $this->resource_type_name = null; $this->alreadyInSave = false; $this->clearAllReferences(); $this->applyDefaultValues(); $this->resetModified(); $this->setNew(true); $this->setDeleted(false); }
/** * Filter the query by a related \App\Propel\ResourceType object * * @param \App\Propel\ResourceType|ObjectCollection $resourceType 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 ChildResourceTypeI18nQuery The current query, for fluid interface */ public function filterByResourceType($resourceType, $comparison = null) { if ($resourceType instanceof \App\Propel\ResourceType) { return $this->addUsingAlias(ResourceTypeI18nTableMap::COL_RESOURCE_TYPE_ID, $resourceType->getResourceTypeId(), $comparison); } elseif ($resourceType instanceof ObjectCollection) { if (null === $comparison) { $comparison = Criteria::IN; } return $this->addUsingAlias(ResourceTypeI18nTableMap::COL_RESOURCE_TYPE_ID, $resourceType->toKeyValue('PrimaryKey', 'ResourceTypeId'), $comparison); } else { throw new PropelException('filterByResourceType() only accepts arguments of type \\App\\Propel\\ResourceType or Collection'); } }
/** * Exclude object from result * * @param ChildResourceType $resourceType Object to remove from the list of results * * @return $this|ChildResourceTypeQuery The current query, for fluid interface */ public function prune($resourceType = null) { if ($resourceType) { $this->addUsingAlias(ResourceTypeTableMap::COL_RESOURCE_TYPE_ID, $resourceType->getResourceTypeId(), Criteria::NOT_EQUAL); } return $this; }