src/Generator/InputGeneratorTrait.php
protected function createParameters(Operation $operation, $queryParamDocumentation, Context $context)
    {
        $documentationParams = [];
        $methodParameters = [];

        if ($operation->getOperation()->getParameters()) {
            foreach ($operation->getOperation()->getParameters() as $key => $parameter) {
                if ($parameter instanceof Reference) {
                    $parameter = $this->resolveParameter($parameter);
                }

                if ($parameter instanceof PathParameterSubSchema) {
                    $methodParameters[] = $this->pathParameterGenerator->generateMethodParameter($parameter, $context, $operation->getReference() . '/parameters/' . $key);
                    $documentationParams[] = sprintf(' * @param %s', $this->pathParameterGenerator->generateDocParameter($parameter, $context, $operation->getReference() . '/parameters/' . $key));
                }
            }

            foreach ($operation->getOperation()->getParameters() as $key => $parameter) {
                if ($parameter instanceof Reference) {
                    $parameter = $this->resolveParameter($parameter);
                }

                if ($parameter instanceof BodyParameter) {
                    $methodParameters[] = $this->bodyParameterGenerator->generateMethodParameter($parameter, $context, $operation->getReference() . '/parameters/' . $key);
                    $documentationParams[] = sprintf(' * @param %s', $this->bodyParameterGenerator->generateDocParameter($parameter, $context, $operation->getReference() . '/parameters/' . $key));
                }
            }
        }

        if (!empty($queryParamDocumentation)) {
            $documentationParams[] = " * @param array  \$parameters {";
            $documentationParams   = array_merge($documentationParams, array_map(function ($doc) {
                return " *     " . $doc;
            }, $queryParamDocumentation));
            $documentationParams[] = " * }";
        } else {
            $documentationParams[] = " * @param array  \$parameters List of parameters";
        }

        $documentationParams[] = " * @param string \$fetch      Fetch mode (object or response)";

        $methodParameters[] = new Param('parameters', new Expr\Array_());
        $methodParameters[] = new Param('fetch', new Expr\ConstFetch(new Name('self::FETCH_OBJECT')));

        return [$documentationParams, $methodParameters];
    }
protected function createParameters(Operation $operation, $queryParamDocumentation, Context $context)
    {
        $documentationParams = [];
        $methodParameters = [];

        if ($operation->getOperation()->getParameters()) {
            foreach ($operation->getOperation()->getParameters() as $key => $parameter) {
                if ($parameter instanceof Reference) {
                    $parameter = $this->resolveParameter($parameter);
                }

                if ($parameter instanceof PathParameterSubSchema) {
                    $methodParameters[] = $this->pathParameterGenerator->generateMethodParameter($parameter, $context, $operation->getReference() . '/parameters/' . $key);
                    $documentationParams[] = sprintf(' * @param %s', $this->pathParameterGenerator->generateDocParameter($parameter, $context, $operation->getReference() . '/parameters/' . $key));
                }
            }

            foreach ($operation->getOperation()->getParameters() as $key => $parameter) {
                if ($parameter instanceof Reference) {
                    $parameter = $this->resolveParameter($parameter);
                }

                if ($parameter instanceof BodyParameter) {
                    $methodParameters[] = $this->bodyParameterGenerator->generateMethodParameter($parameter, $context, $operation->getReference() . '/parameters/' . $key);
                    $documentationParams[] = sprintf(' * @param %s', $this->bodyParameterGenerator->generateDocParameter($parameter, $context, $operation->getReference() . '/parameters/' . $key));
                }
            }
        }

        if (!empty($queryParamDocumentation)) {
            $documentationParams[] = " * @param array  \$parameters {";
            $documentationParams   = array_merge($documentationParams, array_map(function ($doc) {
                return " *     " . $doc;
            }, $queryParamDocumentation));
            $documentationParams[] = " * }";
        } else {
            $documentationParams[] = " * @param array  \$parameters List of parameters";
        }

        $documentationParams[] = " * @param string \$fetch      Fetch mode (object or response)";

        $methodParameters[] = new Param('parameters', new Expr\Array_());
        $methodParameters[] = new Param('fetch', new Expr\ConstFetch(new Name('self::FETCH_OBJECT')));

        return [$documentationParams, $methodParameters];
    }
Create parameters for the method and their documentation

@param Operation $operation
@param string[]  $queryParamDocumentation
@param Context   $context

@return array