* * This source file is subject to the MIT license that is bundled * with this source code in the file LICENSE. */ /** * Ensure the Doctrine ORM is configured properly for a production environment. * * @author Fabien Potencier * @author Jonathan H. Wage */ class EnsureProductionSettingsDoctrineCommand extends EnsureProductionSettingsCommand { protected function configure() { parent::configure(); $this ->setName('doctrine:ensure-production-settings') ->addOption('em', null, InputOption::PARAMETER_OPTIONAL, 'The entity manager to use for this command.') ->setHelp(<<doctrine:cache:clear-metadata command clears all metadata cache for the default entity manager: ./symfony doctrine:cache:clear-metadata You can also optionally specify the --em option to specify which entity manager to clear the cache for: ./symfony doctrine:cache:clear-metadata --em=default EOT ); } protected function execute(InputInterface $input, OutputInterface $output) { DoctrineCommand::setApplicationEntityManager($this->application, $input->getOption('em')); parent::execute($input, $output); } }