. */ /** * Doctrine_Task_GenerateModelsDb * * @package Doctrine * @subpackage Task * @license http://www.opensource.org/licenses/lgpl-license.php LGPL * @link www.phpdoctrine.org * @since 1.0 * @version $Revision: 2761 $ * @author Jonathan H. Wage */ class Doctrine_Task_GenerateModelsDb extends Doctrine_Task { public $description = 'Generates your Doctrine_Record definitions from your existing database connections.', $requiredArguments = array('models_path' => 'Specify path to your Doctrine_Record definitions.'), $optionalArguments = array('connection' => 'Optionally specify a single connection to generate the models for.'); public function execute() { Doctrine::generateModelsFromDb($this->getArgument('models_path'), (array) $this->getArgument('connection')); $this->dispatcher->notify('Generated models successfully from databases'); } }