You are here

public function EntityResource::__construct in CMS Content Sync 8

Same name and namespace in other branches
  1. 2.1.x src/Plugin/rest/resource/EntityResource.php \Drupal\cms_content_sync\Plugin\rest\resource\EntityResource::__construct()
  2. 2.0.x src/Plugin/rest/resource/EntityResource.php \Drupal\cms_content_sync\Plugin\rest\resource\EntityResource::__construct()

Constructs an 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

array $serializer_formats: The available serialization formats

\Psr\Log\LoggerInterface $logger: A logger instance

\Drupal\Core\Entity\EntityTypeBundleInfo $entity_type_bundle_info: An entity type bundle info instance

\Drupal\Core\Entity\EntityTypeManagerInterface $entity_type_manager: An entity type manager instance

\Drupal\Core\Render\Renderer $render_manager: A rendered instance

\Drupal\Core\Entity\EntityRepositoryInterface $entity_repository: The entity repository interface

Overrides ResourceBase::__construct

File

src/Plugin/rest/resource/EntityResource.php, line 113

Class

EntityResource
Provides entity interfaces for Content Sync, allowing Sync Core to request and manipulate entities.

Namespace

Drupal\cms_content_sync\Plugin\rest\resource

Code

public function __construct(array $configuration, $plugin_id, $plugin_definition, array $serializer_formats, LoggerInterface $logger, EntityTypeBundleInfo $entity_type_bundle_info, EntityTypeManagerInterface $entity_type_manager, Renderer $render_manager, EntityRepositoryInterface $entity_repository) {
  parent::__construct($configuration, $plugin_id, $plugin_definition, $serializer_formats, $logger);
  $this->entityTypeBundleInfo = $entity_type_bundle_info;
  $this->entityTypeManager = $entity_type_manager;
  $this->renderedManager = $render_manager;
  $this->entityRepository = $entity_repository;
}