PHP Класс Imbo\Model\Image

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

Открытые свойства

Свойство Тип Описание
$mimeTypeMapping array Mapping for some mime types
$mimeTypes array Supported mime types and the correct file extensions

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

Метод Описание
getAddedDate ( ) : DateTime Get the added date
getBlob ( ) : string Get the blob
getChecksum ( ) : string Get the checksum of the current image data
getData ( )
getExtension ( ) : string Get the extension
getFileExtension ( string $mime ) : boolean | string Get the file extension mapped to a mime type
getFilesize ( ) : integer Get the size of the image data in bytes
getHeight ( ) : integer Get the height
getImageIdentifier ( ) : string Get the image identifier
getMetadata ( ) : array Get the metadata
getMimeType ( ) : string Get the mime type
getOriginalChecksum ( ) : string Get the original checksum of the current image data
getUpdatedDate ( ) : DateTime Get the updated date
getUser ( ) : string Get the user
getWidth ( ) : integer Get the width
hasBeenTransformed ( boolean | null $flag = null ) : boolean | self Set or get the hasBeenTransformed flag
setAddedDate ( DateTime $added ) : Image Set the added date
setBlob ( string $blob ) : Image Set the blob and update filesize and checksum properties
setChecksum ( string $checksum ) : Image Set the checksum
setExtension ( string $extension ) : Image Set the extension
setFilesize ( integer $size ) : Image Set the size of the image in bytes
setHeight ( integer $height ) : Image Set the height
setImageIdentifier ( string $imageIdentifier ) : Image Set the image identifier
setMetadata ( array $metadata ) : Image Set the metadata
setMimeType ( string $mimeType ) : Image Set the mime type
setOriginalChecksum ( $checksum ) : Image Set the original checksum
setUpdatedDate ( DateTime $updated ) : Image Set the updated date
setUser ( string $user ) : Image Set the user
setWidth ( integer $width ) : Image Set the width
supportedMimeType ( string $mime ) : boolean Check if a mime type is supported by Imbo

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

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

Get the added date
public getAddedDate ( ) : DateTime
Результат DateTime

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

Get the blob
public getBlob ( ) : string
Результат string

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

Get the checksum of the current image data
public getChecksum ( ) : string
Результат string

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

public getData ( )

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

Get the extension
public getExtension ( ) : string
Результат string

getFileExtension() публичный статический Метод

Get the file extension mapped to a mime type
public static getFileExtension ( string $mime ) : boolean | string
$mime string The mime type. For instance "image/png"
Результат boolean | string The extension (without the leading dot) on success or boolean false if the mime type is not supported.

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

Get the size of the image data in bytes
public getFilesize ( ) : integer
Результат integer

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

Get the height
public getHeight ( ) : integer
Результат integer

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

Get the image identifier
public getImageIdentifier ( ) : string
Результат string

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

Get the metadata
public getMetadata ( ) : array
Результат array

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

Get the mime type
public getMimeType ( ) : string
Результат string

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

Get the original checksum of the current image data
public getOriginalChecksum ( ) : string
Результат string

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

Get the updated date
public getUpdatedDate ( ) : DateTime
Результат DateTime

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

Get the user
public getUser ( ) : string
Результат string

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

Get the width
public getWidth ( ) : integer
Результат integer

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

Set or get the hasBeenTransformed flag
public hasBeenTransformed ( boolean | null $flag = null ) : boolean | self
$flag boolean | null Skip the argument to get the current value
Результат boolean | self

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

Set the added date
public setAddedDate ( DateTime $added ) : Image
$added DateTime When the image was added
Результат Image

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

Set the blob and update filesize and checksum properties
public setBlob ( string $blob ) : Image
$blob string The binary data to set
Результат Image

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

Set the checksum
public setChecksum ( string $checksum ) : Image
$checksum string The checksum to set
Результат Image

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

Set the extension
public setExtension ( string $extension ) : Image
$extension string The file extension
Результат Image

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

Set the size of the image in bytes
public setFilesize ( integer $size ) : Image
$size integer The size of the image
Результат Image

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

Set the height
public setHeight ( integer $height ) : Image
$height integer Height in pixels
Результат Image

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

Set the image identifier
public setImageIdentifier ( string $imageIdentifier ) : Image
$imageIdentifier string The image identifier
Результат Image

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

Set the metadata
public setMetadata ( array $metadata ) : Image
$metadata array An array with metadata
Результат Image

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

Set the mime type
public setMimeType ( string $mimeType ) : Image
$mimeType string The mime type, for instance "image/png"
Результат Image

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

Set the original checksum
public setOriginalChecksum ( $checksum ) : Image
Результат Image

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

Set the updated date
public setUpdatedDate ( DateTime $updated ) : Image
$updated DateTime When the image was updated
Результат Image

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

Set the user
public setUser ( string $user ) : Image
$user string The user
Результат Image

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

Set the width
public setWidth ( integer $width ) : Image
$width integer Width in pixels
Результат Image

supportedMimeType() публичный статический Метод

Check if a mime type is supported by Imbo
public static supportedMimeType ( string $mime ) : boolean
$mime string The mime type to check. For instance "image/png"
Результат boolean

Описание свойств

$mimeTypeMapping публичное статическое свойство

Mapping for some mime types
public static array $mimeTypeMapping
Результат array

$mimeTypes публичное статическое свойство

Supported mime types and the correct file extensions
public static array $mimeTypes
Результат array