You are here

interface MediaThumbnailInterface in Media Thumbnails 8

Defines an interface for Media thumbnail plugins.

Hierarchy

Expanded class hierarchy of MediaThumbnailInterface

All classes that implement MediaThumbnailInterface

File

src/Plugin/MediaThumbnailInterface.php, line 10

Namespace

Drupal\media_thumbnails\Plugin
View source
interface MediaThumbnailInterface extends PluginInspectionInterface {

  /**
   * Create a thumbnail file using the passed source uri.
   *
   * @param string $sourceUri
   *   The uri of the source file, like 'public://invoices/inv001.pdf'.
   *
   * @return \Drupal\file\Entity\File|null
   *   The new managed file object for the generated thumbnail.
   */
  public function createThumbnail($sourceUri);

}

Members

Namesort descending Modifiers Type Description Overrides
MediaThumbnailInterface::createThumbnail public function Create a thumbnail file using the passed source uri.
PluginInspectionInterface::getPluginDefinition public function Gets the definition of the plugin implementation. 4
PluginInspectionInterface::getPluginId public function Gets the plugin_id of the plugin instance. 2