Probleme de parcours d'une hashtable
Bonjour,
Voila j'ai un probleme :
je dois parcourir une Hashtable et passer en parametre son contenu à une fonction. Mais le souci est que j'obtiens un classCastException.
Voici le code :
Code:
1 2 3 4 5 6 7 8 9 10 11
| animauxSelection = accesDonnees
.chercherEtrangerParIdentifiant(critere);
animauxSelection = accesDonnees
.chercherEtrangerDomaineGenetiqueParIdentifiant(critere);
Iterator it = animauxSelection.keySet().iterator();
while (it.hasNext()) {
AnimalSelection animalsel = (AnimalSelection) animauxSelection.get(it.next());
Animal animal = accesDonnees
.completerEtrangerDomaineGenetique(animalsel);
collectionanimauxSelection.add(animal);
} |
Est ce que quelqu'un peut m'aider ?
Merci