Retour impossible de l'objet du Bean vers le client standalone
Bonjour,
Depuis une application cliente, j'appelle la méthode suivante d'un Session Bean :
Code:
1 2 3 4 5 6 7 8 9
|
@SuppressWarnings("unchecked")
@Override
public List<Utilisateur> getAllClients() {
List<Utilisateur> listeClients = (List<Utilisateur>)em.createQuery("SELECT utilisateur FROM Utilisateur AS utilisateur").getResultList();
return listeClients;
} |
Je récupère bien la listeClients rempli dans cette méthode.
Mais après le return, dans l'application je me retourve avec l'exception suivante :
Code:
1 2 3 4 5
|
java.lang.reflect.UndeclaredThrowableException
at $Proxy2.getAllClients(Unknown Source)
at Main.main(Main.java:38)
Caused by: java.lang.ClassNotFoundException: org.hibernate.collection.PersistentBag |
Pourquoi, l'objet ne passe pas au client ? :?
PS : L'Entity Bean Utilisateur implémente Serializable.
A+ ;)