Class RestDslGenerator<G>
java.lang.Object
org.apache.camel.generator.openapi.RestDslGenerator<G>
- Direct Known Subclasses:
RestDslDefinitionGenerator,RestDslSourceCodeGenerator,RestDslXmlGenerator,RestDslYamlGenerator
Source code and
RestsDefinition generator that generates Camel REST DSL implementations from OpenAPI
specifications.-
Method Summary
Modifier and TypeMethodDescriptionstatic StringdetermineBasePathFrom(io.swagger.v3.oas.models.OpenAPI document) static StringdetermineBasePathFrom(String parameter) static StringdetermineBasePathFrom(String parameter, io.swagger.v3.oas.models.OpenAPI document) static StringdetermineHostFrom(io.swagger.v3.oas.models.OpenAPI document) static StringgenerateToYaml(org.apache.camel.CamelContext camelContext, File path) static StringresolveVariablesIn(String url, io.swagger.v3.oas.models.servers.Server server) static RestDslSourceCodeGenerator<Appendable> toAppendable(io.swagger.v3.oas.models.OpenAPI document) static RestDslDefinitionGeneratortoDefinition(io.swagger.v3.oas.models.OpenAPI document) static RestDslSourceCodeGenerator<Filer> toFiler(io.swagger.v3.oas.models.OpenAPI document) static RestDslSourceCodeGenerator<Path> toPath(io.swagger.v3.oas.models.OpenAPI document) static RestDslXmlGeneratortoXml(io.swagger.v3.oas.models.OpenAPI document) static RestDslYamlGeneratortoYaml(io.swagger.v3.oas.models.OpenAPI document) static RestDslYamlGeneratorwithApiContextPath(String contextPath) withBasePath(String basePath) withDestinationGenerator(DestinationGenerator destinationGenerator) withDestinationToSyntax(String destinationToSyntax) Syntax to use for to uri.withDtoPackageName(String dtoPackageName) withOperationFilter(String include) withOperationFilter(org.apache.camel.generator.openapi.OperationFilter filter) withRestComponent(String restComponent) withRestContextPath(String contextPath)
-
Method Details
-
asSpringBootProject
-
asSpringComponent
-
withApiContextPath
-
withClientRequestValidation
-
withBasePath
-
withDestinationGenerator
-
withDestinationToSyntax
Syntax to use for to uri. The default is direct:${operationId} -
withOperationFilter
-
withOperationFilter
-
withRestComponent
-
withRestContextPath
-
withDtoPackageName
-
determineBasePathFrom
-
determineBasePathFrom
-
determineBasePathFrom
-
determineHostFrom
-
resolveVariablesIn
-
toAppendable
public static RestDslSourceCodeGenerator<Appendable> toAppendable(io.swagger.v3.oas.models.OpenAPI document) -
toDefinition
-
toFiler
-
toPath
-
toXml
-
toYaml
-
toYaml
-
generateToYaml
public static String generateToYaml(org.apache.camel.CamelContext camelContext, File path) throws Exception - Throws:
Exception
-