Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. UrlMatcher.php

function UrlMatcher::mergeDefaults

Get merged default parameters.

2 calls to UrlMatcher::mergeDefaults()
UrlMatcher::getAttributes in core/lib/Drupal/Core/Routing/UrlMatcher.php
Returns an array of values to use as request attributes.
UrlMatcher::getAttributes in vendor/symfony/routing/Matcher/UrlMatcher.php
Returns an array of values to use as request attributes.

File

vendor/symfony/routing/Matcher/UrlMatcher.php, line 229

Class

UrlMatcher
UrlMatcher matches URL based on a set of routes.

Namespace

Symfony\Component\Routing\Matcher

Code

protected function mergeDefaults(array $params, array $defaults) : array {
    foreach ($params as $key => $value) {
        if (!\is_int($key) && null !== $value) {
            $defaults[$key] = $value;
        }
    }
    return $defaults;
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal