Same name and namespace in other branches
- 8.9.x core/lib/Drupal.php \Drupal::routeMatch()
- 9 core/lib/Drupal.php \Drupal::routeMatch()
Retrieves the currently active route match object.
Return value
\Drupal\Core\Routing\RouteMatchInterface The currently active route match object.
24 calls to Drupal::routeMatch()
- batch_process in core/
includes/ form.inc - Processes the batch.
- big_pipe_page_attachments in core/
modules/ big_pipe/ big_pipe.module - Implements hook_page_attachments().
- block_page_top in core/
modules/ block/ block.module - Implements hook_page_top().
- comment_form_field_ui_display_overview_form_alter in core/
modules/ comment/ comment.module - Implements hook_form_FORM_ID_alter().
- comment_form_field_ui_field_storage_add_form_alter in core/
modules/ comment/ comment.module - Implements hook_form_FORM_ID_alter() for field_ui_field_storage_add_form.
File
- core/
lib/ Drupal.php, line 288
Class
- Drupal
- Static Service Container wrapper.
Code
public static function routeMatch() {
return static::getContainer()
->get('current_route_match');
}