Esempio n. 1
0
 /**
  * Constructor.
  */
 public function __construct()
 {
     parent::__construct(new ParameterBag($this->getDefaultParameters()));
     $this->methodMap = array('bar' => 'getBarService', 'baz' => 'getBazService', 'configurator_service' => 'getConfiguratorServiceService', 'configurator_service_simple' => 'getConfiguratorServiceSimpleService', 'configured_service' => 'getConfiguredServiceService', 'configured_service_simple' => 'getConfiguredServiceSimpleService', 'decorated' => 'getDecoratedService', 'decorator_service' => 'getDecoratorServiceService', 'decorator_service_with_name' => 'getDecoratorServiceWithNameService', 'deprecated_service' => 'getDeprecatedServiceService', 'factory_service' => 'getFactoryServiceService', 'factory_service_simple' => 'getFactoryServiceSimpleService', 'factory_simple' => 'getFactorySimpleService', 'foo' => 'getFooService', 'foo.baz' => 'getFoo_BazService', 'foo_bar' => 'getFooBarService', 'foo_with_inline' => 'getFooWithInlineService', 'inlined' => 'getInlinedService', 'method_call1' => 'getMethodCall1Service', 'new_factory' => 'getNewFactoryService', 'new_factory_service' => 'getNewFactoryServiceService', 'request' => 'getRequestService', 'service_from_static_method' => 'getServiceFromStaticMethodService');
     $this->privates = array('configurator_service' => true, 'configurator_service_simple' => true, 'factory_simple' => true, 'inlined' => true, 'new_factory' => true);
     $this->aliases = array('alias_for_alias' => 'foo', 'alias_for_foo' => 'foo');
 }
Esempio n. 2
0
 /**
  * Constructor.
  */
 public function __construct()
 {
     $this->parameters = array('baz_class' => 'BazClass', 'foo_class' => 'Bar\\FooClass', 'foo' => 'bar');
     parent::__construct(new ParameterBag($this->parameters));
     $this->methodMap = array('bar' => 'getBarService', 'baz' => 'getBazService', 'configurator_service' => 'getConfiguratorServiceService', 'configured_service' => 'getConfiguredServiceService', 'decorated' => 'getDecoratedService', 'decorator_service' => 'getDecoratorServiceService', 'decorator_service_with_name' => 'getDecoratorServiceWithNameService', 'depends_on_request' => 'getDependsOnRequestService', 'factory_service' => 'getFactoryServiceService', 'foo' => 'getFooService', 'foo.baz' => 'getFoo_BazService', 'foo_bar' => 'getFooBarService', 'foo_with_inline' => 'getFooWithInlineService', 'inlined' => 'getInlinedService', 'method_call1' => 'getMethodCall1Service', 'new_factory' => 'getNewFactoryService', 'new_factory_service' => 'getNewFactoryServiceService', 'request' => 'getRequestService', 'service_from_static_method' => 'getServiceFromStaticMethodService');
     $this->aliases = array('alias_for_alias' => 'foo', 'alias_for_foo' => 'foo');
 }
Esempio n. 3
0
 /**
  * Constructor
  * @param ParameterBagInterface $parameterBag
  */
 public function __construct(ParameterBagInterface $parameterBag = null)
 {
     parent::__construct($parameterBag);
     $passes = array();
     $passes[] = new MergeExtensionConfigurationPass();
     $passes[] = new ResolveInterfaceInjectorsPass();
     $this->compilerPasses = $passes;
 }
Esempio n. 4
0
 /**
  * Constructor
  * @param ParameterBagInterface $parameterBag
  */
 public function __construct(ParameterBagInterface $parameterBag = null)
 {
     parent::__construct($parameterBag);
     $this->compiler = new Compiler();
     foreach ($this->compiler->getPassConfig()->getPasses() as $pass) {
         $this->addObjectResource($pass);
     }
 }
