-
Notifications
You must be signed in to change notification settings - Fork 20
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
Adds date comparison methods #533
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reformat and new methods would have been better in two commits. And for the relatively simple methods, is it really worth to use a helper class? (Referring to the use of Range
)
Range comes from Google, and we hope to have a better alternative one day. And since we already provide a Dates class, it kinda suits for it. PS: sorry for the reformat. |
Hmm, for instance, Extending the |
It was a suggestion from a chat with @sabieber a while ago. I will review that... |
Description
Unfortunately Java's standard methods do not provide
afterOrEqual
orbeforeOrEqual
, nor a range check.Note that we are leaving null-handling for the caller to decide, as it strongly depends on usage: am empty date might represent an infinite date in the past or in the future, or represent an exception.
Checklist