jelixModuleUpgrader
extends Installer
in package
Base class for classes that does processing to install a module into an instance of the application. A module should have a class that inherits from it in order to setup itself into the application.
Tags
Table of Contents
- $date : string
- $defaultDbProfile : string
- $parameters : array<string|int, mixed>
- parameters for the installer, indicated in the configuration file or dynamically, by a launcher in a command line for instance.
- $targetVersions : array<string|int, mixed>
- the versions for which the installer should be called.
- $version : string
- $componentName : string
- $name : string
- $path : string
- The path of the module.
- __construct() : mixed
- getDate() : mixed
- getDefaultDbProfile() : mixed
- getModuleName() : mixed
- getName() : mixed
- getParameter() : mixed
- getParameters() : mixed
- {@inheritdoc}
- getPath() : mixed
- getTargetVersions() : mixed
- getVersion() : mixed
- install() : mixed
- Should configure the module.
- postInstall() : mixed
- Redefine this method if you do some additional process after the installation of all modules.
- preInstall() : mixed
- Called before the installation of any modules.
- setParameters() : mixed
- {@inheritdoc}
- setTargetVersions() : mixed
- setVersion() : mixed
Properties
$date
protected
string
$date
= ''
the date of the release of the update. format: yyyy-mm-dd hh:ii
$defaultDbProfile
protected
string
$defaultDbProfile
= ''
the default profile name for the component, if it exist. keep it to '' if not
$parameters
parameters for the installer, indicated in the configuration file or dynamically, by a launcher in a command line for instance.
protected
array<string|int, mixed>
$parameters
= array()
$targetVersions
the versions for which the installer should be called.
protected
array<string|int, mixed>
$targetVersions
= array()
Useful for an upgrade which target multiple branches of a project. Put the version for multiple branches. The installer will be called only once, for the needed version. If you don't fill it, the name of the class file should contain the target version (deprecated behavior though)
list of version by asc order
$version
protected
string
$version
= '0'
the version for which the installer is called
$componentName
private
string
$componentName
name of the component
$name
private
string
$name
name of the installer
$path
The path of the module.
private
string
$path
Methods
__construct()
public
__construct(string $componentName, string $name, string $path, string $version[, bool $installWholeApp = true ]) : mixed
Parameters
- $componentName : string
-
name of the component
- $name : string
-
name of the installer
- $path : string
-
the component path
- $version : string
-
version of the component
- $installWholeApp : bool = true
-
deprecated
Return values
mixed —getDate()
public
getDate() : mixed
Return values
mixed —getDefaultDbProfile()
public
getDefaultDbProfile() : mixed
Return values
mixed —getModuleName()
public
final getModuleName() : mixed
Return values
mixed —getName()
public
final getName() : mixed
Return values
mixed —getParameter()
public
final getParameter(mixed $name) : mixed
Parameters
- $name : mixed
Return values
mixed —getParameters()
{@inheritdoc}
public
final getParameters() : mixed
Return values
mixed —getPath()
public
final getPath() : mixed
Return values
mixed —getTargetVersions()
public
getTargetVersions() : mixed
Return values
mixed —getVersion()
public
getVersion() : mixed
Return values
mixed —install()
Should configure the module.
public
install(InstallHelpers $helpers) : mixed
Parameters
- $helpers : InstallHelpers
Return values
mixed —postInstall()
Redefine this method if you do some additional process after the installation of all modules.
public
postInstall(InstallHelpers $helpers) : mixed
Parameters
- $helpers : InstallHelpers
Return values
mixed —preInstall()
Called before the installation of any modules.
public
preInstall(PreInstallHelpers $helpers) : mixed
Parameters
- $helpers : PreInstallHelpers
Return values
mixed —setParameters()
{@inheritdoc}
public
final setParameters(mixed $parameters) : mixed
Parameters
- $parameters : mixed
Return values
mixed —setTargetVersions()
public
setTargetVersions(mixed $versions) : mixed
Parameters
- $versions : mixed
Return values
mixed —setVersion()
public
setVersion(mixed $version) : mixed
Parameters
- $version : mixed