Javolution 6.0.0 java
|
Public Member Functions | |
MappedSetImpl (SetService< E > target, Function<? super E, ? extends R > function) | |
abstract boolean | add (R r) |
abstract boolean | contains (Object r) |
abstract boolean | remove (Object r) |
SetService< R > | threadSafe () |
abstract boolean | add (E element) |
void | clear () |
Equality<? super R > | comparator () |
boolean | isEmpty () |
Iterator< R > | iterator () |
int | size () |
boolean | addAll (Collection<? extends E > c) |
CollectionView< E > | clone () |
boolean | containsAll (Collection<?> c) |
boolean | equals (Object o) |
int | hashCode () |
void | perform (Consumer< CollectionService< E >> action, CollectionService< E > view) |
boolean | removeAll (Collection<?> c) |
boolean | retainAll (Collection<?> c) |
CollectionService< E >[] | split (int n) |
Object[] | toArray () |
void | update (Consumer< CollectionService< E >> action, CollectionService< E > view) |
CollectionService< E > | clone () throws CloneNotSupportedException |
Equality<? super E > | comparator () |
void | perform (Consumer< T > action, T part) |
T[] | split (int n) |
void | update (Consumer< T > action, T part) |
Protected Member Functions | |
CollectionService< E > | target () |
CollectionService< E > | service () |
Protected Attributes | |
final Function<? super E, ? extends R > | function |
Package Functions | |
public< T > T[] | toArray (T[] a) |
Private Attributes | |
CollectionService< E > | target |
Static Private Attributes | |
static final long | serialVersionUID = 0x600L |
A mapped view over a set.
Definition at line 18 of file MappedSetImpl.java.
javolution.util.internal.set.MappedSetImpl< E, R >.MappedSetImpl | ( | SetService< E > | target, |
Function<? super E, ? extends R > | function | ||
) |
Definition at line 23 of file MappedSetImpl.java.
|
abstractinherited |
Adds the specified element to this collection
|
abstract |
Reimplemented from javolution.util.internal.collection.MappedCollectionImpl< E, R >.
|
inherited |
Adds all the specified elements to this collection.
Definition at line 46 of file CollectionView.java.
|
inherited |
Definition at line 66 of file MappedCollectionImpl.java.
|
inherited |
Returns a copy of this collection; updates of the copy should not impact the original.
Implemented in javolution.util.internal.table.FastTableImpl< E >, javolution.util.internal.collection.SharedCollectionImpl< E >, javolution.util.internal.collection.AtomicCollectionImpl< E >, and javolution.util.internal.collection.CollectionView< E >.
|
inherited |
Returns a copy of this collection; updates of the copy should not impact the original.
Definition at line 66 of file CollectionView.java.
|
inherited |
Returns the comparator used for element equality or order if the collection is sorted.
Implemented in javolution.util.internal.map.MapView< K, V >.KeySet, javolution.util.internal.collection.SharedCollectionImpl< E >, javolution.util.internal.bitset.BitSetServiceImpl, javolution.util.internal.table.FastTableImpl< E >, javolution.util.internal.table.SubTableImpl< E >, javolution.util.internal.collection.AtomicCollectionImpl< E >, javolution.util.internal.collection.SortedCollectionImpl< E >, javolution.util.internal.set.sorted.SubSortedSetImpl< E >, javolution.util.internal.collection.CollectionView< E >, javolution.util.internal.collection.FilteredCollectionImpl< E >, javolution.util.internal.table.UnmodifiableTableImpl< E >, javolution.util.internal.collection.DistinctCollectionImpl< E >, javolution.util.internal.map.MapView< K, V >.EntrySet, javolution.util.internal.table.ReversedTableImpl< E >, javolution.util.internal.collection.ReversedCollectionImpl< E >, javolution.util.internal.collection.UnmodifiableCollectionImpl< E >, javolution.util.internal.collection.ParallelCollectionImpl< E >, and javolution.util.internal.collection.SequentialCollectionImpl< E >.
Referenced by javolution.util.FastTable< javolution.xml.internal.stream.XMLStreamReaderImpl >.sort().
|
inherited |
Reimplemented in javolution.util.internal.map.MapView< K, V >.Values, and javolution.util.internal.map.MapView< K, V >.KeySet.
Definition at line 71 of file MappedCollectionImpl.java.
|
abstract |
Reimplemented in javolution.util.internal.map.MapView< K, V >.KeySet.
|
inherited |
Indicates if this collection contains all the specified elements.
Definition at line 93 of file CollectionView.java.
|
inherited |
Compares the specified object with this collection for equality. This method follows the Collection#equals(Object) specification if this collection comparator is Equalities#STANDARD (default). Otherwise, only collections using the same comparator can be considered equals.
obj | the object to be compared for equality with this collection |
true
if both collections are considered equals; false
otherwise. Definition at line 102 of file CollectionView.java.
|
inherited |
Returns the hash code of this collection. This method follows the Collection#hashCode() specification if this collection comparator is Equalities#STANDARD.
Definition at line 135 of file CollectionView.java.
|
inherited |
Definition at line 76 of file MappedCollectionImpl.java.
|
inherited |
Definition at line 81 of file MappedCollectionImpl.java.
|
inherited |
Definition at line 163 of file CollectionView.java.
|
inherited |
Executes a read-only action on the specified part of this object.
action | the read-only action. |
part | this object or a part of it. |
UnsupportedOperationException | if the action tries to update the specified part. |
|
abstract |
Reimplemented in javolution.util.internal.map.MapView< K, V >.KeySet.
|
inherited |
Removes all the specified element from this collection.
Definition at line 186 of file CollectionView.java.
|
inherited |
Removes all the elements except those in the specified collection.
Definition at line 199 of file CollectionView.java.
|
protectedinherited |
Returns the service implementation of this collection (for sub-classes).
Definition at line 274 of file CollectionView.java.
|
inherited |
Definition at line 86 of file MappedCollectionImpl.java.
|
inherited |
Returns
distinct parts of this object. This method may return an array of size less than
(e.g. an array of size one if this object cannot split).
n | the number of parts. |
IllegalArgumentException | if n <= 1
|
Implemented in javolution.util.internal.map.MapView< K, V >, javolution.util.internal.table.SharedTableImpl< E >, javolution.util.internal.table.TableView< E >, javolution.util.internal.collection.SharedCollectionImpl< E >, javolution.util.internal.collection.CollectionView< E >, javolution.util.internal.table.AtomicTableImpl< E >, javolution.util.internal.map.SharedMapImpl< K, V >, javolution.util.internal.map.FastMapImpl< K, V >, javolution.util.internal.map.AtomicMapImpl< K, V >, javolution.util.internal.collection.AtomicCollectionImpl< E >, and javolution.util.internal.map.MapView< K, V >.EntrySet.
Referenced by javolution.util.internal.map.ParallelMapImpl< K, V >.perform(), and javolution.util.internal.collection.ParallelCollectionImpl< E >.perform().
|
inherited |
Returns
distinct parts of this object. This method may return an array of size less than
(e.g. an array of size one if this object cannot split).
n | the number of parts. |
IllegalArgumentException | if n <= 1
|
Definition at line 224 of file CollectionView.java.
|
protectedinherited |
Returns the actual target
Definition at line 279 of file CollectionView.java.
SetService<R> javolution.util.internal.set.MappedSetImpl< E, R >.threadSafe | ( | ) |
Returns a thread-safe version of this service (used during parallel updates).
Implements javolution.util.service.SetService< E >.
Reimplemented in javolution.util.internal.map.sorted.SortedMapView< K, V >.KeySortedSet.
Definition at line 38 of file MappedSetImpl.java.
|
inherited |
Returns an array holding this collection elements.
Definition at line 243 of file CollectionView.java.
|
packageinherited |
Returns the specified array holding this collection elements if enough capacity.
Definition at line 249 of file CollectionView.java.
|
inherited |
Definition at line 266 of file CollectionView.java.
|
inherited |
Executes an update action on the specified part of this object. Any change to the part is reflected in the whole (this object).
action | the action authorized to update this object part. |
part | this object or a part of it. |
|
protectedinherited |
Definition at line 50 of file MappedCollectionImpl.java.
|
staticprivate |
Definition at line 21 of file MappedSetImpl.java.
|
privateinherited |
Definition at line 33 of file CollectionView.java.