commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Henri Yandell (JIRA)" <>
Subject [jira] Closed: (LANG-400) Add DateUtils methods to implement before and after time-insensitive
Date Sun, 19 Jul 2009 19:11:14 GMT


Henri Yandell closed LANG-400.

       Resolution: Won't Fix
    Fix Version/s:     (was: 3.0)
                   Commons Time?

Closing and pointing to JODA Time. Setting fix version to "Commons Time?".

> Add DateUtils methods to implement before and after time-insensitive
> --------------------------------------------------------------------
>                 Key: LANG-400
>                 URL:
>             Project: Commons Lang
>          Issue Type: New Feature
>    Affects Versions: 2.3
>            Reporter: Paul Benedict
>             Fix For: Commons Time?
> The JDK contains Date.before() and Date.after() but no time-insensitive versions exist.
I am typically in the situation where TIMESTAMP columns are converted into Date instances
and I need to compare dates only for business rules.
> I propose to complement DateUtils.isSameDay:
> DateUtils.isBeforeDay
> DateUtils.isAfterDay
> My private implementations convert Date to Calendar, zero-out the time elements, and
then compare.
> PS: I would also deprecate isSameXXX methods in 2.4 and rename it to isEqualXXX since
sameness usually implies instance equality, rather than object equality.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message