3 namespace Drupal\paragraphs;
5 use Drupal\Core\Config\Entity\ConfigEntityInterface;
8 * Provides an interface defining a ParagraphsType entity.
10 interface ParagraphsTypeInterface extends ConfigEntityInterface {
13 * Returns the ordered collection of feature plugin instances.
15 * @return \Drupal\paragraphs\ParagraphsBehaviorCollection
16 * The behavior plugins collection.
18 public function getBehaviorPlugins();
21 * Returns an individual plugin instance.
23 * @param string $instance_id
24 * The ID of a behavior plugin instance to return.
26 * @return \Drupal\paragraphs\ParagraphsBehaviorInterface
27 * A specific feature plugin instance.
29 public function getBehaviorPlugin($instance_id);
32 * Retrieves all the enabled plugins.
35 * Array of the enabled plugins as instances.
37 public function getEnabledBehaviorPlugins();
40 * Returns TRUE if $plugin_id is enabled on this ParagraphType Entity.
42 * @param string $plugin_id
43 * The plugin id, as specified in the plugin annotation details.
46 * True or False dependant on plugin state
48 public function hasEnabledBehaviorPlugin($plugin_id);