You are here

function AnnotatedClassDiscovery::__construct in Plug 7

Same name in this branch
  1. 7 lib/Drupal/Core/Plugin/Discovery/AnnotatedClassDiscovery.php \Drupal\Core\Plugin\Discovery\AnnotatedClassDiscovery::__construct()
  2. 7 lib/Drupal/Component/Annotation/Plugin/Discovery/AnnotatedClassDiscovery.php \Drupal\Component\Annotation\Plugin\Discovery\AnnotatedClassDiscovery::__construct()

Constructs a new instance.

Parameters

string[] $plugin_namespaces: (optional) An array of namespace that may contain plugin implementations. Defaults to an empty array.

string $plugin_definition_annotation_name: (optional) The name of the annotation that contains the plugin definition. Defaults to 'Drupal\Component\Annotation\Plugin'.

1 call to AnnotatedClassDiscovery::__construct()
AnnotatedClassDiscovery::__construct in lib/Drupal/Core/Plugin/Discovery/AnnotatedClassDiscovery.php
Constructs an AnnotatedClassDiscovery object.
1 method overrides AnnotatedClassDiscovery::__construct()
AnnotatedClassDiscovery::__construct in lib/Drupal/Core/Plugin/Discovery/AnnotatedClassDiscovery.php
Constructs an AnnotatedClassDiscovery object.

File

lib/Drupal/Component/Annotation/Plugin/Discovery/AnnotatedClassDiscovery.php, line 59
Contains \Drupal\Component\Annotation\Plugin\Discovery\AnnotatedClassDiscovery.

Class

AnnotatedClassDiscovery
Defines a discovery mechanism to find annotated plugins in PSR-0 namespaces.

Namespace

Drupal\Component\Annotation\Plugin\Discovery

Code

function __construct($plugin_namespaces = array(), $plugin_definition_annotation_name = 'Drupal\\Component\\Annotation\\Plugin') {
  $this->pluginNamespaces = $plugin_namespaces;
  $this->pluginDefinitionAnnotationName = $plugin_definition_annotation_name;
}