interface PluginInterface
Plugin interface
@author Nils Adermann <naderman@naderman.de>
Hierarchy
- interface \Composer\Plugin\PluginInterface
Expanded class hierarchy of PluginInterface
All classes that implement PluginInterface
10 files declare their use of PluginInterface
- Locker.php in vendor/
composer/ composer/ src/ Composer/ Package/ Locker.php - MessagePlugin.php in composer/
Plugin/ ProjectMessage/ MessagePlugin.php - PlatformRepository.php in vendor/
composer/ composer/ src/ Composer/ Repository/ PlatformRepository.php - Plugin.php in vendor/
dealerdirect/ phpcodesniffer-composer-installer/ src/ Plugin.php - Plugin.php in vendor/
phpstan/ extension-installer/ src/ Plugin.php
File
-
vendor/
composer/ composer/ src/ Composer/ Plugin/ PluginInterface.php, line 23
Namespace
Composer\PluginView source
interface PluginInterface {
/**
* Version number of the internal composer-plugin-api package
*
* This is used to denote the API version of Plugin specific
* features, but is also bumped to a new major if Composer
* includes a major break in internal APIs which are susceptible
* to be used by plugins.
*
* @var string
*/
public const PLUGIN_API_VERSION = '2.6.0';
/**
* Apply plugin modifications to Composer
*
* @return void
*/
public function activate(Composer $composer, IOInterface $io);
/**
* Remove any hooks from Composer
*
* This will be called when a plugin is deactivated before being
* uninstalled, but also before it gets upgraded to a new version
* so the old one can be deactivated and the new one activated.
*
* @return void
*/
public function deactivate(Composer $composer, IOInterface $io);
/**
* Prepare the plugin to be uninstalled
*
* This will be called after deactivate.
*
* @return void
*/
public function uninstall(Composer $composer, IOInterface $io);
}
Members
Title Sort descending | Modifiers | Object type | Summary | Overrides |
---|---|---|---|---|
PluginInterface::activate | public | function | Apply plugin modifications to Composer | 8 |
PluginInterface::deactivate | public | function | Remove any hooks from Composer | 8 |
PluginInterface::PLUGIN_API_VERSION | public | constant | Version number of the internal composer-plugin-api package | |
PluginInterface::uninstall | public | function | Prepare the plugin to be uninstalled | 8 |