Composer\Installers
BaseInstaller::mapCustomInstallPaths() protected WC 1.0
Search through a passed paths array for a custom install path.
{} Это метод класса: BaseInstaller{}
Хуков нет.
Возвращает
Строку/false.
Использование
// protected - в коде основоного (родительского) или дочернего класса $result = $this->mapCustomInstallPaths( $paths, $name, $type, $vendor );
- $paths(массив) (обязательный)
- -
- $name(строка) (обязательный)
- -
- $type(строка) (обязательный)
- -
- $vendor(строка)
- = NULL
Код BaseInstaller::mapCustomInstallPaths() BaseInstaller::mapCustomInstallPaths WC 5.0.0
protected function mapCustomInstallPaths(array $paths, $name, $type, $vendor = NULL)
{
foreach ($paths as $path => $names) {
$names = (array) $names;
if (in_array($name, $names) || in_array('type:' . $type, $names) || in_array('vendor:' . $vendor, $names)) {
return $path;
}
}
return false;
}