W3cubDocs

/Drupal 8

public function ImageToolkitManager::getDefaultToolkit

public ImageToolkitManager::getDefaultToolkit()

Gets the default image toolkit.

Return value

\Drupal\Core\ImageToolkit\ImageToolkitInterface Object of the default toolkit, or FALSE on error.

File

core/lib/Drupal/Core/ImageToolkit/ImageToolkitManager.php, line 73

Class

ImageToolkitManager
Manages image toolkit plugins.

Namespace

Drupal\Core\ImageToolkit

Code

public function getDefaultToolkit() {
  if ($toolkit_id = $this->getDefaultToolkitId()) {
    return $this->createInstance($toolkit_id);
  }
  return FALSE;
}

© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/core!lib!Drupal!Core!ImageToolkit!ImageToolkitManager.php/function/ImageToolkitManager::getDefaultToolkit/8.1.x