/** * @param ReflectionClass $reflectionClass * @param bool $isDocumented * @param array $methods * @return ReflectionMethodMagic[] */ private function extractOwnFromClass(ReflectionClass $reflectionClass, $isDocumented, array $methods) { foreach ($reflectionClass->getOwnMagicMethods() as $method) { if ($this->canBeExtracted($isDocumented, $methods, $method)) { $methods[$method->getName()] = $method; } } return $methods; }