Constructor.
public __construct ( Symfony\Component\DependencyInjection\ContainerInterface $container, mixed $resource, array $options = [], Symfony\Component\Routing\RequestContext $context = null, array $defaults = [] ) | ||
$container | Symfony\Component\DependencyInjection\ContainerInterface | A ContainerInterface instance |
$resource | mixed | The main resource to load |
$options | array | An array of options |
$context | Symfony\Component\Routing\RequestContext | The context |
$defaults | array | The default values |
/** * Extends parent constructor to get documents service * as $container is private in parent class * * @param ReadSiteRepositoryInterface $siteRepository * @param CurrentSiteIdInterface $currentSiteManager * @param ContainerInterface $container * @param mixed $resource * @param array $options * @param RequestContext $context */ public function __construct(ReadSiteRepositoryInterface $siteRepository, CurrentSiteIdInterface $currentSiteManager, ContainerInterface $container, $resource, array $options = array(), RequestContext $context = null) { parent::__construct($container, $resource, $options, $context); $this->siteRepository = $siteRepository; $this->currentSiteManager = $currentSiteManager; $this->requestStack = $container->get('request_stack'); $this->nodeManager = $container->get('open_orchestra_front.manager.node'); }
public function __construct(ContainerInterface $container, $resource, array $options = [], RequestContext $context = null) { $ch = $container->get('claroline.config.platform_config_handler'); $this->host = $ch->getParameter('domain_name'); $context = $context ?: new RequestContext(); $sslEnabled = $ch->getParameter('ssl_enabled'); $this->scheme = $sslEnabled ? 'https' : 'http'; $this->buildContext($context); parent::__construct($container, $resource, $options, $context); }
/** * {@inheritDoc} */ public function __construct(ContainerInterface $container, $resource, array $options = [], RequestContext $context = null) { $this->container = $container; parent::__construct($container, $resource, $options, $context); }
/** * @param ContainerInterface $container * @param mixed $resource * @param array $options * @param RequestContext $context */ public function __construct(ContainerInterface $container, $resource, array $options = array(), RequestContext $context = null) { parent::__construct($container, $resource, $options, $context); $this->requestStack = $container->get('request_stack'); }
public function __construct(ContainerInterface $container, $resource, array $options = array(), RequestContext $context = null) { parent::__construct($container, $resource, $options, $context); $this->dataComposerMemory = $container->get('hdiv_security_bundle.hdiv_data_composer_memory'); $this->HDIVConfig = $container->get('hdiv_security_bundle.hdiv_config'); }
public function __construct(ContainerInterface $container, $resource, array $options = array(), RequestContext $context = null, array $defaults = array()) { parent::__construct($container, $resource, $options, $context, $defaults); $this->container = $container; }
/** * ConditionalRouter constructor. * * @param ContainerInterface $container * @param mixed $resource * @param array $options * @param RequestContext|null $context */ public function __construct(ContainerInterface $container, $resource, array $options = array(), RequestContext $context = null) { // $this->loader is null at any moment, that is why we have to check whether there is conditional_router.routing_loader in the container $this->aContainer = $container; return parent::__construct($container, $resource, $options, $context); }