PHPSA\ScopePointer::isFunction PHP Method

isFunction() public method

Is the object a function?
public isFunction ( ) : boolean
return boolean
    public function isFunction()
    {
        return $this->object instanceof FunctionDefinition;
    }

Usage Example

Example #1
0
 /**
  * @covers \PHPSA\ScopePointer::isFunction()
  * @dataProvider notFunctionDataProvider
  */
 public function testIsNotFunction($object)
 {
     $scopePointer = new ScopePointer($object);
     $this->assertFalse($scopePointer->isFunction());
 }