interface FileMediaFormatterInterface in Drupal 9
Same name and namespace in other branches
- 8 core/modules/file/src/Plugin/Field/FieldFormatter/FileMediaFormatterInterface.php \Drupal\file\Plugin\Field\FieldFormatter\FileMediaFormatterInterface
Defines getter methods for FileMediaFormatterBase.
This interface is used on the FileMediaFormatterBase class to ensure that each file media formatter will be based on a media type.
Abstract classes are not able to implement abstract static methods, this interface will work around that.
Hierarchy
- interface \Drupal\file\Plugin\Field\FieldFormatter\FileMediaFormatterInterface
Expanded class hierarchy of FileMediaFormatterInterface
All classes that implement FileMediaFormatterInterface
See also
\Drupal\file\Plugin\Field\FieldFormatter\FileMediaFormatterBase
File
- core/
modules/ file/ src/ Plugin/ Field/ FieldFormatter/ FileMediaFormatterInterface.php, line 16
Namespace
Drupal\file\Plugin\Field\FieldFormatterView source
interface FileMediaFormatterInterface {
/**
* Gets the applicable media type for a formatter.
*
* @return string
* The media type of this formatter.
*/
public static function getMediaType();
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
FileMediaFormatterInterface:: |
public static | function | Gets the applicable media type for a formatter. | 2 |