public class LinkedSet<E> extends AbstractSet<E> implements Set<E>, Cloneable, Serializable
Set
interface,
with predictable iteration order.
Resembles LinkedHashSet
from JDK 1.4+, but is backed by a generic
LinkedMap
, rather than implementing a particular algoritm.
LinkedMap
,
Serialized FormConstructor and Description |
---|
LinkedSet() |
LinkedSet(Collection<E> pCollection) |
Modifier and Type | Method and Description |
---|---|
boolean |
add(E pValue) |
boolean |
addAll(Collection<? extends E> pCollection) |
Iterator<E> |
iterator() |
int |
size() |
equals, hashCode, removeAll
clear, contains, containsAll, isEmpty, remove, retainAll, toArray, toArray, toString
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
clear, contains, containsAll, equals, hashCode, isEmpty, remove, removeAll, retainAll, spliterator, toArray, toArray
parallelStream, removeIf, stream
public LinkedSet()
public LinkedSet(Collection<E> pCollection)
public boolean addAll(Collection<? extends E> pCollection)
addAll
in interface Collection<E>
addAll
in interface Set<E>
addAll
in class AbstractCollection<E>
public boolean add(E pValue)
add
in interface Collection<E>
add
in interface Set<E>
add
in class AbstractCollection<E>
public int size()
size
in interface Collection<E>
size
in interface Set<E>
size
in class AbstractCollection<E>
Copyright © 2017. All rights reserved.