| @@ 41-49 (lines=9) @@ | ||
| 38 | * @param $method |
|
| 39 | * @return mixed |
|
| 40 | */ |
|
| 41 | public function reflectionMethodInvoke( $class, $method ) |
|
| 42 | { |
|
| 43 | $reflection = new \ReflectionMethod( $class, $method ); |
|
| 44 | $reflection->setAccessible( true ); |
|
| 45 | if (is_string($class)) { |
|
| 46 | $class = null; |
|
| 47 | } |
|
| 48 | return $reflection->invoke( $class ); |
|
| 49 | } |
|
| 50 | ||
| 51 | /** |
|
| 52 | * @param $class |
|
| @@ 57-65 (lines=9) @@ | ||
| 54 | * @param $args |
|
| 55 | * @return mixed |
|
| 56 | */ |
|
| 57 | public function reflectionMethodInvokeArgs( $class, $method, $args ) |
|
| 58 | { |
|
| 59 | $reflection = new \ReflectionMethod( $class, $method ); |
|
| 60 | $reflection->setAccessible( true ); |
|
| 61 | if (is_string($class)) { |
|
| 62 | $class = null; |
|
| 63 | } |
|
| 64 | return $reflection->invoke( $class, $args ); |
|
| 65 | } |
|
| 66 | ||
| 67 | /** |
|
| 68 | * @return string |
|