You are here

interface EmbedInterface in CKEditor Media Embed Plugin 8

Defines an interface for processing and embedding embeddable content.

Hierarchy

Expanded class hierarchy of EmbedInterface

All classes that implement EmbedInterface

2 files declare their use of EmbedInterface
CKEditorMediaEmbedFormatter.php in src/Plugin/Field/FieldFormatter/CKEditorMediaEmbedFormatter.php
FilterCKEditorMediaEmbed.php in src/Plugin/Filter/FilterCKEditorMediaEmbed.php

File

src/EmbedInterface.php, line 8

Namespace

Drupal\ckeditor_media_embed
View source
interface EmbedInterface {

  /**
   * Retrieve the link to the configuration page for the settings.
   */
  public function getSettingsLink();

  /**
   * Sets specified provider url as the provider URL.
   */
  public function setEmbedProvider($provider);

  /**
   * Retrieve the Embed object as provided by the embed provider.
   *
   * @param string $url
   *   The url to the media to request an embed object for.
   *
   * @return object
   *   The decoded json object retrieved from the provided for the specified
   *   url.
   */
  public function getEmbedObject($url);

  /**
   * Replace all oembed tags with the embed html based ona provider resource.
   *
   * @param string $text
   *   The HTML string to replace <oembed> tags.
   *
   * @return string
   *   The HTML with all the <oembed> tags replaced with their embed html.
   */
  public function processEmbeds($text);

}

Members

Namesort descending Modifiers Type Description Overrides
EmbedInterface::getEmbedObject public function Retrieve the Embed object as provided by the embed provider. 1
EmbedInterface::getSettingsLink public function Retrieve the link to the configuration page for the settings. 1
EmbedInterface::processEmbeds public function Replace all oembed tags with the embed html based ona provider resource. 1
EmbedInterface::setEmbedProvider public function Sets specified provider url as the provider URL. 1