PHP Class Eloquent\Phony\Mock\Builder\Method\CustomMethodDefinition

Inheritance: implements Eloquent\Phony\Mock\Builder\Method\MethodDefinition
Show file Open project: eloquent/phony

Public Methods

Method Description
__construct ( boolean $isStatic, string $name, callable $callback, ReflectionFunctionAbstract $method ) Construct a new custom method definition.
accessLevel ( ) : string Get the access level.
callback ( ) : callable | null Get the callback.
isCallable ( ) : boolean Returns true if this method is callable.
isCustom ( ) : boolean Returns true if this method is custom.
isStatic ( ) : boolean Returns true if this method is static.
method ( ) : ReflectionFunctionAbstract Get the method.
name ( ) : string Get the name.

Method Details

__construct() public method

Construct a new custom method definition.
public __construct ( boolean $isStatic, string $name, callable $callback, ReflectionFunctionAbstract $method )
$isStatic boolean True if this method is static.
$name string The name.
$callback callable The callback.
$method ReflectionFunctionAbstract The function implementation.

accessLevel() public method

Get the access level.
public accessLevel ( ) : string
return string The access level.

callback() public method

Get the callback.
public callback ( ) : callable | null
return callable | null The callback, or null if this is a real method.

isCallable() public method

Returns true if this method is callable.
public isCallable ( ) : boolean
return boolean True if this method is callable.

isCustom() public method

Returns true if this method is custom.
public isCustom ( ) : boolean
return boolean True if this method is custom.

isStatic() public method

Returns true if this method is static.
public isStatic ( ) : boolean
return boolean True if this method is static.

method() public method

Get the method.
public method ( ) : ReflectionFunctionAbstract
return ReflectionFunctionAbstract The method.

name() public method

Get the name.
public name ( ) : string
return string The name.