You are here

public static function BaseFieldFileFormatterBase::defaultSettings in Drupal 10

Same name and namespace in other branches
  1. 8 core/modules/file/src/Plugin/Field/FieldFormatter/BaseFieldFileFormatterBase.php \Drupal\file\Plugin\Field\FieldFormatter\BaseFieldFileFormatterBase::defaultSettings()
  2. 9 core/modules/file/src/Plugin/Field/FieldFormatter/BaseFieldFileFormatterBase.php \Drupal\file\Plugin\Field\FieldFormatter\BaseFieldFileFormatterBase::defaultSettings()

Defines the default settings for this plugin.

Return value

array A list of default settings, keyed by the setting name.

Overrides PluginSettingsBase::defaultSettings

4 methods override BaseFieldFileFormatterBase::defaultSettings()
DefaultFileFormatter::defaultSettings in core/modules/file/src/Plugin/Field/FieldFormatter/DefaultFileFormatter.php
Defines the default settings for this plugin.
FileExtensionFormatter::defaultSettings in core/modules/file/src/Plugin/Field/FieldFormatter/FileExtensionFormatter.php
Defines the default settings for this plugin.
FilemimeFormatter::defaultSettings in core/modules/file/src/Plugin/Field/FieldFormatter/FilemimeFormatter.php
Defines the default settings for this plugin.
FileUriFormatter::defaultSettings in core/modules/file/src/Plugin/Field/FieldFormatter/FileUriFormatter.php
Defines the default settings for this plugin.

File

core/modules/file/src/Plugin/Field/FieldFormatter/BaseFieldFileFormatterBase.php, line 69

Class

BaseFieldFileFormatterBase
Base class for file formatters, which allow to link to the file download URL.

Namespace

Drupal\file\Plugin\Field\FieldFormatter

Code

public static function defaultSettings() {
  $settings['link_to_file'] = FALSE;
  return $settings;
}