Class OpenApiTransformer

    • Method Detail

      • execute

        public static io.swagger.models.Swagger execute​(LocalizableString title,
                                                        String host,
                                                        String basePath,
                                                        boolean secure,
                                                        ApiDescription apiDescription,
                                                        ApiDescription... externalApiDescriptions)
        Transforms an ApiDescription into a Swagger model.
        Parameters:
        title - API title
        host - Hostname or IP address, with optional port
        basePath - Base-path on host
        secure - true when host is using HTTPS and false when using HTTP
        apiDescription - CREST API Descriptor
        externalApiDescriptions - External CREST API Descriptions, for resolving References, or null
        Returns:
        Swagger model
      • execute

        public static io.swagger.models.Swagger execute​(ApiDescription apiDescription,
                                                        ApiDescription... externalApiDescriptions)
        Transforms an ApiDescription into a Swagger model.

        Note: The returned descriptor does not contain an Info object, a base path, a host or a scheme, as these will all depend on the deployment and/or request.

        Parameters:
        apiDescription - CREST API Descriptor
        externalApiDescriptions - External CREST API Descriptions, for resolving References, or null
        Returns:
        Swagger model