You are here

class ObjectDefinition in Drupal 9

Same name in this branch
  1. 9 core/tests/Drupal/Tests/Core/Plugin/DefaultPluginManagerTest.php \Drupal\Tests\Core\Plugin\ObjectDefinition
  2. 9 core/tests/Drupal/Tests/Component/Annotation/Plugin/Discovery/AnnotationBridgeDecoratorTest.php \Drupal\Tests\Component\Annotation\Plugin\Discovery\ObjectDefinition
Same name and namespace in other branches
  1. 8 core/tests/Drupal/Tests/Component/Annotation/Plugin/Discovery/AnnotationBridgeDecoratorTest.php \Drupal\Tests\Component\Annotation\Plugin\Discovery\ObjectDefinition

Hierarchy

Expanded class hierarchy of ObjectDefinition

File

core/tests/Drupal/Tests/Component/Annotation/Plugin/Discovery/AnnotationBridgeDecoratorTest.php, line 58

Namespace

Drupal\Tests\Component\Annotation\Plugin\Discovery
View source
class ObjectDefinition extends PluginDefinition {

  /**
   * ObjectDefinition constructor.
   *
   * @param array $definition
   *   An array of definition values.
   */
  public function __construct(array $definition) {
    foreach ($definition as $property => $value) {
      $this->{$property} = $value;
    }
  }

}

Members

Namesort descending Modifiers Type Description Overrides
ObjectDefinition::__construct public function ObjectDefinition constructor.
PluginDefinition::$class protected property A fully qualified class name.
PluginDefinition::$id protected property The plugin ID. 1
PluginDefinition::$provider protected property The plugin provider.
PluginDefinition::getClass public function Gets the class. Overrides PluginDefinitionInterface::getClass
PluginDefinition::getProvider public function Gets the plugin provider. Overrides PluginDefinitionInterface::getProvider
PluginDefinition::id public function Gets the unique identifier of the plugin. Overrides PluginDefinitionInterface::id 1
PluginDefinition::setClass public function Sets the class. Overrides PluginDefinitionInterface::setClass 1