Suggestion for Enum name cleanup logic #2495
Labels
enhancement
New feature or request
generator
Issues or improvements relater to generation capabilities.
Milestone
Currently Enum name cleanup follows the same naming cleanup logic as classes for example, meaning invalid characters like ':' are just removed.
But Enum names are generally important to keep as defined in the OpenAPI spec and Kiota shouldn't take much responsability on itself to change the names defined in the specification. The only motivation for change could be to remove or replace invalid characters. Here are a few examples for discussion
1.
In example 1, the invalid characters should be replaced with _, as doing anything else requires changing the case of the whole name to keep the visual separation and namespacing and it quickly becomes an impossible logic. Keeping the uppercase naming in this example is a good idea.
In example 2, again the invalid characters should be replaced with _. Also, here its good idea to keep the lowercase naming.
In example 3, the names could be transformed to pascal case but it could also stay the same, so that the cleanup logic could be kept the same.
In example 4, the names could be transformed to pascal case but it could also stay the same, so that the cleanup logic could be kept the same.
The text was updated successfully, but these errors were encountered: