Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. MediaSourceInterface.php

function MediaSourceInterface::createSourceField

Creates the source field definition for a type.

Parameters

\Drupal\media\MediaTypeInterface $type: The media type.

Return value

\Drupal\field\FieldConfigInterface The unsaved field definition. The field storage definition, if new, should also be unsaved.

1 method overrides MediaSourceInterface::createSourceField()
MediaSourceBase::createSourceField in core/modules/media/src/MediaSourceBase.php
Creates the source field definition for a type.

File

core/modules/media/src/MediaSourceInterface.php, line 143

Class

MediaSourceInterface
Defines the interface for media source plugins.

Namespace

Drupal\media

Code

public function createSourceField(MediaTypeInterface $type);

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal