Doctrine\ODM\MongoDB\UnitOfWork::scheduleCollectionOwner PHP Метод

scheduleCollectionOwner() приватный Метод

If the owner is not scheduled for any lifecycle action, it will be scheduled for update to ensure that versioning takes place if necessary. If the collection is nested within atomic collection, it is immediately unscheduled and atomic one is scheduled for update instead. This makes calculating update data way easier.
private scheduleCollectionOwner ( Doctrine\ODM\MongoDB\PersistentCollection\PersistentCollectionInterface $coll )
$coll Doctrine\ODM\MongoDB\PersistentCollection\PersistentCollectionInterface
    private function scheduleCollectionOwner(PersistentCollectionInterface $coll)
    {
        $document = $this->getOwningDocument($coll->getOwner());
        $this->hasScheduledCollections[spl_object_hash($document)][spl_object_hash($coll)] = $coll;
        if ($document !== $coll->getOwner()) {
            $parent = $coll->getOwner();
            while (null !== ($parentAssoc = $this->getParentAssociation($parent))) {
                list($mapping, $parent, ) = $parentAssoc;
            }
            if (CollectionHelper::isAtomic($mapping['strategy'])) {
                $class = $this->dm->getClassMetadata(get_class($document));
                $atomicCollection = $class->getFieldValue($document, $mapping['fieldName']);
                $this->scheduleCollectionUpdate($atomicCollection);
                $this->unscheduleCollectionDeletion($coll);
                $this->unscheduleCollectionUpdate($coll);
            }
        }
        if (!$this->isDocumentScheduled($document)) {
            $this->scheduleForUpdate($document);
        }
    }
UnitOfWork