PHP Class BetterReflection\Util\FindReflectionOnLine

Exibir arquivo Open project: roave/better-reflection

Public Methods

Method Description
__invoke ( string $filename, integer $lineNumber ) : BetterReflection\Reflection\ReflectionMethod | ReflectionClass | BetterReflection\Reflection\ReflectionFunction | null Find a reflection on the specified line number.

Private Methods

Method Description
computeReflections ( string $filename ) : BetterReflection\Reflection\Reflection[] Find all class and function reflections in the specified file
containsLine ( mixed $reflection, integer $lineNumber ) : boolean Check to see if the line is within the boundaries of the reflection specified.

Method Details

__invoke() public method

Returns null if no reflections found on the line.
public __invoke ( string $filename, integer $lineNumber ) : BetterReflection\Reflection\ReflectionMethod | ReflectionClass | BetterReflection\Reflection\ReflectionFunction | null
$filename string
$lineNumber integer
return BetterReflection\Reflection\ReflectionMethod | BetterReflection\Reflection\ReflectionClass | BetterReflection\Reflection\ReflectionFunction | null