Package com.oracle.coherence.client
Class RemoteKeySet<K,V>
- java.lang.Object
-
- com.oracle.coherence.client.RemoteCollection<K,V,K>
-
- com.oracle.coherence.client.RemoteKeySet<K,V>
-
- Type Parameters:
K- the type of the underlying cache's keysV- the type of the underlying cache's values
- All Implemented Interfaces:
Iterable<K>,Collection<K>,Set<K>
public class RemoteKeySet<K,V> extends RemoteCollection<K,V,K> implements Set<K>
A base class forNamedCachekey set implementations.This
Setimplementation allows removal but does not allow additions to the collection. MethodsRemoteCollection.add(Object)RemoteCollection.addAll(Collection)will throw anUnsupportedOperationException.Some methods in this class are intentionally inefficient partly due to their being a more efficient means to perform the same task using the underlying
NamedCacheand partly to ensure that using this class on a client will not cause all of the data from the underlyingNamedCacheto be pulled back to the caller in one result.- Since:
- 20.06
- Author:
- Jonathan Knight 2019.11.12
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected static classRemoteKeySet.KeysAdvancerAnPagedIterator.Advancerto support aPagedIteratorover this key set.-
Nested classes/interfaces inherited from class com.oracle.coherence.client.RemoteCollection
RemoteCollection.EntryAdvancer<K,V>, RemoteCollection.EntryResultMapEntry
-
-
Field Summary
-
Fields inherited from class com.oracle.coherence.client.RemoteCollection
f_client
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedRemoteKeySet(AsyncNamedCacheClient<K,V> client)Create aRemoteKeySet.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleancontains(Object key)Iterator<K>iterator()booleanremove(Object key)Object[]toArray()<T1> T1[]toArray(T1[] array)-
Methods inherited from class com.oracle.coherence.client.RemoteCollection
add, addAll, clear, containsAll, createEntryAdvancer, equals, getCache, hashCode, isEmpty, removeAll, retainAll, size, toString
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArray
-
-
-
-
Constructor Detail
-
RemoteKeySet
protected RemoteKeySet(AsyncNamedCacheClient<K,V> client)
Create aRemoteKeySet.- Parameters:
client- theNamedCacheClientthat this key set is linked to
-
-