TYPO3 CMS  TYPO3_7-6
TYPO3\CMS\Install\Configuration\Image\AbstractImagePreset Class Reference
Inheritance diagram for TYPO3\CMS\Install\Configuration\Image\AbstractImagePreset:
TYPO3\CMS\Install\Configuration\AbstractPreset TYPO3\CMS\Install\Configuration\PresetInterface TYPO3\CMS\Install\Configuration\Image\GraphicsMagickPreset TYPO3\CMS\Install\Configuration\Image\ImageMagick6Preset

Public Member Functions

 getFoundPath ()
 
 isActive ()
 
 isAvailable ()
 
 getConfigurationValues ()
 
- Public Member Functions inherited from TYPO3\CMS\Install\Configuration\AbstractPreset
 injectConfigurationManager (\TYPO3\CMS\Core\Configuration\ConfigurationManager $configurationManager)
 
 setPostValues (array $postValues)
 
 getIsAvailable ()
 
 isActive ()
 
 getIsActive ()
 
 getName ()
 
 getPriority ()
 
 getConfigurationValues ()
 

Protected Member Functions

 findExecutableInPath (array $searchPaths)
 
 getSearchPaths ()
 
 cleanUpPath ($path)
 

Protected Attributes

 $defaultExecutableSearchPaths
 
 $foundPath = ''
 
- Protected Attributes inherited from TYPO3\CMS\Install\Configuration\AbstractPreset
 $configurationManager = null
 
 $name = ''
 
 $priority = 50
 
 $configurationValues = []
 
 $postValues = []
 

Detailed Description

Abstract class implements common image preset code

Definition at line 22 of file AbstractImagePreset.php.

Member Function Documentation

◆ cleanUpPath()

TYPO3\CMS\Install\Configuration\Image\AbstractImagePreset::cleanUpPath (   $path)
protected

Consolidate between Windows and Unix and add trailing slash im missing

Parameters
string$pathGiven path
Returns
string Cleaned up path

Definition at line 151 of file AbstractImagePreset.php.

References TYPO3\CMS\Core\Utility\GeneralUtility\fixWindowsFilePath().

Referenced by TYPO3\CMS\Install\Configuration\Image\AbstractImagePreset\getSearchPaths().

◆ findExecutableInPath()

TYPO3\CMS\Install\Configuration\Image\AbstractImagePreset::findExecutableInPath ( array  $searchPaths)
abstractprotected

Find executable in path, wrapper for specific ImageMagick/GraphicsMagick find methods.

Parameters
array$searchPaths
Returns
mixed

Referenced by TYPO3\CMS\Install\Configuration\Image\AbstractImagePreset\getConfigurationValues(), and TYPO3\CMS\Install\Configuration\Image\AbstractImagePreset\isAvailable().

◆ getConfigurationValues()

◆ getFoundPath()

TYPO3\CMS\Install\Configuration\Image\AbstractImagePreset::getFoundPath ( )

Path where executable was found

Returns
string Fonud path

Definition at line 49 of file AbstractImagePreset.php.

References TYPO3\CMS\Install\Configuration\Image\AbstractImagePreset\$foundPath.

Referenced by TYPO3\CMS\Install\Configuration\Image\AbstractImagePreset\getConfigurationValues().

◆ getSearchPaths()

TYPO3\CMS\Install\Configuration\Image\AbstractImagePreset::getSearchPaths ( )
protected

◆ isActive()

TYPO3\CMS\Install\Configuration\Image\AbstractImagePreset::isActive ( )

Check is preset is currently active on the system. Overwrites parent method to ignore im_path and im_path_lzw settings

Returns
bool TRUE if preset is active

Implements TYPO3\CMS\Install\Configuration\PresetInterface.

Definition at line 60 of file AbstractImagePreset.php.

◆ isAvailable()

TYPO3\CMS\Install\Configuration\Image\AbstractImagePreset::isAvailable ( )

Find out if GraphicsMagick is available

Returns
bool TRUE if GraphicsMagick executable is found in path

Implements TYPO3\CMS\Install\Configuration\PresetInterface.

Definition at line 82 of file AbstractImagePreset.php.

References TYPO3\CMS\Install\Configuration\Image\AbstractImagePreset\findExecutableInPath(), and TYPO3\CMS\Install\Configuration\Image\AbstractImagePreset\getSearchPaths().

Member Data Documentation

◆ $defaultExecutableSearchPaths

TYPO3\CMS\Install\Configuration\Image\AbstractImagePreset::$defaultExecutableSearchPaths
protected
Initial value:
= [
'/usr/local/bin/',
'/opt/local/bin/',
'/usr/bin/',
'/usr/X11R6/bin/',
'/opt/bin/',
'C:/php/ImageMagick/',
'C:/php/GraphicsMagick/',
'C:/apache/ImageMagick/',
'C:/apache/GraphicsMagick/',
]

Definition at line 27 of file AbstractImagePreset.php.

Referenced by TYPO3\CMS\Install\Configuration\Image\AbstractImagePreset\getSearchPaths().

◆ $foundPath

TYPO3\CMS\Install\Configuration\Image\AbstractImagePreset::$foundPath = ''
protected