You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Benedikt Ritter (JIRA)" <ji...@apache.org> on 2012/06/18 22:37:42 UTC

[jira] [Updated] (SANDBOX-423) [BeanUtils2] Wrap checked exceptions from BeanAccessor.get() into BeanReflectionException

     [ https://issues.apache.org/jira/browse/SANDBOX-423?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Benedikt Ritter updated SANDBOX-423:
------------------------------------

    Attachment: SANDBOX-423.patch

I've attached a patch for this issue. There are a few things to note:

* There is a lot of try-catch-boiler plate code. To reduce that code I see two possibilities:
** Use some kind of template method implementation
** only catch Exception e
* I'm not sure how to make sure that the BeanReflectionException being thrown in GetPropertyTestCase wraps the right exception. Maybe there are matchers for this in hamcrest that I'm currently not aware of. I've marked that as TODOs.

TIA
Benedikt
                
> [BeanUtils2] Wrap checked exceptions from BeanAccessor.get() into BeanReflectionException
> -----------------------------------------------------------------------------------------
>
>                 Key: SANDBOX-423
>                 URL: https://issues.apache.org/jira/browse/SANDBOX-423
>             Project: Commons Sandbox
>          Issue Type: Sub-task
>          Components: BeanUtils2
>    Affects Versions: Nightly Builds
>            Reporter: Benedikt Ritter
>             Fix For: Nightly Builds
>
>         Attachments: SANDBOX-423.patch
>
>
> * Change method signature of BeanAccessor.get()
> * in DefaultBeanAccessor.get() catch all checked exceptions
> * modify GetPropertyTestCase accordingly

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira