E - the type of content of this Setpublic class ImmutableHashSet<E> extends ImmutableAbstractSet<E>
Copyright (c) 2016-2019 Delft University of Technology, Jaffalaan 5, 2628 BX Delft, the Netherlands. All rights reserved. See for project information https://djutils.org. The DJUTILS project is distributed under a three-clause BSD-style license, which can be found at https://djutils.org/docs/license.html.
copyOrWrap| Constructor and Description |
|---|
ImmutableHashSet(Collection<? extends E> collection) |
ImmutableHashSet(ImmutableAbstractCollection<? extends E> collection) |
ImmutableHashSet(ImmutableAbstractSet<E> set,
Immutable copyOrWrap) |
ImmutableHashSet(Set<E> set,
Immutable copyOrWrap) |
| Modifier and Type | Method and Description |
|---|---|
protected Set<E> |
getCollection()
Returns the underlying collection of this immutable collection.
|
Set<E> |
toSet()
Returns a modifiable copy of this immutable set.
|
String |
toString() |
contains, containsAll, containsAll, equals, forEach, hashCode, isEmpty, isWrap, iterator, parallelStream, size, spliterator, stream, toArray, toArray, toCollectionclone, finalize, getClass, notify, notifyAll, wait, wait, waitisCopypublic ImmutableHashSet(Collection<? extends E> collection)
collection - Collection<? extends E>; the collection to use for the immutable set.public ImmutableHashSet(Set<E> set, Immutable copyOrWrap)
set - Set<E>; the set to use for the immutable set.copyOrWrap - COPY stores a safe, internal copy of the collection; WRAP stores a pointer to the original
collectionpublic ImmutableHashSet(ImmutableAbstractCollection<? extends E> collection)
collection - ImmutableAbstractCollection<? extends E>; the collection to use for the immutable set.public ImmutableHashSet(ImmutableAbstractSet<E> set, Immutable copyOrWrap)
set - ImmutableAbstractSet<E>; the set to use for the immutable set.copyOrWrap - COPY stores a safe, internal copy of the collection; WRAP stores a pointer to the original
collectionprotected Set<E> getCollection()
getCollection in class ImmutableAbstractSet<E>public final Set<E> toSet()
public String toString()
toString in class ImmutableAbstractSet<E>Copyright © 2018–2019 Delft University of Technology. All rights reserved.