public function RestExport::__construct in Drupal 10
Same name and namespace in other branches
- 8 core/modules/rest/src/Plugin/views/display/RestExport.php \Drupal\rest\Plugin\views\display\RestExport::__construct()
- 9 core/modules/rest/src/Plugin/views/display/RestExport.php \Drupal\rest\Plugin\views\display\RestExport::__construct()
Constructs a RestExport object.
Parameters
array $configuration: A configuration array containing information about the plugin instance.
string $plugin_id: The plugin_id for the plugin instance.
mixed $plugin_definition: The plugin implementation definition.
\Drupal\Core\Routing\RouteProviderInterface $route_provider: The route provider.
\Drupal\Core\State\StateInterface $state: The state key value store.
\Drupal\Core\Render\RendererInterface $renderer: The renderer.
string[] $authentication_providers: The authentication providers, keyed by ID.
string[] $serializer_format_providers: The serialization format providers, keyed by format.
Overrides PathPluginBase::__construct
File
- core/
modules/ rest/ src/ Plugin/ views/ display/ RestExport.php, line 123
Class
- RestExport
- The plugin that handles Data response callbacks for REST resources.
Namespace
Drupal\rest\Plugin\views\displayCode
public function __construct(array $configuration, $plugin_id, $plugin_definition, RouteProviderInterface $route_provider, StateInterface $state, RendererInterface $renderer, array $authentication_providers, array $serializer_format_providers) {
parent::__construct($configuration, $plugin_id, $plugin_definition, $route_provider, $state);
$this->renderer = $renderer;
// $authentication_providers as defined in
// \Drupal\Core\DependencyInjection\Compiler\AuthenticationProviderPass
// and as such it is an array, with authentication providers (cookie,
// basic_auth) as keys and modules providing those as values (user,
// basic_auth).
$this->authenticationProviderIds = array_keys($authentication_providers);
$this->formatProviders = $serializer_format_providers;
}