You are here

interface RouteWrapperInterface in Drupal 7 to 8/9 Module Upgrader 8

Common interface implemented by classes which wrap around Drupal 7 or Drupal 8 routes.

Hierarchy

Expanded class hierarchy of RouteWrapperInterface

All classes that implement RouteWrapperInterface

2 files declare their use of RouteWrapperInterface
RouteWrapper.php in src/Routing/Drupal7/RouteWrapper.php
RouteWrapper.php in src/Routing/Drupal8/RouteWrapper.php

File

src/Routing/RouteWrapperInterface.php, line 9

Namespace

Drupal\drupalmoduleupgrader\Routing
View source
interface RouteWrapperInterface {

  /**
   * Returns an identifier for this route.
   *
   * @return string
   */
  public function getIdentifier();

  /**
   * Returns a PathUtilityInterface implementation for the route.
   *
   * @return \Drupal\drupalmoduleupgrader\Utility\Path\PathUtilityInterface
   */
  public function getPath();

  /**
   * Returns if this route has a parent.
   *
   * @return bool
   */
  public function hasParent();

  /**
   * Gets the parent route, if there is one. The parent should also be wrapped.
   *
   * @return static|null
   */
  public function getParent();

  /**
   * Returns the original, unwrapped route.
   *
   * @return mixed
   */
  public function unwrap();

  /**
   * React to the router (i.e., the collection of routes defined by the
   * module) being completely built.
   *
   * @param RouterBuiltEvent $event
   *   The event object.
   */
  public function onRouterBuilt(RouterBuiltEvent $event);

}

Members

Namesort descending Modifiers Type Description Overrides
RouteWrapperInterface::getIdentifier public function Returns an identifier for this route. 2
RouteWrapperInterface::getParent public function Gets the parent route, if there is one. The parent should also be wrapped. 2
RouteWrapperInterface::getPath public function Returns a PathUtilityInterface implementation for the route. 2
RouteWrapperInterface::hasParent public function Returns if this route has a parent. 2
RouteWrapperInterface::onRouterBuilt public function React to the router (i.e., the collection of routes defined by the module) being completely built. 2
RouteWrapperInterface::unwrap public function Returns the original, unwrapped route. 2