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

Breadcrumb

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

function EntityUuidConverter::applies

Overrides EntityConverter::applies

File

core/modules/jsonapi/src/ParamConverter/EntityUuidConverter.php, line 84

Class

EntityUuidConverter
Parameter converter for upcasting entity UUIDs to full objects.

Namespace

Drupal\jsonapi\ParamConverter

Code

public function applies($definition, $name, Route $route) {
    return (bool) Routes::getResourceTypeNameFromParameters($route->getDefaults()) && !empty($definition['type']) && str_starts_with($definition['type'], 'entity');
}

API Navigation

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