Drupal investigation

ChainRouterInterface.php 1.1KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. <?php
  2. /*
  3. * This file is part of the Symfony CMF package.
  4. *
  5. * (c) 2011-2015 Symfony CMF
  6. *
  7. * For the full copyright and license information, please view the LICENSE
  8. * file that was distributed with this source code.
  9. */
  10. namespace Symfony\Cmf\Component\Routing;
  11. use Symfony\Component\Routing\RouterInterface;
  12. use Symfony\Component\Routing\Matcher\RequestMatcherInterface;
  13. /**
  14. * Interface for a router that proxies routing to other routers.
  15. *
  16. * @author Daniel Wehner <dawehner@googlemail.com>
  17. */
  18. interface ChainRouterInterface extends RouterInterface, RequestMatcherInterface
  19. {
  20. /**
  21. * Add a Router to the index.
  22. *
  23. * @param RouterInterface $router The router instance. Instead of RouterInterface, may also
  24. * be RequestMatcherInterface and UrlGeneratorInterface.
  25. * @param int $priority The priority
  26. */
  27. public function add($router, $priority = 0);
  28. /**
  29. * Sorts the routers and flattens them.
  30. *
  31. * @return RouterInterface[] or RequestMatcherInterface and UrlGeneratorInterface.
  32. */
  33. public function all();
  34. }