Package com.codingchili.core.protocol
Class OpenAPIGenerator
java.lang.Object
com.codingchili.core.protocol.OpenAPIGenerator
Template for generating valid OpenAPI 3 definitions, see https://apidevtools.org/swagger-parser/online/
-
Constructor Summary
-
Method Summary
-
Constructor Details
-
OpenAPIGenerator
public OpenAPIGenerator()
-
-
Method Details
-
toYaml
- Parameters:
protocol
- the protocol instance to generate an API definition from.- Returns:
- a YAML OpenAPI v3 schema generated from a protocol.
- See Also:
toJson(Protocol)
-
toJson
Generates OpenAPI v3 compatible definitions from the given protocol. The information is retrieved using protocol metadata, registered using the documentation API or with protocol annotations. Reflection may also be used to retrieve additional information.- Parameters:
protocol
- the protocol instance to generate an API definition from.- Returns:
- a YAML OpenAPI v3 schema generated from a protocol.
-
main
-