PHP Class PDepend\TextUI\Runner

Show file Open project: pdepend/pdepend Class Usage Examples

Public Methods

Method Description
__construct ( PDepend\Report\ReportGeneratorFactory $reportGeneratorFactory, Engine $engine )
addOption ( string $identifier, string | array $value ) : void Adds a logger or analyzer option.
addProcessListener ( PDepend\ProcessListener $processListener ) : void Adds a process listener instance that will be hooked into PDepend's analyzing process.
addReportGenerator ( string $generatorId, string $reportFile ) : void Adds a logger to this runner.
getParseErrors ( ) : array(string) This method will return an array with error messages for all failures that happened during the parsing process.
hasParseErrors ( ) : boolean This method will return true when there were errors during the parse process.
run ( ) : boolean Starts the main PDepend process and returns true after a successful execution.
setExcludeDirectories ( array $excludeDirectories ) : void Sets a list of exclude directories.
setExcludeNamespaces ( array $excludePackages ) : void Sets a list of exclude packages.
setFileExtensions ( array $extensions ) : void Sets a list of allowed file extensions.
setSourceArguments ( array $sourceArguments ) : void Sets a list of source directories and files.
setWithoutAnnotations ( ) : void Should the parser ignore doc comment annotations?

Method Details

__construct() public method

public __construct ( PDepend\Report\ReportGeneratorFactory $reportGeneratorFactory, Engine $engine )
$reportGeneratorFactory PDepend\Report\ReportGeneratorFactory
$engine PDepend\Engine

addOption() public method

Adds a logger or analyzer option.
public addOption ( string $identifier, string | array $value ) : void
$identifier string
$value string | array
return void

addProcessListener() public method

Adds a process listener instance that will be hooked into PDepend's analyzing process.
public addProcessListener ( PDepend\ProcessListener $processListener ) : void
$processListener PDepend\ProcessListener
return void

addReportGenerator() public method

Adds a logger to this runner.
public addReportGenerator ( string $generatorId, string $reportFile ) : void
$generatorId string
$reportFile string
return void

getParseErrors() public method

This method will return an array with error messages for all failures that happened during the parsing process.
public getParseErrors ( ) : array(string)
return array(string)

hasParseErrors() public method

This method will return true when there were errors during the parse process.
public hasParseErrors ( ) : boolean
return boolean

run() public method

Starts the main PDepend process and returns true after a successful execution.
public run ( ) : boolean
return boolean

setExcludeDirectories() public method

NOTE: If this method is called, it will overwrite the default settings.
public setExcludeDirectories ( array $excludeDirectories ) : void
$excludeDirectories array
return void

setExcludeNamespaces() public method

Sets a list of exclude packages.
public setExcludeNamespaces ( array $excludePackages ) : void
$excludePackages array
return void

setFileExtensions() public method

NOTE: If you call this method, it will replace the default file extensions.
public setFileExtensions ( array $extensions ) : void
$extensions array
return void

setSourceArguments() public method

Sets a list of source directories and files.
public setSourceArguments ( array $sourceArguments ) : void
$sourceArguments array
return void

setWithoutAnnotations() public method

Should the parser ignore doc comment annotations?
public setWithoutAnnotations ( ) : void
return void