Package com.evolveum.midpoint.prism
Class FreezableList<T>
- java.lang.Object
-
- com.evolveum.midpoint.prism.AbstractFreezable
-
- com.evolveum.midpoint.prism.FreezableList<T>
-
- Type Parameters:
T- type of list items
- All Implemented Interfaces:
Freezable,Serializable,Iterable<T>,Collection<T>,List<T>
- Direct Known Subclasses:
DeeplyFreezableList
@Experimental public class FreezableList<T> extends AbstractFreezable implements Serializable, List<T>
A list that can be made immutable. The expected use of this class is to be a `final` field in a class.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description FreezableList()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidadd(int index, T element)booleanadd(T t)booleanaddAll(int index, @NotNull Collection<? extends T> c)booleanaddAll(@NotNull Collection<? extends T> c)voidclear()booleancontains(Object o)booleancontainsAll(@NotNull Collection<?> c)Tget(int index)intindexOf(Object o)booleanisEmpty()@NotNull Iterator<T>iterator()intlastIndexOf(Object o)@NotNull ListIterator<T>listIterator()@NotNull ListIterator<T>listIterator(int index)protected voidperformFreeze()Tremove(int index)booleanremove(Object o)booleanremoveAll(@NotNull Collection<?> c)booleanretainAll(@NotNull Collection<?> c)Tset(int index, T element)intsize()@NotNull List<T>subList(int fromIndex, int toIndex)@NotNull Object @NotNull []toArray()<T1> @NotNull T1 @NotNull []toArray(@NotNull T1 @NotNull [] a)-
Methods inherited from class com.evolveum.midpoint.prism.AbstractFreezable
freeze, freeze, freezeAll, freezeNullableList, isImmutable, isMutable
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArray
-
Methods inherited from interface com.evolveum.midpoint.prism.Freezable
checkImmutable, checkMutable
-
Methods inherited from interface java.util.List
equals, hashCode, replaceAll, sort, spliterator
-
-
-
-
Method Detail
-
performFreeze
protected void performFreeze()
- Overrides:
performFreezein classAbstractFreezable
-
size
public int size()
-
isEmpty
public boolean isEmpty()
-
contains
public boolean contains(Object o)
-
toArray
@NotNull public @NotNull Object @NotNull [] toArray()
-
toArray
@NotNull public <T1> @NotNull T1 @NotNull [] toArray(@NotNull @NotNull T1 @NotNull [] a)
-
add
public boolean add(T t)
-
remove
public boolean remove(Object o)
-
containsAll
public boolean containsAll(@NotNull @NotNull Collection<?> c)- Specified by:
containsAllin interfaceCollection<T>- Specified by:
containsAllin interfaceList<T>
-
addAll
public boolean addAll(@NotNull @NotNull Collection<? extends T> c)
-
addAll
public boolean addAll(int index, @NotNull @NotNull Collection<? extends T> c)
-
removeAll
public boolean removeAll(@NotNull @NotNull Collection<?> c)
-
retainAll
public boolean retainAll(@NotNull @NotNull Collection<?> c)
-
clear
public void clear()
-
lastIndexOf
public int lastIndexOf(Object o)
- Specified by:
lastIndexOfin interfaceList<T>
-
listIterator
@NotNull public @NotNull ListIterator<T> listIterator()
- Specified by:
listIteratorin interfaceList<T>
-
listIterator
@NotNull public @NotNull ListIterator<T> listIterator(int index)
- Specified by:
listIteratorin interfaceList<T>
-
-