src/Bridge/Symfony/Bundle/DependencyInjection/ApiPlatformExtension.php
private function registerSwaggerConfiguration(ContainerBuilder $container, array $config, XmlFileLoader $loader): void
    {
        if (!$config['enable_swagger']) {
            return;
        }

        $loader->load('swagger.xml');

        if ($config['enable_swagger_ui'] || $config['enable_re_doc']) {
            $loader->load('swagger-ui.xml');
            $container->setParameter('api_platform.enable_swagger_ui', $config['enable_swagger_ui']);
            $container->setParameter('api_platform.enable_re_doc', $config['enable_re_doc']);
        }

        $container->setParameter('api_platform.enable_swagger', $config['enable_swagger']);
        $container->setParameter('api_platform.swagger.api_keys', $config['swagger']['api_keys']);
    }
private function registerSwaggerConfiguration(ContainerBuilder $container, array $config, XmlFileLoader $loader): void
    {
        if (!$config['enable_swagger']) {
            return;
        }

        $loader->load('swagger.xml');

        if ($config['enable_swagger_ui'] || $config['enable_re_doc']) {
            $loader->load('swagger-ui.xml');
            $container->setParameter('api_platform.enable_swagger_ui', $config['enable_swagger_ui']);
            $container->setParameter('api_platform.enable_re_doc', $config['enable_re_doc']);
        }

        $container->setParameter('api_platform.enable_swagger', $config['enable_swagger']);
        $container->setParameter('api_platform.swagger.api_keys', $config['swagger']['api_keys']);
    }
private function registerSwaggerConfiguration ( ContainerBuilder $ container , array $ config , XmlFileLoader $ loader ) : void { if ( ! $ config [ 'enable_swagger' ] ) { return ; } $ loader -> load ( 'swagger.xml' ) ; if ( $ config [ 'enable_swagger_ui' ] || $ config [ 'enable_re_doc' ] ) { $ loader -> load ( 'swagger-ui.xml' ) ; $ container -> setParameter ( 'api_platform.enable_swagger_ui' , $ config [ 'enable_swagger_ui' ] ) ; $ container -> setParameter ( 'api_platform.enable_re_doc' , $ config [ 'enable_re_doc' ] ) ; } $ container -> setParameter ( 'api_platform.enable_swagger' , $ config [ 'enable_swagger' ] ) ; $ container -> setParameter ( 'api_platform.swagger.api_keys' , $ config [ 'swagger' ] [ 'api_keys' ] ) ; }
Registers the Swagger, ReDoc and Swagger UI configuration.
Registers the Swagger ReDoc and Swagger UI configuration .