You are here

class ControllerReference in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/http-kernel/Controller/ControllerReference.php \Symfony\Component\HttpKernel\Controller\ControllerReference

Acts as a marker and a data holder for a Controller.

Some methods in Symfony accept both a URI (as a string) or a controller as an argument. In the latter case, instead of passing an array representing the controller, you can use an instance of this class.

@author Fabien Potencier <fabien@symfony.com>

Hierarchy

Expanded class hierarchy of ControllerReference

See also

FragmentRendererInterface

10 files declare their use of ControllerReference
AbstractSurrogateFragmentRenderer.php in vendor/symfony/http-kernel/Fragment/AbstractSurrogateFragmentRenderer.php
EsiFragmentRendererTest.php in vendor/symfony/http-kernel/Tests/Fragment/EsiFragmentRendererTest.php
FragmentHandler.php in vendor/symfony/http-kernel/Fragment/FragmentHandler.php
FragmentRendererInterface.php in vendor/symfony/http-kernel/Fragment/FragmentRendererInterface.php
HIncludeFragmentRenderer.php in vendor/symfony/http-kernel/Fragment/HIncludeFragmentRenderer.php

... See full list

File

vendor/symfony/http-kernel/Controller/ControllerReference.php, line 27

Namespace

Symfony\Component\HttpKernel\Controller
View source
class ControllerReference {
  public $controller;
  public $attributes = array();
  public $query = array();

  /**
   * Constructor.
   *
   * @param string $controller The controller name
   * @param array  $attributes An array of parameters to add to the Request attributes
   * @param array  $query      An array of parameters to add to the Request query string
   */
  public function __construct($controller, array $attributes = array(), array $query = array()) {
    $this->controller = $controller;
    $this->attributes = $attributes;
    $this->query = $query;
  }

}

Members