IS 460 java.lang.reflect.UndeclaredThrowableException

0 views
Skip to first unread message

William Dalton

unread,
Mar 23, 2006, 7:21:03 PM3/23/06
to BYU-Idaho Information Systems Majors
Has anyone seen this error? If so I am wondering why it is being
thrown. It says the root cause is:

Caused by: java.io.NotSerializableException:
home.direct.bank.javabeans.Person

So I went and made my bean class to implement serializable and I still
get the error.

Here is what the API says, first paragraph:

Thrown by a method invocation on a proxy instance if its invocation
handler's invoke method throws a checked exception (a Throwable that is
not assignable to RuntimeException or Error) that is not assignable to
any of the exception types declared in the throws clause of the method
that was invoked on the proxy instance and dispatched to the invocation
handler.

I feel that I have all exceptions types included in my try catches. I
don't understand how this is happening. Can anyone help me on this one?

-Chuck

John Martinson

unread,
Mar 23, 2006, 11:45:38 PM3/23/06
to BYU-Idaho-Informat...@googlegroups.com
I had the same problem.  What I ended up doing is making PersonDAO serialiable by mistake, but once I made Person serializable I didn't have a problem.  I there is a problem with Person throwing an enexception, I would just take all of that out.  A bean shouldn't have any exceptions other than the normal run time null pointers and such. 

I don't know if that helped, but there you have it.

--John
Reply all
Reply to author
Forward
0 new messages