PHP Class Nextras\Orm\Repository\PersistenceHelper

Show file Open project: nextras/orm Class Usage Examples

Protected Properties

Property Type Description
$inputQueue array
$outputQueue array

Public Methods

Method Description
getCascadeQueue ( Nextras\Orm\Entity\IEntity $entity, Nextras\Orm\Model\IModel $model, boolean $withCascade ) : array

Protected Methods

Method Description
addRelationshipToQueue ( Nextras\Orm\Entity\IEntity $entity, PropertyMetadata $propertyMeta, Nextras\Orm\Model\IModel $model )
visitEntity ( Nextras\Orm\Entity\IEntity $entity, Nextras\Orm\Model\IModel $model, $withCascade = true )
visitRelationship ( Nextras\Orm\Relationships\IRelationshipCollection $rel, Nextras\Orm\Model\IModel $model )

Method Details

addRelationshipToQueue() protected static method

protected static addRelationshipToQueue ( Nextras\Orm\Entity\IEntity $entity, PropertyMetadata $propertyMeta, Nextras\Orm\Model\IModel $model )
$entity Nextras\Orm\Entity\IEntity
$propertyMeta Nextras\Orm\Entity\Reflection\PropertyMetadata
$model Nextras\Orm\Model\IModel

getCascadeQueue() public static method

See also: https://en.wikipedia.org/wiki/Topological_sorting#Depth-first_search
public static getCascadeQueue ( Nextras\Orm\Entity\IEntity $entity, Nextras\Orm\Model\IModel $model, boolean $withCascade ) : array
$entity Nextras\Orm\Entity\IEntity
$model Nextras\Orm\Model\IModel
$withCascade boolean
return array

visitEntity() protected static method

protected static visitEntity ( Nextras\Orm\Entity\IEntity $entity, Nextras\Orm\Model\IModel $model, $withCascade = true )
$entity Nextras\Orm\Entity\IEntity
$model Nextras\Orm\Model\IModel

visitRelationship() protected static method

protected static visitRelationship ( Nextras\Orm\Relationships\IRelationshipCollection $rel, Nextras\Orm\Model\IModel $model )
$rel Nextras\Orm\Relationships\IRelationshipCollection
$model Nextras\Orm\Model\IModel

Property Details

$inputQueue protected static property

protected static array $inputQueue
return array

$outputQueue protected static property

protected static array $outputQueue
return array