InboundPathProcessorInterface.php 974 B

1234567891011121314151617181920212223242526272829303132
  1. <?php
  2. namespace Drupal\Core\PathProcessor;
  3. use Symfony\Component\HttpFoundation\Request;
  4. /**
  5. * Defines an interface for classes that process the inbound path.
  6. */
  7. interface InboundPathProcessorInterface {
  8. /**
  9. * Processes the inbound path.
  10. *
  11. * Implementations may make changes to the request object passed in but should
  12. * avoid all other side effects. This method can be called to process requests
  13. * other than the current request.
  14. *
  15. * @param string $path
  16. * The path to process, with a leading slash.
  17. * @param \Symfony\Component\HttpFoundation\Request $request
  18. * The HttpRequest object representing the request to process. Note, if this
  19. * method is being called via the path_processor_manager service and is not
  20. * part of routing, the current request object must be cloned before being
  21. * passed in.
  22. *
  23. * @return string
  24. * The processed path.
  25. */
  26. public function processInbound($path, Request $request);
  27. }