You are here

public function ApiSpecificationController::title in OpenAPI 8

Same name and namespace in other branches
  1. 8.2 src/Controller/ApiSpecificationController.php \Drupal\openapi\Controller\ApiSpecificationController::title()

Gets the OpenAPI output in JSON format.

Return value

string The page title.

1 string reference to 'ApiSpecificationController::title'
openapi.routing.yml in ./openapi.routing.yml
openapi.routing.yml

File

src/Controller/ApiSpecificationController.php, line 21

Class

ApiSpecificationController
API Specification controller base.

Namespace

Drupal\openapi\Controller

Code

public function title(OpenApiGeneratorInterface $generator, Request $request) {
  return $this
    ->t('%label OpenApi Schema Download', [
    '%label' => $generator
      ->getLabel(),
  ]);
}