Better access into schema contents #357
Labels
enhancement
New feature in an existing library
openapi-support
Tasks that support OpenApi.Net
pkg:schema
Users could benefit from being able to access the data contained in the schema a bit more easily.
Add an extension
.Get<T>() where T : IJsonSchemaKeyword
to get the indicated keyword.This can open the door to a set of extensions that directly get the values of the spec-defined keywords, e.g.
.GetTitle()
.Additionally, I would like to explore using a dictionary to store the keywords by name instead of in a list. (The
Keywords
property would be a forwarded property to theValues
collection on the keyword, so no breakages.)This would make accessing keywords faster.
The text was updated successfully, but these errors were encountered: