ObjectWithPluginCollectionInterface.php

Same filename in other branches
  1. 9 core/lib/Drupal/Core/Plugin/ObjectWithPluginCollectionInterface.php
  2. 10 core/lib/Drupal/Core/Plugin/ObjectWithPluginCollectionInterface.php
  3. 11.x core/lib/Drupal/Core/Plugin/ObjectWithPluginCollectionInterface.php

Namespace

Drupal\Core\Plugin

File

core/lib/Drupal/Core/Plugin/ObjectWithPluginCollectionInterface.php

View source
<?php

namespace Drupal\Core\Plugin;


/**
 * Provides an interface for an object using a plugin collection.
 *
 * @see \Drupal\Component\Plugin\LazyPluginCollection
 *
 * @ingroup plugin_api
 *
 * Entities that need this interface should implement
 * \Drupal\Core\Entity\EntityWithPluginCollectionInterface, which extends this.
 */
interface ObjectWithPluginCollectionInterface {
    
    /**
     * Gets the plugin collections used by this object.
     *
     * @return \Drupal\Component\Plugin\LazyPluginCollection[]
     *   An array of plugin collections, keyed by the property name they use to
     *   store their configuration.
     */
    public function getPluginCollections();

}

Interfaces

Title Deprecated Summary
ObjectWithPluginCollectionInterface Provides an interface for an object using a plugin collection.

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.