You are here

public function GDToolkit::isValid in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/modules/system/src/Plugin/ImageToolkit/GDToolkit.php \Drupal\system\Plugin\ImageToolkit\GDToolkit::isValid()

Checks if the image is valid.

Return value

bool TRUE if the image toolkit is currently handling a valid image, FALSE otherwise.

Overrides ImageToolkitInterface::isValid

1 call to GDToolkit::isValid()
GDToolkit::load in core/modules/system/src/Plugin/ImageToolkit/GDToolkit.php
Loads a GD resource from a file.

File

core/modules/system/src/Plugin/ImageToolkit/GDToolkit.php, line 214
Contains \Drupal\system\Plugin\ImageToolkit\GDToolkit.

Class

GDToolkit
Defines the GD2 toolkit for image manipulation within Drupal.

Namespace

Drupal\system\Plugin\ImageToolkit

Code

public function isValid() {
  return (bool) $this->preLoadInfo || (bool) $this->resource;
}