You are here

public static function CropInterface::getCropFromImageStyle in Crop API 8

Same name and namespace in other branches
  1. 8.2 src/CropInterface.php \Drupal\crop\CropInterface::getCropFromImageStyle()

Retrieve crop from given image style.

Parameters

string $uri: URI of the image.

\Drupal\image\ImageStyleInterface $image_style: The image style.

Return value

\Drupal\crop\CropInterface|null Crop entity used by effect 'crop_crop' or NULL if crop doesn't exist.

1 method overrides CropInterface::getCropFromImageStyle()
Crop::getCropFromImageStyle in src/Entity/Crop.php
Retrieve crop from given image style.

File

src/CropInterface.php, line 112

Class

CropInterface
Provides an interface defining the crop entity.

Namespace

Drupal\crop

Code

public static function getCropFromImageStyle($uri, ImageStyleInterface $image_style);