OXID eShop CE
6.1.5
|
Public Member Functions | |
__call ($method, $args) | |
getImagePath ($absPath=false) | |
outputImage () | |
Static Public Member Functions | |
static | getInstance () |
Protected Member Functions | |
_getShopBasePath () | |
_getImageUri () | |
_getImageName () | |
_getImageMasterPath () | |
_getImageInfo () | |
_getImageTarget () | |
_getNopicImageTarget () | |
_getImageType () | |
_generatePng ($source, $target, $width, $height) | |
_generateJpg ($source, $target, $width, $height, $quality) | |
_generateGif ($source, $target, $width, $height) | |
_isTargetPathValid ($path) | |
_createFolders ($dir) | |
_isValidPath ($path) | |
_generateImage ($imageSource, $imageTarget) | |
_getLockName ($name) | |
_lock ($source) | |
_unlock ($source) | |
validateImageFileExtension ($fileExtension) | |
_setHeader ($header) | |
_getHeaders () | |
validateGdVersion () | |
validateFileExist ($filePath) | |
getImageDimensions ($imageFilePath) | |
Protected Attributes | |
$_aHeaders = [] | |
$_aAllowedImgTypes = ["jpg", "jpeg", "png", "gif"] | |
$_sImageInfoSep = "_" | |
$_hLockHandle = null | |
$_sImageUri = null | |
$_aConfParamToPath | |
Static Protected Attributes | |
static | $_oInstance = null |
Image generator class
OxidEsales\EshopCommunity\Core\DynamicImageGenerator::__call | ( | $method, | |
$args | |||
) |
Only used for convenience in UNIT tests by doing so we avoid writing extended classes for testing protected or private methods
string | $method | Methods name |
array | $args | Argument array |
|
protected |
Checks if valid and creates missing needed folders
string | $dir | folder(s) to create |
|
protected |
Generates GIF type image and returns its location on file system
string | $source | image source |
string | $target | image target |
int | $width | image width |
int | $height | image height |
|
protected |
Converts a given source image into a target image
string | $imageSource | File path of the source image |
string | $imageTarget | File path of the image to be generated |
OxidEsales |
|
protected |
Generates JPG type image and returns its location on file system
string | $source | image source |
string | $target | image target |
int | $width | image width |
int | $height | image height |
int | $quality | new image quality |
|
protected |
Generates PNG type image and returns its location on file system
string | $source | image source |
string | $target | image target |
int | $width | image width |
int | $height | image height |
|
protected |
Return headers array
|
protected |
Returns image info array
|
protected |
Returns path to possible master image
|
protected |
Returns requested image name
|
protected |
Returns full requested image path on file system
|
protected |
Returns image type used for image generation and header setting
|
protected |
Returns requested image uri
|
protected |
Returns lock file name
string | $name | original file name |
|
protected |
Nopic image path
|
protected |
Returns shops base path
|
protected |
Checks if requested image path is valid. If path is valid but is not created - creates directory structure
string | $path | image path name to check |
|
protected |
Checks if main folder matches requested
string | $path | image path name to check |
|
protected |
Locks file and returns locking state
string | $source | source file which should be locked |
|
protected |
Custom header setter
string | $header | header |
|
protected |
Deletes lock file
string | $source | source file which should be locked |
|
protected |
Return an array with the dimensions (width x height) of an image file. returns array (0,0), if the dimensions could not be retrieved.
string | $imageFilePath |
OxidEsales\EshopCommunity\Core\DynamicImageGenerator::getImagePath | ( | $absPath = false | ) |
Returns the file path of an image as requested by self::_getImageUri(). If the requested image does not exist, if will be rendered from the master image. If the master image does not exist, a nopic image in the same directory as the requested image is shown. If the nopic image does not exist, it will be generated in with the same dimensions and quality as the requested image. If the nopic image does not exist, the method returns false.
bool | $absPath | absolute requested image path (not url, but real path on file system) |
|
static |
Creates and returns picture generator instance
OxidEsales\EshopCommunity\Core\DynamicImageGenerator::outputImage | ( | ) |
Creates and outputs requested image. If source file was not found - tries to render related "nopic.jpg". If "nopic.jpg" is not available - sends 404 header to browser
|
protected |
Return true, if a given file path exists.
string | $filePath |
|
protected |
Return true, if the version of the gd library is correct
|
protected |
string | $fileExtension | Extension to be validated. Validation is case insensitive. |
|
protected |
|
protected |
|
protected |
|
protected |
|
staticprotected |
|
protected |
|
protected |