Package org.apache.camel.openapi
Class RestOpenApiReader
- java.lang.Object
-
- org.apache.camel.openapi.RestOpenApiReader
-
public class RestOpenApiReader extends Object
A Camel REST-DSL openApi reader that parse the rest-dsl into a openApi model representation. This reader supports the OpenApi Specification 2.0 and 3.0
-
-
Field Summary
Fields Modifier and Type Field Description static String
OAS20_SCHEMA_DEFINITION_PREFIX
static String
OAS30_SCHEMA_DEFINITION_PREFIX
-
Constructor Summary
Constructors Constructor Description RestOpenApiReader()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description io.apicurio.datamodels.openapi.models.OasDocument
read(org.apache.camel.CamelContext camelContext, List<org.apache.camel.model.rest.RestDefinition> rests, BeanConfig config, String camelContextId, org.apache.camel.spi.ClassResolver classResolver)
Read the REST-DSL definition's and parse that as a OpenApi model representation
-
-
-
Field Detail
-
OAS20_SCHEMA_DEFINITION_PREFIX
public static final String OAS20_SCHEMA_DEFINITION_PREFIX
- See Also:
- Constant Field Values
-
OAS30_SCHEMA_DEFINITION_PREFIX
public static final String OAS30_SCHEMA_DEFINITION_PREFIX
- See Also:
- Constant Field Values
-
-
Method Detail
-
read
public io.apicurio.datamodels.openapi.models.OasDocument read(org.apache.camel.CamelContext camelContext, List<org.apache.camel.model.rest.RestDefinition> rests, BeanConfig config, String camelContextId, org.apache.camel.spi.ClassResolver classResolver) throws ClassNotFoundException
Read the REST-DSL definition's and parse that as a OpenApi model representation- Parameters:
camelContext
- the camel contextrests
- the rest-dslconfig
- the openApi configurationclassResolver
- class resolver to use @return the openApi model- Throws:
ClassNotFoundException
- is thrown if error loading class
-
-