Skip to content

Conversation

@jmarkerink
Copy link

I hope you are appropriating this refactoring with strong typing.

I have modeled the supported/implemented commands in a enumeration and wrapped it in a value object so we can retrieve the original query command string because of the case insensitivity.

Some benefits:

  • compile-time safety - typos are caught at compile time
  • documentation - enum serves as documentation of all supported commands
  • performance - single toLowerCase() with HashMap lookup

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.

1 participant