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

Breadcrumb

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

function WizardPluginBase::__construct

Constructs a WizardPluginBase object.

Overrides PluginBase::__construct

2 calls to WizardPluginBase::__construct()
Node::__construct in core/modules/node/src/Plugin/views/wizard/Node.php
Node constructor.
Node::__construct in core/modules/node/src/Plugin/views/wizard/Node.php
Node constructor.
1 method overrides WizardPluginBase::__construct()
Node::__construct in core/modules/node/src/Plugin/views/wizard/Node.php
Node constructor.

File

core/modules/views/src/Plugin/views/wizard/WizardPluginBase.php, line 146

Class

WizardPluginBase
Base class for Views wizard plugins.

Namespace

Drupal\views\Plugin\views\wizard

Code

public function __construct(array $configuration, $plugin_id, $plugin_definition, EntityTypeBundleInfoInterface $bundle_info_service, MenuParentFormSelectorInterface $parent_form_selector) {
    parent::__construct($configuration, $plugin_id, $plugin_definition);
    $this->bundleInfoService = $bundle_info_service;
    $this->base_table = $this->definition['base_table'];
    $this->parentFormSelector = $parent_form_selector;
    $entity_types = \Drupal::entityTypeManager()->getDefinitions();
    foreach ($entity_types as $entity_type_id => $entity_type) {
        if (in_array($this->base_table, [
            $entity_type->getBaseTable(),
            $entity_type->getDataTable(),
            $entity_type->getRevisionTable(),
            $entity_type->getRevisionDataTable(),
        ], TRUE)) {
            $this->entityType = $entity_type;
            $this->entityTypeId = $entity_type_id;
        }
    }
}

API Navigation

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