PHP Class PhpBench\Benchmark\RunnerContext

显示文件 Open project: dantleech/phpbench Class Usage Examples

Public Methods

Method Description
__construct ( string $path, array $options = [] )
getContextName ( ) : string Return the name to assign to this suite.
getExecutor ( ) : string | array Return either an executor configuration name or an actual configuration.
getFilters ( ) Whitelist of subject method names.
getGroups ( ) : string[] Whitelist of groups to execute.
getIterations ( $default = null ) : integer Override the number of iterations to execute.
getOutputTimePrecision ( $default = null ) : string Return the output time precision.
getOutputTimeUnit ( $default = null ) : string Return the output time unit.
getParameterSets ( $default = null ) : mixed[] Override parameters.
getPath ( ) : string Return the path underwhich to scan for benchmarks.
getRetryThreshold ( $default = null ) : float Get the deviation threshold beyond which the iteration should be retried.
getRevolutions ( integer $default = null ) Get the number of rev(olutions) to run.
getSleep ( $default = null ) Override the sleep interval (in microseconds).
getStopOnError ( ) Return true if the runner should exit on the first exception encountered.
getWarmup ( integer $default = null ) Return the number of warmup revolutions that should be exectuted.

Method Details

__construct() public method

public __construct ( string $path, array $options = [] )
$path string
$options array

getContextName() public method

NOTE: Do not confuse this with this context class. It is simply an arbitrary identifier to identify the suite when doing a comparison.
public getContextName ( ) : string
return string

getExecutor() public method

Return either an executor configuration name or an actual configuration.
public getExecutor ( ) : string | array
return string | array

getFilters() public method

Whitelist of subject method names.
public getFilters ( )

getGroups() public method

Whitelist of groups to execute.
public getGroups ( ) : string[]
return string[]

getIterations() public method

Override the number of iterations to execute.
public getIterations ( $default = null ) : integer
return integer

getOutputTimePrecision() public method

Return the output time precision.
public getOutputTimePrecision ( $default = null ) : string
return string

getOutputTimeUnit() public method

Return the output time unit.
public getOutputTimeUnit ( $default = null ) : string
return string

getParameterSets() public method

Override parameters.
public getParameterSets ( $default = null ) : mixed[]
return mixed[]

getPath() public method

Return the path underwhich to scan for benchmarks.
public getPath ( ) : string
return string

getRetryThreshold() public method

A value of NULL will disable retry.
public getRetryThreshold ( $default = null ) : float
return float

getRevolutions() public method

Get the number of rev(olutions) to run.
public getRevolutions ( integer $default = null )
$default integer

getSleep() public method

Override the sleep interval (in microseconds).
public getSleep ( $default = null )

getStopOnError() public method

Return true if the runner should exit on the first exception encountered.
public getStopOnError ( )

getWarmup() public method

Return the number of warmup revolutions that should be exectuted.
public getWarmup ( integer $default = null )
$default integer