LeanMapper\Row::cleanReferencingAddedAndRemovedMeta PHP Method

cleanReferencingAddedAndRemovedMeta() public method

public cleanReferencingAddedAndRemovedMeta ( string $table, string | null $viaColumn = null, Filtering $filtering = null, string | null $strategy = null )
$table string
$viaColumn string | null
$filtering Filtering
$strategy string | null
    public function cleanReferencingAddedAndRemovedMeta($table, $viaColumn = null, Filtering $filtering = null, $strategy = null)
    {
        $this->result->cleanReferencingAddedAndRemovedMeta($table, $viaColumn, $filtering, $strategy);
    }

Usage Example

コード例 #1
0
ファイル: Entity.php プロジェクト: tharos/leanmapper
 /**
  * Marks entity as non-modified (isModified returns false right after this method call)
  */
 public function markAsUpdated()
 {
     $this->row->markAsUpdated();
     foreach ($this->getCurrentReflection()->getEntityProperties() as $property) {
         if ($property->hasRelationship() and $property->getRelationship() instanceof Relationship\HasMany) {
             $relationship = $property->getRelationship();
             $this->row->cleanReferencingAddedAndRemovedMeta($relationship->getRelationshipTable(), $relationship->getColumnReferencingSourceTable(), null, $relationship->getStrategy());
         }
     }
 }