CopyFromRecipeConfigurator
extends AbstractConfigurator
in package
Tags
Table of Contents
Properties
Methods
- __construct() : mixed
- configure() : mixed
- unconfigure() : mixed
- update() : void
- extractSection() : string|null
- isFileMarked() : bool
- isFileXmlMarked() : bool
- markData() : string
- markXmlData() : string
- updateData() : bool
- updateDataString() : string|null
- write() : mixed
- copyDir() : array<string|int, mixed>
- copyFile() : string
- copyFiles() : array<string|int, mixed>
- getLocalFilePath() : string
- getRemovableFilesFromRecipeAndLock() : array<string|int, mixed>
- removeFile() : mixed
- removeFiles() : mixed
Properties
$composer
protected
mixed
$composer
$io
protected
mixed
$io
$options
protected
mixed
$options
$path
protected
mixed
$path
Methods
__construct()
public
__construct(Composer $composer, IOInterface $io, Options $options) : mixed
Parameters
- $composer : Composer
- $io : IOInterface
- $options : Options
configure()
public
configure(Recipe $recipe, mixed $config, Lock $lock[, array<string|int, mixed> $options = [] ]) : mixed
Parameters
unconfigure()
public
unconfigure(Recipe $recipe, mixed $config, Lock $lock) : mixed
Parameters
update()
public
update(RecipeUpdate $recipeUpdate, array<string|int, mixed> $originalConfig, array<string|int, mixed> $newConfig) : void
Parameters
- $recipeUpdate : RecipeUpdate
- $originalConfig : array<string|int, mixed>
- $newConfig : array<string|int, mixed>
extractSection()
protected
extractSection(Recipe $recipe, string $contents) : string|null
Parameters
- $recipe : Recipe
- $contents : string
Return values
string|nullisFileMarked()
protected
isFileMarked(Recipe $recipe, string $file) : bool
Parameters
- $recipe : Recipe
- $file : string
Return values
boolisFileXmlMarked()
protected
isFileXmlMarked(Recipe $recipe, string $file) : bool
Parameters
- $recipe : Recipe
- $file : string
Return values
boolmarkData()
protected
markData(Recipe $recipe, string $data) : string
Parameters
- $recipe : Recipe
- $data : string
Return values
stringmarkXmlData()
protected
markXmlData(Recipe $recipe, string $data) : string
Parameters
- $recipe : Recipe
- $data : string
Return values
stringupdateData()
protected
updateData(string $file, string $data) : bool
Parameters
- $file : string
- $data : string
Return values
bool —True if section was found and replaced
updateDataString()
protected
updateDataString(string $contents, string $data) : string|null
Parameters
- $contents : string
- $data : string
Return values
string|null —returns the updated content if the section was found, null if not found
write()
protected
write(mixed $messages[, mixed $verbosity = IOInterface::VERBOSE ]) : mixed
Parameters
- $messages : mixed
- $verbosity : mixed = IOInterface::VERBOSE
copyDir()
private
copyDir(string $source, string $target, array<string|int, mixed> $files, array<string|int, mixed> $options) : array<string|int, mixed>
Parameters
- $source : string
- $target : string
- $files : array<string|int, mixed>
- $options : array<string|int, mixed>
Return values
array<string|int, mixed>copyFile()
private
copyFile(string $to, string $contents, bool $executable, array<string|int, mixed> $options) : string
Parameters
- $to : string
- $contents : string
- $executable : bool
- $options : array<string|int, mixed>
Return values
stringcopyFiles()
private
copyFiles(array<string|int, mixed> $manifest, array<string|int, mixed> $files, array<string|int, mixed> $options) : array<string|int, mixed>
Parameters
- $manifest : array<string|int, mixed>
- $files : array<string|int, mixed>
- $options : array<string|int, mixed>
Return values
array<string|int, mixed>getLocalFilePath()
private
getLocalFilePath(string $basePath, mixed $destination) : string
Parameters
- $basePath : string
- $destination : mixed
Return values
stringgetRemovableFilesFromRecipeAndLock()
private
getRemovableFilesFromRecipeAndLock(Recipe $recipe, Lock $lock) : array<string|int, mixed>
Parameters
Return values
array<string|int, mixed>removeFile()
private
removeFile(string $to) : mixed
Parameters
- $to : string
removeFiles()
private
removeFiles(array<string|int, mixed> $manifest, array<string|int, mixed> $files, string $to) : mixed
Parameters
- $manifest : array<string|int, mixed>
- $files : array<string|int, mixed>
- $to : string