當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Router::__construct方法代碼示例

本文整理匯總了PHP中Symfony\Bundle\FrameworkBundle\Routing\Router::__construct方法的典型用法代碼示例。如果您正苦於以下問題:PHP Router::__construct方法的具體用法?PHP Router::__construct怎麽用?PHP Router::__construct使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Symfony\Bundle\FrameworkBundle\Routing\Router的用法示例。


在下文中一共展示了Router::__construct方法的7個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: __construct

 /**
  * 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');
 }
開發者ID:open-orchestra,項目名稱:open-orchestra-front-bundle,代碼行數:19,代碼來源:OpenOrchestraRouter.php

示例2: __construct

 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);
 }
開發者ID:claroline,項目名稱:distribution,代碼行數:10,代碼來源:ClaroRouter.php

示例3: __construct

 /**
  * {@inheritDoc}
  */
 public function __construct(ContainerInterface $container, $resource, array $options = [], RequestContext $context = null)
 {
     $this->container = $container;
     parent::__construct($container, $resource, $options, $context);
 }
開發者ID:yoyosan,項目名稱:BlablacarI18nRoutingBundle,代碼行數:8,代碼來源:Router.php

示例4: __construct

 /**
  * @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');
 }
開發者ID:eliberty,項目名稱:api-bundle,代碼行數:11,代碼來源:ApiRouter.php

示例5: __construct

 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');
 }
開發者ID:hdiv,項目名稱:HDIVSecurityBundle,代碼行數:6,代碼來源:Router.php

示例6: __construct

 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;
 }
開發者ID:natxet,項目名稱:JMSI18nRoutingBundle,代碼行數:5,代碼來源:I18nRouter.php

示例7: __construct

 /**
  * 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);
 }
開發者ID:piotrpolak,項目名稱:conditional-routing-bundle,代碼行數:14,代碼來源:ConditionalRouter.php


注:本文中的Symfony\Bundle\FrameworkBundle\Routing\Router::__construct方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。