private function generateClass(): EntityGenerator
    {
        $this->entityFile = (new PhpFile())
            ->addComment('This file is auto-generated.');

        $this->entityClass = $this->entityFile
            ->addNamespace($this->entityData['namespace'])
            ->addClass($this->entityData['class'])
            ->addComment($this->entityData['class'] . ' entity' . PHP_EOL)
            ->addComment('@package ' . $this->entityData['namespace']);

        return $this;
    }