-
Notifications
You must be signed in to change notification settings - Fork 41.3k
Refactor and polish with Java 8 idioms #9781
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
Conversation
I've separated each refactor in different commits so the review can be focused on that particular improvement. I can squash them all if you prefer. |
@philwebb @wilkinsona if you think that this PR could be considered at some point I can keep this branch up to date. If you want to reduce the scope of it or just discard it altogether please let me know. |
Where possible, explicit generic declarations to use the Java 8 diamond operator. See gh-9781
Replace existing `Collections.sort(...)` calls with `.sort(...)` directly on the collection instance. See gh-9781
Use multi-catch for exceptions whenever possible. See gh-9781
Update existing try/finally/close blocks to use "try with resources" See gh-9781
Replace anonymous inner classes with lambda declarations (when possible using method references). See gh-9781
…-idioms * pr/9781: Simplify comparator implementation Use lambdas when possible Replace try with try-with-resources Collapse catch clauses Replace Collections.sort() with direct sort call Replace explicit generics with diamond operator
Thanks very much for the PR. This has been merged to master with some changes. |
No description provided.