php bin/console doctrine:generate:entities

Generates entity classes and method stubs from your mapping information

Usage

doctrine:generate:entities [--path PATH] [--no-backup] [--] <name>

Arguments

name   A bundle name, a namespace, or a class name 

Options

      --path        The path where to generate entities when it cannot be guessed 
      --no-backup   Do not backup existing entities files. 

Help

The doctrine:generate:entities command generates entity classes
and method stubs from your mapping information:

You have to limit generation of entities:

* To a bundle:

  php bin/console doctrine:generate:entities MyCustomBundle

* To a single entity:

  php bin/console doctrine:generate:entities MyCustomBundle:User
  php bin/console doctrine:generate:entities MyCustomBundle/Entity/User

* To a namespace

  php bin/console doctrine:generate:entities MyCustomBundle/Entity

If the entities are not stored in a bundle, and if the classes do not exist,
the command has no way to guess where they should be generated. In this case,
you must provide the --path option:

  php bin/console doctrine:generate:entities Blog/Entity --path=src/

By default, the unmodified version of each entity is backed up and saved
(e.g. Product.php~). To prevent this task from creating the backup file,
pass the --no-backup option:

  php bin/console doctrine:generate:entities Blog/Entity --no-backup

Important: Even if you specified Inheritance options in your
XML or YAML Mapping files the generator cannot generate the base and
child classes for you correctly, because it doesn't know which
class is supposed to extend which. You have to adjust the entity
code manually for inheritance to work!