Skip to content

Add extra safety to unmarshaling to enums.#38

Merged
broady merged 1 commit intogooglemaps:masterfrom
broady:unknown
Oct 3, 2014
Merged

Add extra safety to unmarshaling to enums.#38
broady merged 1 commit intogooglemaps:masterfrom
broady:unknown

Conversation

@broady
Copy link
Copy Markdown
Contributor

@broady broady commented Oct 3, 2014

Removes existing TravelModeAdapter, AddressTypeAdapter and AddressComponentTypeAdapter, replaces them with generic SafeEnumAdapter.

Add tests that check converting UNKNOWN to a UrlValue throws an exception.

@broady
Copy link
Copy Markdown
Contributor Author

broady commented Oct 3, 2014

Fixes #30 and #31 better.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Cheeky. The style guide says no (but I say yes).

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Me too.

@markmcd
Copy link
Copy Markdown
Contributor

markmcd commented Oct 3, 2014

LGTM

@domesticmouse
Copy link
Copy Markdown
Contributor

lgtm

Removes existing TravelModeAdapter, AddressTypeAdapter and AddressComponentTypeAdapter, replaces them with generic SafeEnumAdapter.

Add tests that check converting UNKNOWN to a UrlValue throws an exception.
broady added a commit that referenced this pull request Oct 3, 2014
Add extra safety to unmarshaling to enums.
@broady broady merged commit 0a2ee82 into googlemaps:master Oct 3, 2014
@broady broady mentioned this pull request Oct 16, 2014
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.

3 participants