yxorP Documentation

ShopwareInstaller extends BaseInstaller
in package

Plugin/theme installer for shopware

Tags
author

Benjamin Boit

Table of Contents

$composer  : mixed
$io  : mixed
$locations  : mixed
$package  : mixed
__construct()  : mixed
Initializes base installer.
getInstallPath()  : string
Return the install path based on package type.
getLocations()  : array<string, string>
Gets the installer's locations
inflectPackageVars()  : array<string|int, mixed>
Transforms the names
mapCustomInstallPaths()  : string|false
Search through a passed paths array for a custom install path.
templatePath()  : string
Replace vars in a path
correctPluginName()  : array<string|int, mixed>
Changes the name to a camelcased combination of vendor and name
correctThemeName()  : array<string|int, mixed>
Changes the name to a underscore separated name

Properties

$locations

protected mixed $locations = array('backend-plugin' => 'engine/Shopware/Plugins/Local/Backend/{$name}/', 'core-plugin' => 'engine/Shopware/Plugins/Local/Core/{$name}/', 'frontend-plugin' => 'engine/Shopware/Plugins/Local/Frontend/{$name}/', 'theme' => 'templates/{$name}/', 'plugin' => 'custom/plugins/{$name}/', 'frontend-theme' => 'themes/Frontend/{$name}/')

Methods

__construct()

Initializes base installer.

public __construct([PackageInterface $package = null ][, Composer $composer = null ][, IOInterface $io = null ]) : mixed
Parameters
$package : PackageInterface = null
$composer : Composer = null
$io : IOInterface = null
Return values
mixed

getInstallPath()

Return the install path based on package type.

public getInstallPath(PackageInterface $package[, string $frameworkType = '' ]) : string
Parameters
$package : PackageInterface
$frameworkType : string = ''
Return values
string

getLocations()

Gets the installer's locations

public getLocations() : array<string, string>
Return values
array<string, string>

map of package types => install path

inflectPackageVars()

Transforms the names

public inflectPackageVars(array<string|int, mixed> $vars) : array<string|int, mixed>
Parameters
$vars : array<string|int, mixed>
Return values
array<string|int, mixed>

mapCustomInstallPaths()

Search through a passed paths array for a custom install path.

protected mapCustomInstallPaths(array<string|int, mixed> $paths, string $name, string $type[, string $vendor = NULL ]) : string|false
Parameters
$paths : array<string|int, mixed>
$name : string
$type : string
$vendor : string = NULL

= NULL

Return values
string|false

templatePath()

Replace vars in a path

protected templatePath(string $path[, array<string, string> $vars = array() ]) : string
Parameters
$path : string
$vars : array<string, string> = array()
Return values
string

correctPluginName()

Changes the name to a camelcased combination of vendor and name

private correctPluginName(array<string|int, mixed> $vars) : array<string|int, mixed>
Parameters
$vars : array<string|int, mixed>
Return values
array<string|int, mixed>

correctThemeName()

Changes the name to a underscore separated name

private correctThemeName(array<string|int, mixed> $vars) : array<string|int, mixed>
Parameters
$vars : array<string|int, mixed>
Return values
array<string|int, mixed>

Search results