Re: Post Update to 5.2.3 Exception: java.lang.reflect.InvocationTargetException
Re: Post Update to 5.2.3 Exception: java.lang.reflect.InvocationTargetException
- Subject: Re: Post Update to 5.2.3 Exception: java.lang.reflect.InvocationTargetException
- From: Jonathan Rochkind <email@hidden>
- Date: Wed, 17 Mar 2004 16:45:39 -0600
Standardly, this is caused by using the java Reflection API. Since
you can use the reflection API to call an arbitrary method determined
at runtime, the refelction API to do this can't possibly declare
every time of exception that might be thrown by that arbitrary
method. So it just declares InvocationTargetException, and will wrap
the true exception in one of these InvocationTargetExceptions.
But even if you don't think you are using the reflection API, the
WO/EOF frameworks are using it all the time, notably for key/value
coding stuff, such as in .wod bindings. I've noticed the WO/EOF
frameworks are a bit inconsistent about when they end up throwing an
NSForwardException, when they throw an InvocationTargetException
instead, and when they do something else entirely. In any event, if
you've ever run into NSForwardException, InvocationTargetException is
very similar---it wraps another exception, which is your real
exception, and you've got to look at that wrapped exception to really
figure out what's going on.
[In one case I think I've even run into an NSForwardException
wrapping an InvocationTargetException wrapping the true exception!].
Hope this helps,
--Jonathan
At 5:20 PM -0500 3/17/04, George Domurot wrote:
After upgrading to 5.2.3 I'm seeing the following exception:
Exception: java.lang.reflect.InvocationTargetException
I've never seen this exception before. And, unfortunately, I'm not
sure where in our code this is happening. Is anyone familiar with
this exception and what might cause it?
-George
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.