function Mapper::isUserDefinedMethod
Throws
1 call to Mapper::isUserDefinedMethod()
- Mapper::stringToCodeUnits in vendor/
sebastian/ code-unit/ src/ Mapper.php
File
-
vendor/
sebastian/ code-unit/ src/ Mapper.php, line 233
Class
Namespace
SebastianBergmann\CodeUnitCode
private function isUserDefinedMethod(string $className, string $methodName) : bool {
if (!class_exists($className)) {
// @codeCoverageIgnoreStart
return false;
// @codeCoverageIgnoreEnd
}
if (!method_exists($className, $methodName)) {
// @codeCoverageIgnoreStart
return false;
// @codeCoverageIgnoreEnd
}
try {
return (new ReflectionMethod($className, $methodName))->isUserDefined();
// @codeCoverageIgnoreStart
} catch (\ReflectionException $e) {
throw new ReflectionException($e->getMessage(), $e->getCode(), $e);
}
// @codeCoverageIgnoreEnd
}