PHP Интерфейс Imbo\EventListener\ImageVariations\Database\DatabaseInterface

Автор: Christer Edvartsen ([email protected])
Показать файл Открыть проект Примеры использования интерфейса

Открытые методы

Метод Описание
deleteImageVariations ( string $user, string $imageIdentifier, integer $width = null ) : boolean Remove all metadata about image variations for an image
getBestMatch ( string $user, string $imageIdentifier, integer $width ) : integer | null Fetch the best match of an image
storeImageVariationMetadata ( string $user, string $imageIdentifier, integer $width, integer $height ) : boolean Store an image variation

Описание методов

deleteImageVariations() публичный Метод

Remove all metadata about image variations for an image
public deleteImageVariations ( string $user, string $imageIdentifier, integer $width = null ) : boolean
$user string The user which the image belongs to
$imageIdentifier string The image identifier
$width integer Only delete the variation with this width
Результат boolean

getBestMatch() публичный Метод

Fetch the best match of an image
public getBestMatch ( string $user, string $imageIdentifier, integer $width ) : integer | null
$user string The user which the image belongs to
$imageIdentifier string The image identifier of the original
$width integer The width we want to resize the image to
Результат integer | null Returns the closest width, or null

storeImageVariationMetadata() публичный Метод

Store an image variation
public storeImageVariationMetadata ( string $user, string $imageIdentifier, integer $width, integer $height ) : boolean
$user string The user which the image belongs to
$imageIdentifier string The image identifier of the original
$width integer The width of the variation
$height integer The height of the variation
Результат boolean