public function OEmbed::getSourceFieldConstraints in Drupal 10
Same name and namespace in other branches
- 8 core/modules/media/src/Plugin/media/Source/OEmbed.php \Drupal\media\Plugin\media\Source\OEmbed::getSourceFieldConstraints()
- 9 core/modules/media/src/Plugin/media/Source/OEmbed.php \Drupal\media\Plugin\media\Source\OEmbed::getSourceFieldConstraints()
Gets media source-specific validation constraints for a source field.
Return value
\Symfony\Component\Validator\Constraint[] An array of validation constraint definitions, keyed by constraint name. Each constraint definition can be used for instantiating \Symfony\Component\Validator\Constraint objects.
Overrides MediaSourceFieldConstraintsInterface::getSourceFieldConstraints
File
- core/
modules/ media/ src/ Plugin/ media/ Source/ OEmbed.php, line 495
Class
- OEmbed
- Provides a media source plugin for oEmbed resources.
Namespace
Drupal\media\Plugin\media\SourceCode
public function getSourceFieldConstraints() {
return [
'oembed_resource' => [],
];
}