private function completeArgumentFromTypeHint(Argument $arg, ReflectionMethod $method, ReflectionParameter $param, DocBlockReader $docBlock): void
    {
        if (!$arg->getName()) {
            $arg->setName($param->getName());
        }

        if (!$arg->getDescription()) {
            $arg->setDescription($docBlock->getParameterDescription($param));
        }

        if (!$arg->hasDefaultValue() && $param->isDefaultValueAvailable()) {
            $arg->setDefaultValue($param->getDefaultValue());
        }

        $this->completeArgumentTypeFromTypeHint($arg, $method, $param, $docBlock);
    }
private function completeArgumentFromTypeHint(Argument $arg, ReflectionMethod $method, ReflectionParameter $param, DocBlockReader $docBlock): void
    {
        if (!$arg->getName()) {
            $arg->setName($param->getName());
        }

        if (!$arg->getDescription()) {
            $arg->setDescription($docBlock->getParameterDescription($param));
        }

        if (!$arg->hasDefaultValue() && $param->isDefaultValueAvailable()) {
            $arg->setDefaultValue($param->getDefaultValue());
        }

        $this->completeArgumentTypeFromTypeHint($arg, $method, $param, $docBlock);
    }
private function completeArgumentFromTypeHint ( Argument $ arg , ReflectionMethod $ method , ReflectionParameter $ param , DocBlockReader $ docBlock ) : void { if ( ! $ arg -> getName ( ) ) { $ arg -> setName ( $ param -> getName ( ) ) ; } if ( ! $ arg -> getDescription ( ) ) { $ arg -> setDescription ( $ docBlock -> getParameterDescription ( $ param ) ) ; } if ( ! $ arg -> hasDefaultValue ( ) && $ param -> isDefaultValueAvailable ( ) ) { $ arg -> setDefaultValue ( $ param -> getDefaultValue ( ) ) ; } $ this -> completeArgumentTypeFromTypeHint ( $ arg , $ method , $ param , $ docBlock ) ; }
Complete a single argument from its type hint

@param Argument $arg
@param ReflectionMethod $method
@param ReflectionParameter $param
@param DocBlockReader $docBlock
Complete a single argument from its type hint