Sonata\Exporter\Source\DoctrineORMQuerySourceIterator::current PHP Метод

current() публичный Метод

public current ( )
    public function current()
    {
        $current = $this->iterator->current();
        $data = array();
        foreach ($this->propertyPaths as $name => $propertyPath) {
            try {
                $data[$name] = $this->getValue($this->propertyAccessor->getValue($current[0], $propertyPath));
            } catch (UnexpectedTypeException $e) {
                //non existent object in path will be ignored
                $data[$name] = null;
            }
        }
        $this->query->getEntityManager()->getUnitOfWork()->detach($current[0]);
        return $data;
    }