Skip to content

Modernize codebase with Java improvements #2277

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

Open
wants to merge 8 commits into
base: master
Choose a base branch
from

Conversation

gnodet
Copy link
Contributor

@gnodet gnodet commented Apr 25, 2025

This PR includes several improvements to modernize the codebase:

  1. Replace IllegalArgumentException with ClassCastException for type cast failures
  2. Replace IllegalArgumentException with NullPointerException for null checks
  3. Use modern Java collections API (toList() instead of collect(Collectors.toList()))
  4. Replace custom null checks with Objects.requireNonNull
  5. Add @nonnull and @nullable annotations throughout the codebase

These changes make the code more maintainable, safer, and aligned with modern Java practices.

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