public function JsonApiParamEnhancer::applies in JSON:API 8
Declares if the route enhancer applies to the given route.
Parameters
\Symfony\Component\Routing\Route $route: The route to consider attaching to.
Return value
bool TRUE if the check applies to the passed route, False otherwise.
Overrides RouteEnhancerInterface::applies
File
- src/
Routing/ JsonApiParamEnhancer.php, line 53
Class
- JsonApiParamEnhancer
- Processes the request query parameters.
Namespace
Drupal\jsonapi\RoutingCode
public function applies(Route $route) {
return (bool) Routes::getResourceTypeNameFromParameters($route
->getDefaults());
}