NelmioApiDocBundle/Describer/ApiPlatformDescriber.php

26 lines
721 B
PHP
Raw Normal View History

2016-07-29 10:22:40 +02:00
<?php
/*
* This file is part of the ApiDocBundle package.
*
* (c) EXSyst
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace EXSyst\Bundle\ApiDocBundle\Describer;
use ApiPlatform\Core\Documentation\Documentation;
use ApiPlatform\Core\Swagger\DocumentationNormalizer;
class ApiPlatformDescriber extends ExternalDocDescriber
{
public function __construct(Documentation $documentation, DocumentationNormalizer $normalizer, bool $overwrite = false)
{
parent::__construct(function () use ($documentation, $normalizer) {
return $normalizer->normalize($documentation);
}, $overwrite);
}
}