PHP Class PartKeepr\ImageBundle\Services\ImageService

Inheritance: extends PartKeepr\UploadedFileBundle\Services\UploadedFileService
Show file Open project: partkeepr/PartKeepr Class Usage Examples

Public Methods

Method Description
canHandleMimetype ( $mimeType ) : boolean Checks if the system can handle the given mime type as image. Currently hardcoded for GD.
invalidate ( UploadedFile $file ) Invalidates any cached files.
replaceFromFilesystem ( UploadedFile $file, File $filesystemFile )

Method Details

canHandleMimetype() public method

Checks if the system can handle the given mime type as image. Currently hardcoded for GD.
public canHandleMimetype ( $mimeType ) : boolean
$mimeType The mime type to check
return boolean True if the system can display images of the given mimetype, false otherwise

invalidate() public method

Invalidates any cached files.
public invalidate ( UploadedFile $file )
$file PartKeepr\UploadedFileBundle\Entity\UploadedFile The file to invalidate

replaceFromFilesystem() public method

public replaceFromFilesystem ( UploadedFile $file, File $filesystemFile )
$file PartKeepr\UploadedFileBundle\Entity\UploadedFile
$filesystemFile Symfony\Component\HttpFoundation\File\File