Dear All
I have a findAll method for a CMP enitity bean. I have previously had to
cast to and ArrayList when calling this method. But now because I need to
use a Vector instead (for backward compatability reasons), I have done:
AddressHome adrHome = (AddressHome)initialContext.lookup("Address");
Vector v = (Vector)adrHome.findAll();
I get the following exception thrown: java.lang.ClassCastException:
java.util.ArrayList.
The method declaration in the home interface of the bean is:
public Collection findAll() throws RemoteException, FinderException
which suggests I can cast to a Vector (correct me of I'm wrong).
The only solution is to go back to casting to an ArrayList and then iterate
through it passing each element to a Vector, which works but isn't ideal.
Any suggestions?
Regards,
Robert Hargreaves
----
To unsubscribe, send email to [EMAIL PROTECTED] and
include in the body of the message "unsubscribe jonas-users".
For general help, send email to [EMAIL PROTECTED] and
include in the body of the message "help".