In my code I have the following situation:
List cedolini = (List) Bean_Dati.getListaRisultati("ListaCertificazioni");
for (Iterator iterator = cedolini.iterator(); iterator.hasNext(); ) {
System.out.println("TEST");
}
At this time the List named cedolini contains only an element that is an instance of a class named Certificazioni, I see it using the debugger.
The problem is that when the previous code is performed it enter in an infinite loop and I don't obtain a single TEST printed in the stacktrace but something like it:
TEST
TEST
TEST
TEST
TEST
TEST
....
....
....
and it still continue entering into an infinite loop.
Why? What am I missing? How can I solve this issue?