Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

private/model/api: Generate enum shape functions to retrieve all values #3447

Merged
merged 4 commits into from
Aug 11, 2020

Conversation

bflad
Copy link
Contributor

@bflad bflad commented Jul 29, 2020

Closes #3441

Allows consumers to easily retrieve all values of an enumeration shape.

Maintainer note: Happy to change this to the non-idiomatic _Values() naming if desired.

@jasdel jasdel self-requested a review August 3, 2020 21:06
Copy link
Contributor

@jasdel jasdel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for taking the time to create this PR @bflad. The codegeneration change looks good, but in order to ensure this doesn't have conflicts in the future i think we'll have to go down the route of EnumType_Values naming for this utility. If an API ever modeled an enum member named Values then the idiomatic generation pattern would conflict.

@jasdel
Copy link
Contributor

jasdel commented Aug 6, 2020

Will also want to rebase, but we can update that too before merge, so you don't have to worry about chasing the SDK's API updates.

@bflad
Copy link
Contributor Author

bflad commented Aug 7, 2020

Switched to _Values and rebased. 👍

@bflad bflad force-pushed the f-enum-values-funcs branch 2 times, most recently from bcb40de to 8b3f250 Compare August 7, 2020 23:15
@jasdel jasdel self-requested a review August 10, 2020 17:15
Copy link
Contributor

@jasdel jasdel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for making the update @bflad . We'll rebase and regenerate the API models after the API model update later today, and merge with the latest version of the SDK.

@jasdel jasdel force-pushed the f-enum-values-funcs branch 2 times, most recently from 42df8e0 to c80db5d Compare August 10, 2020 23:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Feature Request] Functionality to Retrieve All Enumeration Values
2 participants