示例#1
0
 public function __construct(Context $context)
 {
     parent::__construct($context);
     $this->type = 'RouteParams';
     // Default approach to route param parsing
     $this->routeParams = explode('/', $context->getUrl()->requestUri);
 }
示例#2
0
 public function __construct(Context $context)
 {
     parent::__construct($context);
     $this->type = 'RouteParams';
     if (isset($context->getCaller()->annotations['canonical'])) {
         $this->routeParams = Url::extract($context->getCaller()->annotations['canonical'], $context->getUrl()->requestUri);
     }
 }