You are here

protected function Generic::createSourceFieldStorage in Media entity generic 8

Creates the source field storage definition.

By default, the first field type listed in the plugin definition's allowed_field_types array will be the generated field's type.

Return value

\Drupal\field\FieldStorageConfigInterface The unsaved field storage definition.

Overrides MediaSourceBase::createSourceFieldStorage

File

src/Plugin/media/Source/Generic.php, line 30

Class

Generic
Generic media source.

Namespace

Drupal\media_entity_generic\Plugin\media\Source

Code

protected function createSourceFieldStorage() {
  return parent::createSourceFieldStorage()
    ->set('custom_storage', TRUE);
}