Class 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

    • Constructor Detail

      • RestOpenApiReader

        public RestOpenApiReader()
    • 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 context
        rests - the rest-dsl
        config - the openApi configuration
        classResolver - class resolver to use @return the openApi model
        Throws:
        ClassNotFoundException - is thrown if error loading class