Same name and namespace in other branches
  1. 1.1.x src/Plugin/Field/FieldFormatter/EntityReferenceFilteredLinkFormatter.php \Drupal\entity_ref_filtering_link\Plugin\Field\FieldFormatter\EntityReferenceFilteredLinkFormatter::__construct() 1 comment

Constructs a FormatterBase object.

Parameters

string $plugin_id: The plugin_id for the formatter.

mixed[] $plugin_definition: The plugin implementation definition.

\Drupal\Core\Field\FieldDefinitionInterface $field_definition: The definition of the field to which the formatter is associated.

mixed[] $settings: The formatter settings.

string $label: The formatter label display setting.

string $view_mode: The view mode.

mixed[] $third_party_settings: Any third party settings.

\Drupal\Core\Path\PathValidatorInterface $path_validator: The path validator service.

File

src/Plugin/Field/FieldFormatter/EntityReferenceFilteredLinkFormatter.php, line 56

Class

EntityReferenceFilteredLinkFormatter
Plugin implementation of the 'entity_reference_filtered_link' formatter.

Namespace

Drupal\entity_ref_filtering_link\Plugin\Field\FieldFormatter

Code

public function __construct(string $plugin_id, array $plugin_definition, FieldDefinitionInterface $field_definition, array $settings, string $label, string $view_mode, array $third_party_settings, PathValidatorInterface $path_validator) {
    parent::__construct($plugin_id, $plugin_definition, $field_definition, $settings, $label, $view_mode, $third_party_settings);
    $this->pathValidator = $path_validator;
}