CenterEdge / Yardarm

OpenAPI 3 SDK Generator for C#
Apache License 2.0
46 stars 6 forks source link

Generate correct code for parameter components #243

Closed brantburnett closed 3 months ago

brantburnett commented 3 months ago

The current code for parameter components fails because it can't generate a source file path for embedding. Also, it results in duplicate schema generation if there are references to schemas from the parameters and can have name conflicts between these schemas.

Instead, generate parameter classes only in cases where a nested schema needs to be generated and nest the schema inside that class. This also addresses the source file name problem since there is a type name to use as the basis for the file name.

Relates to #239

brantburnett commented 3 months ago

/merge