bootstrap.php 1000 B

123456789101112131415161718192021222324252627
  1. <?php
  2. /*
  3. * This file is part of the FOSUserBundle package.
  4. *
  5. * (c) FriendsOfSymfony <http://friendsofsymfony.github.com/>
  6. *
  7. * For the full copyright and license information, please view the LICENSE
  8. * file that was distributed with this source code.
  9. */
  10. if (!is_file($autoloadFile = __DIR__.'/../vendor/autoload.php')) {
  11. throw new \LogicException('Could not find autoload.php in vendor/. Did you run "composer install --dev"?');
  12. }
  13. require $autoloadFile;
  14. if (class_exists('Propel')) {
  15. set_include_path(__DIR__ . '/../vendor/phing/phing/classes' . PATH_SEPARATOR . get_include_path());
  16. $class = new \ReflectionClass('TypehintableBehavior');
  17. $builder = new \PropelQuickBuilder();
  18. $builder->getConfig()->setBuildProperty('behavior.typehintable.class', $class->getFileName());
  19. $builder->setSchema(file_get_contents(__DIR__.'/../Resources/config/propel/schema.xml'));
  20. $builder->setClassTargets(array('tablemap', 'peer', 'object', 'query'));
  21. $builder->build();
  22. }