PHP » GoLang |
login |
register |
about
|
GoLang ReflectionClass::getMethods
request it (346)
GoLang replacement for PHP's ReflectionClass::getMethods
[edit | history]
PHP ReflectionClass::getMethodsPHP original manual for ReflectionClass::getMethods [ show | php.net ]ReflectionClass::getMethods(PHP 5, PHP 7) ReflectionClass::getMethods — Gets an array of methods Description
public array ReflectionClass::getMethods
([ int
$filter
] )Gets an array of methods for the class. Parameters
Return ValuesAn array of ReflectionMethod objects reflecting each method. Examples
Example #1 Basic usage of ReflectionClass::getMethods()
<?php The above example will output: array(3) { [0]=> &object(ReflectionMethod)#2 (2) { ["name"]=> string(11) "firstMethod" ["class"]=> string(5) "Apple" } [1]=> &object(ReflectionMethod)#3 (2) { ["name"]=> string(12) "secondMethod" ["class"]=> string(5) "Apple" } [2]=> &object(ReflectionMethod)#4 (2) { ["name"]=> string(11) "thirdMethod" ["class"]=> string(5) "Apple" } }
Example #2 Filtering results from ReflectionClass::getMethods()
<?php The above example will output: array(2) { [0]=> &object(ReflectionMethod)#2 (2) { ["name"]=> string(12) "secondMethod" ["class"]=> string(5) "Apple" } [1]=> &object(ReflectionMethod)#3 (2) { ["name"]=> string(11) "thirdMethod" ["class"]=> string(5) "Apple" } } See Also
|
more
Recently updated
more
Most requested
more
Last requests
|