You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Jonathan Locke (JIRA)" <ji...@apache.org> on 2007/05/28 02:56:16 UTC

[jira] Issue Created: (WICKET-595) TimeOfDay.next(Calendar) can return time on same day rather than next day

TimeOfDay.next(Calendar) can return time on same day rather than next day
-------------------------------------------------------------------------

 common.concepts.key: WICKET-595
 common.concepts.url: https://issues.apache.org/jira/browse/WICKET-595
common.concepts.project: Wicket
common.concepts.issuetype: Bug
common.concepts.components: wicket
    Affects Versions: 1.3.0-beta1
issue.field.reporter: Jonathan Locke
issue.field.priority: Minor
common.concepts.fixfor: 1.3.0-beta2


Currently code does:

			calendar.add(Calendar.DATE, 1);
			return Time.valueOf(calendar, this);

Because Time.valueOf(Calendar, TimeOfDay) always returns the time on the same day, the add is ignored.  Instead this code should be the time of day today plus one day like this:

			return Time.valueOf(calendar, this).add(Duration.ONE_DAY);



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


[jira] Updated: (WICKET-595) TimeOfDay.next(Calendar) can return time on same day rather than next day

Posted by "Alastair Maw (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/WICKET-595?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Alastair Maw updated WICKET-595:
--------------------------------

    Assignee: Jonathan Locke

> TimeOfDay.next(Calendar) can return time on same day rather than next day
> -------------------------------------------------------------------------
>
>                 Key: WICKET-595
>                 URL: https://issues.apache.org/jira/browse/WICKET-595
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket
>    Affects Versions: 1.3.0-beta1
>            Reporter: Jonathan Locke
>            Assignee: Jonathan Locke
>            Priority: Minor
>             Fix For: 1.3.0-beta2
>
>
> Currently code does:
> 			calendar.add(Calendar.DATE, 1);
> 			return Time.valueOf(calendar, this);
> Because Time.valueOf(Calendar, TimeOfDay) always returns the time on the same day, the add is ignored.  Instead this code should be the time of day today plus one day like this:
> 			return Time.valueOf(calendar, this).add(Duration.ONE_DAY);

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


[jira] Resolved: (WICKET-595) TimeOfDay.next(Calendar) can return time on same day rather than next day

Posted by "Alastair Maw (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/WICKET-595?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Alastair Maw resolved WICKET-595.
---------------------------------

    Resolution: Fixed

> TimeOfDay.next(Calendar) can return time on same day rather than next day
> -------------------------------------------------------------------------
>
>                 Key: WICKET-595
>                 URL: https://issues.apache.org/jira/browse/WICKET-595
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket
>    Affects Versions: 1.3.0-beta1
>            Reporter: Jonathan Locke
>            Assignee: Jonathan Locke
>            Priority: Minor
>             Fix For: 1.3.0-beta2
>
>
> Currently code does:
> 			calendar.add(Calendar.DATE, 1);
> 			return Time.valueOf(calendar, this);
> Because Time.valueOf(Calendar, TimeOfDay) always returns the time on the same day, the add is ignored.  Instead this code should be the time of day today plus one day like this:
> 			return Time.valueOf(calendar, this).add(Duration.ONE_DAY);

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