protected function UrlMatcher::mergeDefaults

Get merged default parameters.

Parameters

array $params The parameters:

array $defaults The defaults:

Return value

array Merged default parameters

4 calls to UrlMatcher::mergeDefaults()
ApacheUrlMatcher::match in drupal/core/vendor/symfony/routing/Symfony/Component/Routing/Matcher/ApacheUrlMatcher.php
Tries to match a URL based on Apache mod_rewrite matching.
ProjectUrlMatcher::match in drupal/core/vendor/symfony/routing/Symfony/Component/Routing/Tests/Fixtures/dumper/url_matcher2.php
Tries to match a URL path with a set of routes.
ProjectUrlMatcher::match in drupal/core/vendor/symfony/routing/Symfony/Component/Routing/Tests/Fixtures/dumper/url_matcher1.php
Tries to match a URL path with a set of routes.
UrlMatcher::matchCollection in drupal/core/vendor/symfony/routing/Symfony/Component/Routing/Matcher/UrlMatcher.php
Tries to match a URL with a set of routes.

File

drupal/core/vendor/symfony/routing/Symfony/Component/Routing/Matcher/UrlMatcher.php, line 175

Class

UrlMatcher
UrlMatcher matches URL based on a set of routes.

Namespace

Symfony\Component\Routing\Matcher

Code

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