protected function createNewInstance(array $data): object
    {
        $instance = self::getInstantiator()->instantiate($this->getEntityClass());

        $refl = $this->getReflection();

        foreach ($data as $key => $value) {
            $prop = $refl->getProperty($key);
            $prop->setAccessible(true);

            if ($value instanceof Closure) {
                $value = $value($instance, $this, $this->manager);
            }

            $prop->setValue($instance, $value);
        }

        return $instance;
    }