java.util
Class ConcurrentModificationException
public
class
ConcurrentModificationException
extends RuntimeException
Exception that is thrown by the collections classes when it is detected that
a modification has been made to a data structure when this is not allowed,
such as when a collection is structurally modified while an Iterator is
operating over it. In cases where this can be detected, a
ConcurrentModificationException will be thrown. An Iterator that detects
this condition is referred to as fail-fast. Notice that this can occur
even in single-threaded designs, if you call methods out of order.
Since: 1.2
See Also: Collection Iterator ListIterator Vector LinkedList HashSet Hashtable TreeMap AbstractList
UNKNOWN: updated to 1.4
public ConcurrentModificationException()
Constructs a ConcurrentModificationException with no detail message.
public ConcurrentModificationException(
String detail)
Constructs a ConcurrentModificationException with a detail message.
Parameters: detail the detail message for the exception