Class DirtyCollection<E>
java.lang.Object
org.forgerock.openig.session.jwt.dirty.DirtyCollection<E>
- Type Parameters:
E
- type of the collection
- All Implemented Interfaces:
Iterable<E>
,Collection<E>
A
Collection
decorator that notifies the provided DirtyListener
when one ore more elements are
removed.-
Constructor Summary
ConstructorDescriptionDirtyCollection
(Collection<E> delegate, DirtyListener listener) Builds a new DirtyCollection delegating to the given Collection and notifying the provided observer. -
Method Summary
Modifier and TypeMethodDescriptionboolean
boolean
addAll
(Collection<? extends E> c) void
clear()
boolean
boolean
containsAll
(Collection<?> c) boolean
int
hashCode()
boolean
isEmpty()
iterator()
boolean
boolean
removeAll
(Collection<?> c) boolean
retainAll
(Collection<?> c) int
size()
Object[]
toArray()
<T> T[]
toArray
(T[] a) Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.util.Collection
parallelStream, removeIf, spliterator, stream, toArray
-
Constructor Details
-
DirtyCollection
Builds a new DirtyCollection delegating to the given Collection and notifying the provided observer.- Parameters:
delegate
- Collection delegatelistener
- change observer
-
-
Method Details
-
size
public int size()- Specified by:
size
in interfaceCollection<E>
-
isEmpty
public boolean isEmpty()- Specified by:
isEmpty
in interfaceCollection<E>
-
contains
- Specified by:
contains
in interfaceCollection<E>
-
iterator
-
toArray
- Specified by:
toArray
in interfaceCollection<E>
-
toArray
public <T> T[] toArray(T[] a) - Specified by:
toArray
in interfaceCollection<E>
-
add
- Specified by:
add
in interfaceCollection<E>
-
remove
- Specified by:
remove
in interfaceCollection<E>
-
containsAll
- Specified by:
containsAll
in interfaceCollection<E>
-
addAll
- Specified by:
addAll
in interfaceCollection<E>
-
removeAll
- Specified by:
removeAll
in interfaceCollection<E>
-
retainAll
- Specified by:
retainAll
in interfaceCollection<E>
-
clear
public void clear()- Specified by:
clear
in interfaceCollection<E>
-
equals
- Specified by:
equals
in interfaceCollection<E>
- Overrides:
equals
in classObject
-
hashCode
public int hashCode()- Specified by:
hashCode
in interfaceCollection<E>
- Overrides:
hashCode
in classObject
-