KnowledgeCaptureAndDiscovery / OBA

Ontology based APIs
Apache License 2.0
38 stars 12 forks source link

Refactor configuration/option flags from config file. Add placeholder flags for (property) array generation and PATCH path #178

Closed cweedall closed 6 months ago

cweedall commented 7 months ago

After adding default_descriptions and default_properties flags, I had an idea to have a flag for enabling/disabling generation of examples (mostly helpful when checking that ontology/OpenAPI spec are as desired).

Based on another PR, I plan to add a flag for flipping between arrays or single type/value properties.

Given that some additional flags may also be desired in the future, I thought we could improve the way these flags are passed around in the code. After some investigation, it appeared that creating a map in the YamlConfig class with an enum flag CONFIG_FLAG for the key and a Boolean value would be the best. Then, whenever we need a value, we can grab it from the config variable.

dgarijo commented 6 months ago

Will have a look by next week (I am on holidays this week). Looking promising!