Module org.apache.wicket.extensions
Class ProviderSubset<T>
java.lang.Object
org.apache.wicket.extensions.markup.html.repeater.util.ProviderSubset<T>
- Type Parameters:
T- type of data
- All Implemented Interfaces:
Serializable,Iterable<T>,Collection<T>,Set<T>,IDetachable,org.apache.wicket.util.io.IClusterable
A
Set implementation utilizing a ITreeProvider's models to keep containing
elements.- Author:
- svenmeier
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionProviderSubset(ITreeProvider<T> provider) Create an empty subset.ProviderSubset(ITreeProvider<T> provider, boolean addRoots) Create a subset optionally containing all roots of the provider. -
Method Summary
Modifier and TypeMethodDescriptionbooleanbooleanaddAll(Collection<? extends T> ts) voidclear()booleanbooleancontainsAll(Collection<?> cs) Create a model holding this set.voiddetach()booleanisEmpty()iterator()booleanbooleanremoveAll(Collection<?> cs) booleanretainAll(Collection<?> c) intsize()Object[]toArray()<S> S[]toArray(S[] a) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArrayMethods inherited from interface java.util.Set
equals, hashCode, spliterator
-
Constructor Details
-
ProviderSubset
Create an empty subset.- Parameters:
provider- the provider of the complete set
-
ProviderSubset
Create a subset optionally containing all roots of the provider.- Parameters:
provider- the provider of the complete setaddRoots- should all roots be added to this subset
-
-
Method Details
-
detach
- Specified by:
detachin interfaceIDetachable
-
size
-
isEmpty
-
clear
-
contains
-
add
-
remove
-
iterator
-
addAll
-
containsAll
- Specified by:
containsAllin interfaceCollection<T>- Specified by:
containsAllin interfaceSet<T>
-
removeAll
-
retainAll
-
toArray
-
toArray
-
createModel
Create a model holding this set.- Returns:
- model
-