Package io.sf.carte.doc
Class WrapperStringList
java.lang.Object
io.sf.carte.doc.WrapperStringList
- All Implemented Interfaces:
StringList,Serializable,Iterable<String>,Collection<String>,List<String>,DOMStringList
An unmodifiable
StringList that wraps a Collection.- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionConstructs a list containing the elements of the specified collection, in the order they are returned by the collection's iterator. -
Method Summary
Modifier and TypeMethodDescriptionvoidbooleanbooleanaddAll(int index, Collection<? extends String> c) booleanaddAll(Collection<? extends String> c) voidclear()booleanbooleanbooleancontainsAll(Collection<?> c) get(int index) intintbooleanisEmpty()item(int index) iterator()intlistIterator(int index) remove(int index) booleanbooleanremoveAll(Collection<?> c) voidreplaceAll(UnaryOperator<String> operator) booleanretainAll(Collection<?> c) intsize()voidsort(Comparator<? super String> c) subList(int fromIndex, int toIndex) Object[]toArray()<T> T[]toArray(T[] 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, toArray
-
Constructor Details
-
WrapperStringList
Constructs a list containing the elements of the specified collection, in the order they are returned by the collection's iterator.- Parameters:
c- the collection whose elements are to be wrapped by this list.- Throws:
NullPointerException- if the specified collection isnull.
-
-
Method Details
-
item
- Specified by:
itemin interfaceDOMStringList
-
getLength
public int getLength()- Specified by:
getLengthin interfaceDOMStringList
-
contains
- Specified by:
containsin interfaceDOMStringList
-
size
public int size() -
isEmpty
public boolean isEmpty() -
contains
-
iterator
-
toArray
-
toArray
public <T> T[] toArray(T[] a) -
add
-
remove
-
containsAll
- Specified by:
containsAllin interfaceCollection<String>- Specified by:
containsAllin interfaceList<String>
-
addAll
-
addAll
-
removeAll
-
retainAll
-
replaceAll
- Specified by:
replaceAllin interfaceList<String>
-
sort
-
clear
public void clear() -
get
-
set
-
add
-
remove
-
indexOf
-
lastIndexOf
- Specified by:
lastIndexOfin interfaceList<String>
-
listIterator
- Specified by:
listIteratorin interfaceList<String>
-
listIterator
- Specified by:
listIteratorin interfaceList<String>
-
subList
-
spliterator
- Specified by:
spliteratorin interfaceCollection<String>- Specified by:
spliteratorin interfaceIterable<String>- Specified by:
spliteratorin interfaceList<String>
-