Esempio n. 5
0
 /**
  * Constructor.
  */
 public function __construct()
 {
     parent::__construct(new ParameterBag($this->getDefaultParameters()));
     $this->methodMap = array(
         'bar' => 'getBarService',
         'baz' => 'getBazService',
         'depends_on_request' => 'getDependsOnRequestService',
         'factory_service' => 'getFactoryServiceService',
         'foo' => 'getFooService',
         'foo.baz' => 'getFoo_BazService',
         'foo_bar' => 'getFooBarService',
         'foo_with_inline' => 'getFooWithInlineService',
         'inlined' => 'getInlinedService',
         'method_call1' => 'getMethodCall1Service',
         'request' => 'getRequestService',
     );
     $this->aliases = array(
         'alias_for_alias' => 'foo',
         'alias_for_foo' => 'foo',
     );
 }
Esempio n. 6
0
 public function __construct()
 {
     parent::__construct();
     $this->__bar = new \stdClass();
     $this->__foo_bar = new \stdClass();
     $this->__foo_baz = new \stdClass();
 }
Esempio n. 7
0
 /**
  * Constructor.
  */
 public function __construct()
 {
     $this->parameters = array('foo' => '%baz%', 'baz' => 'bar', 'bar' => 'foo is %%foo bar', 'escape' => '@escapeme', 'values' => array(0 => true, 1 => false, 2 => NULL, 3 => 0, 4 => 1000.3, 5 => 'true', 6 => 'false', 7 => 'null'));
     parent::__construct(new ParameterBag($this->parameters));
 }
 /**
  * Constructor.
  */
 public function __construct()
 {
     parent::__construct();
 }
Esempio n. 9
0
 /**
  * Constructor.
  */
 public function __construct()
 {
     parent::__construct();
     $this->methodMap = array('service_from_anonymous_factory' => 'getServiceFromAnonymousFactoryService', 'service_with_method_call_and_factory' => 'getServiceWithMethodCallAndFactoryService');
 }
Esempio n. 10
0
 /**
  * Constructor.
  */
 public function __construct()
 {
     parent::__construct();
     $this->methodMap = array('foo' => 'getFooService');
 }
Esempio n. 11
0
 public function __construct()
 {
     parent::__construct();
     $this->__bar = new \stdClass();
     $this->__foo_bar = new \stdClass();
     $this->__foo_baz = new \stdClass();
     $this->__internal = new \stdClass();
     $this->privates = array('internal' => true);
     $this->aliases = array('alias' => 'bar');
 }
Esempio n. 12
0
 /**
  * @inheritdoc
  */
 public function __construct(ParameterBagInterface $parameterBag = null)
 {
     // This is not elegant, but it works.
     parent::__construct(new DrupalFrozenParameterBag($parameterBag->all()));
     $this->services['service_container'] = $this;
 }
Esempio n. 13
0
 /**
  * Construct object.
  *
  * @param array $options The default options
  */
 public function __construct($options = array())
 {
     parent::__construct(new ParameterBag($options));
 }
Esempio n. 14
0
 /**
  * Constructor
  * @param ParameterBagInterface $parameterBag
  */
 public function __construct(ParameterBagInterface $parameterBag = null)
 {
     parent::__construct($parameterBag);
 }
 /**
  * Constructor
  * @param ParameterBagInterface $parameterBag
  */
 public function __construct(ParameterBagInterface $parameterBag = null)
 {
     parent::__construct($parameterBag);
     $this->compilerPassConfig = new PassConfig();
 }
Esempio n. 16
0
 /**
  * Constructor.
  */
 public function __construct()
 {
     parent::__construct(new ParameterBag($this->getDefaultParameters()));
 }
Esempio n. 17
0
 /**
  * Constructor.
  */
 public function __construct()
 {
     parent::__construct();
     $this->methodMap = array('depends_on_request' => 'getDependsOnRequestService', 'request' => 'getRequestService');
 }
Esempio n. 18
0
 /**
  * Constructor.
  */
 public function __construct()
 {
     parent::__construct(new ParameterBag(self::$parameters));
 }
Esempio n. 19
0
 public function __construct()
 {
     parent::__construct();
     $this->__bar = new \stdClass();
     $this->__foo_bar = new \stdClass();
     $this->__foo_baz = new \stdClass();
     $this->synchronized = false;
     $this->aliases = array('alias' => 'bar');
 }
Esempio n. 20
0
 /**
  * Constructor.
  */
 public function __construct()
 {
     $this->parameters = array();
     parent::__construct(new ParameterBag($this->parameters));
 }