- array_map: documentation ( source)
- var_dump: documentation ( source)
<?php
class Foo {
public function fooPublic()
{
}
public static function fooStatic()
{
}
}
$ref = new ReflectionClass('Foo');
//var_dump($ref->getMethods(ReflectionMethod::IS_PUBLIC));
var_dump(array_map(function(\ReflectionMethod $method) { return $method->getName(); }, $ref->getMethods(\ReflectionMethod::IS_PUBLIC & ~\ReflectionMethod::IS_STATIC)));