public function LanguageTypeResolver::applies in GraphQL 8.2
Same name and namespace in other branches
- 8 src/TypeResolver/LanguageTypeResolver.php \Drupal\graphql\TypeResolver\LanguageTypeResolver::applies()
Parameters
mixed $type:
Return value
bool
Overrides TypeResolverInterface::applies
File
- src/
TypeResolver/ LanguageTypeResolver.php, line 26
Class
- LanguageTypeResolver
- Resolves the schema for the 'language' data type.
Namespace
Drupal\graphql\TypeResolverCode
public function applies($type) {
if ($type instanceof DataDefinitionInterface) {
return $type
->getDataType() === 'language';
}
return FALSE;
}