public function TestToolkit::getMimeType in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/modules/system/tests/modules/image_test/src/Plugin/ImageToolkit/TestToolkit.php \Drupal\image_test\Plugin\ImageToolkit\TestToolkit::getMimeType()
Returns the MIME type of the image file.
Return value
string The MIME type of the image file, or an empty string if the image is invalid.
Overrides ImageToolkitInterface::getMimeType
File
- core/
modules/ system/ tests/ modules/ image_test/ src/ Plugin/ ImageToolkit/ TestToolkit.php, line 229 - Contains \Drupal\image_test\Plugin\ImageToolkit\TestToolkit.
Class
- TestToolkit
- Defines a Test toolkit for image manipulation within Drupal.
Namespace
Drupal\image_test\Plugin\ImageToolkitCode
public function getMimeType() {
return $this
->getType() ? image_type_to_mime_type($this
->getType()) : '';
}