You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@struts.apache.org by "Niall Pemberton (JIRA)" <ji...@apache.org> on 2007/12/06 11:29:34 UTC
[jira] Commented: (STR-3119) Standardize exceptions rethrows to
contain root cause (JDK 5)
[ https://issues.apache.org/struts/browse/STR-3119?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_42785 ]
Niall Pemberton commented on STR-3119:
--------------------------------------
Although some exceptions lack constructors which take a throwable the initCause(Throwable) method was added in JDK 1.4 - its slightly more verbose, but this can be done using JDK 1.4:
IllegalStateException ex = new IllegalStateException("..");
ex.initCause(cause);
throw ex;
> Standardize exceptions rethrows to contain root cause (JDK 5)
> -------------------------------------------------------------
>
> Key: STR-3119
> URL: https://issues.apache.org/struts/browse/STR-3119
> Project: Struts 1
> Issue Type: Improvement
> Components: Core, Extras, Scripting, Taglibs, Tiles 1 Plugin
> Affects Versions: 1.4.0
> Environment: Operating System: All
> Platform: All
> Reporter: Paul Benedict
> Assignee: Paul Benedict
> Priority: Minor
> Fix For: Future
>
>
> STR-2437 added the root cause to exceptions as much as possible in JDK 1.4, but IllegalStateException and IllegalArgumentException do not participate in this practice until JDK 5.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.