private function getValuePrepareCallback(PersistentCollectionInterface $coll) : Closure
    {
        $mapping = $coll->getMapping();
        if (isset($mapping['embedded'])) {
            return function ($v) use ($mapping) {
                return $this->pb->prepareEmbeddedDocumentValue($mapping, $v);
            };
        }

        return function ($v) use ($mapping) {
            return $this->pb->prepareReferencedDocumentValue($mapping, $v);
        };
    }
private function getValuePrepareCallback(PersistentCollectionInterface $coll) : Closure
    {
        $mapping = $coll->getMapping();
        if (isset($mapping['embedded'])) {
            return function ($v) use ($mapping) {
                return $this->pb->prepareEmbeddedDocumentValue($mapping, $v);
            };
        }

        return function ($v) use ($mapping) {
            return $this->pb->prepareReferencedDocumentValue($mapping, $v);
        };
    }
private function getValuePrepareCallback ( PersistentCollectionInterface $ coll ) : Closure { $ mapping = $ coll -> getMapping ( ) ; if ( isset ( $ mapping [ 'embedded' ] ) ) { return function ( $ v ) use ( $ mapping ) { return $ this -> pb -> prepareEmbeddedDocumentValue ( $ mapping , $ v ) ; } ; } return function ( $ v ) use ( $ mapping ) { return $ this -> pb -> prepareReferencedDocumentValue ( $ mapping , $ v ) ; } ; }
Return callback instance for specified collection. This callback will prepare values for query from documents
that collection contain.
Return callback instance for specified collection . This callback will prepare values for query from documents that collection contain .