Пример #1
0
 /**
  * @return void
  */
 private function registerServiceProvider()
 {
     $application = new Application();
     $application->register(new AssertionServiceProvider());
     $application->register(new SilexTwigServiceProvider());
     $application->register(new ValidatorServiceProvider());
     $application->register(new FormServiceProvider());
     $application->register(new TwigServiceProvider());
     $application->register(new DateFormatterServiceProvider());
     $propelServiceProvider = new PropelServiceProvider();
     $propelServiceProvider->boot($application);
     $pimple = new Pimple();
     $pimple->setApplication($application);
 }
Пример #2
0
 /**
  * @param array|null $config
  */
 public function __construct($config = null)
 {
     parent::__construct($config);
     $propelServiceProvider = new PropelServiceProvider();
     $propelServiceProvider->boot(new Application());
 }
Пример #3
0
 /**
  * @param \Symfony\Component\Console\Input\InputInterface $input
  * @param \Symfony\Component\Console\Output\OutputInterface $output
  *
  * @return void
  */
 protected function initialize(InputInterface $input, OutputInterface $output)
 {
     $this->input = $input;
     $this->output = $output;
     $propelService = new PropelServiceProvider();
     $propelService->boot(new Application());
 }