‪TYPO3CMS  ‪main
TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService Class Reference
Inheritance diagram for TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService:
TYPO3\CMS\Core\SingletonInterface

Public Member Functions

 __construct (RemoteRegistry $remoteRegistry, FileHandlingUtility $fileHandlingUtility)
 
 injectEventDispatcher (EventDispatcherInterface $eventDispatcher)
 
 injectDownloadQueue (DownloadQueue $downloadQueue)
 
 injectDependencyUtility (DependencyUtility $dependencyUtility)
 
 injectInstallUtility (InstallUtility $installUtility)
 
 markExtensionForInstallation ($extensionKey)
 
 markExtensionForDownload (Extension $extension)
 
 markExtensionForUpdate (Extension $extension)
 
 setSkipDependencyCheck ($skipDependencyCheck)
 
 setAutomaticInstallationEnabled ($automaticInstallationEnabled)
 
bool array installExtension (Extension $extension)
 
array getDependencyErrors ()
 
Extension getExtension ($extensionKey)
 
bool isAvailable ($extensionKey)
 
 reloadPackageInformation ($extensionKey)
 
array getAndResolveDependencies (Extension $extension)
 
 downloadMainExtension (Extension $extension)
 
 setDownloadPath (string $downloadPath)
 

Protected Member Functions

bool checkDependencies (Extension $extension)
 
array uninstallDependenciesToBeUpdated (array $updateQueue)
 
array installDependencies (array $installQueue)
 
array downloadDependencies (array $downloadQueue)
 
 rawDownload (Extension $extension)
 

Protected Attributes

DownloadQueue $downloadQueue
 
DependencyUtility $dependencyUtility
 
InstallUtility $installUtility
 
bool $automaticInstallationEnabled = true
 
bool $skipDependencyCheck = false
 
EventDispatcherInterface $eventDispatcher
 
FileHandlingUtility $fileHandlingUtility
 
RemoteRegistry $remoteRegistry
 
string $downloadPath = 'Local'
 

Detailed Description

Service class for managing multiple step processes (dependencies for example)

Definition at line 35 of file ExtensionManagementService.php.

Constructor & Destructor Documentation

◆ __construct()

TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::__construct ( RemoteRegistry  $remoteRegistry,
FileHandlingUtility  $fileHandlingUtility 
)

Member Function Documentation

◆ checkDependencies()

bool TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::checkDependencies ( Extension  $extension)
protected

Check dependencies for an extension and its required extensions

Returns
‪bool Returns TRUE if all dependencies can be resolved, otherwise FALSE

Definition at line 256 of file ExtensionManagementService.php.

Referenced by TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService\installExtension().

◆ downloadDependencies()

array TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::downloadDependencies ( array  $downloadQueue)
protected

◆ downloadMainExtension()

TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::downloadMainExtension ( Extension  $extension)

Downloads the extension the user wants to install This is separated from downloading the dependencies as an extension is able to provide it's own dependencies

Definition at line 343 of file ExtensionManagementService.php.

References TYPO3\CMS\Extbase\DomainObject\DomainObjectInterface\getUid(), and TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService\rawDownload().

Referenced by TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService\installExtension().

◆ getAndResolveDependencies()

array TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::getAndResolveDependencies ( Extension  $extension)

Get and resolve dependencies

Returns
‪array

Definition at line 327 of file ExtensionManagementService.php.

◆ getDependencyErrors()

array TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::getDependencyErrors ( )

Returns the unresolved dependency errors

Returns
‪array

Definition at line 211 of file ExtensionManagementService.php.

◆ getExtension()

Extension TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::getExtension (   $extensionKey)

◆ injectDependencyUtility()

TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::injectDependencyUtility ( DependencyUtility  $dependencyUtility)

◆ injectDownloadQueue()

TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::injectDownloadQueue ( DownloadQueue  $downloadQueue)

◆ injectEventDispatcher()

TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::injectEventDispatcher ( EventDispatcherInterface  $eventDispatcher)

◆ injectInstallUtility()

TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::injectInstallUtility ( InstallUtility  $installUtility)

◆ installDependencies()

array TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::installDependencies ( array  $installQueue)
protected

Install dependent extensions

Returns
‪array

Definition at line 286 of file ExtensionManagementService.php.

Referenced by TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService\installExtension().

◆ installExtension()

◆ isAvailable()

bool TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::isAvailable (   $extensionKey)

Checks if an extension is available in the system

Parameters
string$extensionKey
Returns
‪bool

Definition at line 234 of file ExtensionManagementService.php.

◆ markExtensionForDownload()

TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::markExtensionForDownload ( Extension  $extension)

Mark an extension for download

Definition at line 115 of file ExtensionManagementService.php.

◆ markExtensionForInstallation()

TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::markExtensionForInstallation (   $extensionKey)

◆ markExtensionForUpdate()

TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::markExtensionForUpdate ( Extension  $extension)

Definition at line 125 of file ExtensionManagementService.php.

◆ rawDownload()

◆ reloadPackageInformation()

TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::reloadPackageInformation (   $extensionKey)
Parameters
string$extensionKey
Exceptions

Definition at line 246 of file ExtensionManagementService.php.

◆ setAutomaticInstallationEnabled()

TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::setAutomaticInstallationEnabled (   $automaticInstallationEnabled)
Parameters
bool$automaticInstallationEnabled

Definition at line 146 of file ExtensionManagementService.php.

References TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService\$automaticInstallationEnabled.

◆ setDownloadPath()

TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::setDownloadPath ( string  $downloadPath)

◆ setSkipDependencyCheck()

TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::setSkipDependencyCheck (   $skipDependencyCheck)

Enables or disables the dependency check for system environment (PHP, TYPO3) before extension installation

Parameters
bool$skipDependencyCheck

Definition at line 138 of file ExtensionManagementService.php.

References TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService\$skipDependencyCheck.

◆ uninstallDependenciesToBeUpdated()

array TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::uninstallDependenciesToBeUpdated ( array  $updateQueue)
protected

Uninstall extensions that will be updated This is not strictly necessary but cleaner all in all

Parameters
Extension[]$updateQueue
Returns
‪array

Definition at line 271 of file ExtensionManagementService.php.

Referenced by TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService\installExtension().

Member Data Documentation

◆ $automaticInstallationEnabled

bool TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::$automaticInstallationEnabled = true
protected

◆ $dependencyUtility

DependencyUtility TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::$dependencyUtility
protected

◆ $downloadPath

string TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::$downloadPath = 'Local'
protected

◆ $downloadQueue

DownloadQueue TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::$downloadQueue
protected

◆ $eventDispatcher

EventDispatcherInterface TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::$eventDispatcher
protected

◆ $fileHandlingUtility

FileHandlingUtility TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::$fileHandlingUtility
protected

◆ $installUtility

InstallUtility TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::$installUtility
protected

◆ $remoteRegistry

RemoteRegistry TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::$remoteRegistry
protected

◆ $skipDependencyCheck

bool TYPO3\CMS\Extensionmanager\Service\ExtensionManagementService::$skipDependencyCheck = false
protected