PHP Class PhpBrew\PatchKit\RegExpPatchRule

Inheritance: implements PhpBrew\PatchKit\PatchRule
Exibir arquivo Open project: phpbrew/phpbrew Class Usage Examples

Public Methods

Method Description
__construct ( array $files )
allOf ( array $patterns ) This method build up the predicator.
always ( )
anyOf ( array $patterns )
apply ( PhpBrew\Buildable $build, CLIFramework\Logger $logger )
backup ( PhpBrew\Buildable $build, CLIFramework\Logger $logger )
files ( $files )
replaces ( $pattern, $replacement )

Protected Methods

Method Description
applyLines ( array $lines, &$patched )
applyTextContent ( string $content, &$patched ) This method can only be used for text format files.
backupFile ( $path )

Method Details

__construct() public method

public __construct ( array $files )
$files array

allOf() public method

This method build up the predicator.
public allOf ( array $patterns )
$patterns array

always() public method

public always ( )

anyOf() public method

public anyOf ( array $patterns )
$patterns array

apply() public method

public apply ( PhpBrew\Buildable $build, CLIFramework\Logger $logger )
$build PhpBrew\Buildable
$logger CLIFramework\Logger

applyLines() protected method

protected applyLines ( array $lines, &$patched )
$lines array

applyTextContent() protected method

This method can only be used for text format files.
protected applyTextContent ( string $content, &$patched )
$content string the target of the text content.

backup() public method

public backup ( PhpBrew\Buildable $build, CLIFramework\Logger $logger )
$build PhpBrew\Buildable
$logger CLIFramework\Logger

backupFile() protected method

protected backupFile ( $path )

files() public static method

public static files ( $files )

replaces() public method

public replaces ( $pattern, $replacement )