You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Paulex Yang (JIRA)" <ji...@apache.org> on 2006/08/30 09:10:24 UTC

[jira] Resolved: (HARMONY-1305) [classlib][sql] java.sql.Date.valueOf(String str) method should throw IllegalArgumentException when the string is "1991-01-01-01"

     [ http://issues.apache.org/jira/browse/HARMONY-1305?page=all ]

Paulex Yang resolved HARMONY-1305.
----------------------------------

    Resolution: Fixed

Richard, patch applied at revision r438404 together with patch for HARMONY-1307, because they are same issue for two similar classes, so I extract the common validation codes of them, thanks a lot for this enhancement, please verify that the problem is fully fixed as you expected.

Further, I saw possibilities to improve the performance of original Date and Time implementation, say, the SimpleDateFormat don't need to be instantiated every times, further the SimpleDateFormat is even not necessary to be used here, because in the validation part, the hour/minute/second(year/month/day for Date) value has been parsed. Please correct me if I'm wrong.

> [classlib][sql] java.sql.Date.valueOf(String str) method should throw IllegalArgumentException when the string is "1991-01-01-01"
> ---------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: HARMONY-1305
>                 URL: http://issues.apache.org/jira/browse/HARMONY-1305
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Richard Liang
>         Assigned To: Paulex Yang
>         Attachments: Harmony-1305.diff
>
>
> Hello,
> java.sql.Date.valueOf(String str) method should throw IllegalArgumentException when the string is "1991-01-01-01". I will attach a patch to fix this issue.
> Best regards,
> Richard

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira