public final class RemoteMapView<K,V> extends VanillaMapView<K,V>
asset, context, keyClass, putReturnsNull, removeReturnsNull, valueType
Constructor and Description |
---|
RemoteMapView(@NotNull(exception=java.lang.NullPointerException.class) RequestContext context,
@NotNull(exception=java.lang.NullPointerException.class) Asset asset,
@NotNull(exception=java.lang.NullPointerException.class) KeyValueStore<K,V> kvStore) |
Modifier and Type | Method and Description |
---|---|
<A,R> R |
applyTo(@NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableBiFunction<MapView<K,V>,A,R> function,
A arg)
Apply a function to an Updatable which is assumed to not change the visited in any significant way.
|
<R> R |
applyTo(@NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableFunction<MapView<K,V>,R> function)
Apply a function to an Updatable which is assumed to not change the visited in any significant way.
|
<T,R> R |
applyToKey(K key,
@NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableBiFunction<V,T,R> function,
T argument)
Apply a function which takes an argument.
|
<R> R |
applyToKey(K key,
@NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableFunction<V,R> function)
Apply a function to the visitable and return the result.
|
void |
asyncUpdate(@NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableUpdater<MapView<K,V>> updateFunction)
Update an Updatable potentially asynchronously.
|
<A> void |
asyncUpdate(@NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableUpdaterWithArg<MapView<K,V>,A> updateFunction,
A arg)
Update an Updatable potentially asynchronously.
|
<T> void |
asyncUpdateKey(K key,
@NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableBiFunction<V,T,V> updateFunction,
T argument)
Apply a function to visitable potentially asynchronously.
|
void |
asyncUpdateKey(K key,
@NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableFunction<V,V> updateFunction)
Apply a function to visitable potentially asynchronously.
|
V |
compute(K key,
@NotNull BiFunction<? super K,? super V,? extends V> remappingFunction) |
V |
computeIfAbsent(K key,
@NotNull Function<? super K,? extends V> mappingFunction) |
V |
computeIfPresent(K key,
@NotNull BiFunction<? super K,? super V,? extends V> remappingFunction) |
boolean |
containsValue(Object value) |
boolean |
equals(Object o) |
int |
hashCode() |
V |
merge(K key,
V value,
BiFunction<? super V,? super V,? extends V> remappingFunction) |
V |
putIfAbsent(K key,
V value) |
@NotNull Reference<V> |
referenceFor(K key)
Obtain a reference the value for a key
|
void |
registerKeySubscriber(@NotNull(exception=java.lang.NullPointerException.class) Subscriber<? super K> subscriber,
@NotNull(exception=java.lang.NullPointerException.class) Filter filter,
@NotNull(exception=java.lang.NullPointerException.class) Set<RequestContext.Operation> contextOperations)
Add a Subscription for the keys changed on this Map
|
boolean |
remove(@NotNull(exception=java.lang.NullPointerException.class) Object key,
Object value) |
V |
replace(K key,
V value) |
boolean |
replace(K key,
V oldValue,
V newValue) |
void |
replaceAll(BiFunction<? super K,? super V,? extends V> function) |
<R> R |
syncUpdate(@NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableUpdater<MapView<K,V>> updateFunction,
@NotNull net.openhft.chronicle.core.util.SerializableFunction<MapView<K,V>,R> returnFunction)
Apply a function to update an Updatable and apply a second function to derive some information from it.
|
<UA,RA,R> R |
syncUpdate(@NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableUpdaterWithArg<MapView<K,V>,UA> updateFunction,
UA ua,
@NotNull net.openhft.chronicle.core.util.SerializableBiFunction<MapView<K,V>,RA,R> returnFunction,
RA returnArgument)
Apply a function to update an Updatable and apply a second function to derive some information from it.
|
<T,RT,R> R |
syncUpdateKey(K key,
@NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableBiFunction<V,T,V> updateFunction,
T updateArgument,
@NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableBiFunction<V,RT,R> returnFunction,
RT returnArgument)
Apply a function to update the state of a visible, and apply a function to return a result object synchronously.
|
<R> R |
syncUpdateKey(K key,
@NotNull net.openhft.chronicle.core.util.SerializableFunction<V,V> updateFunction,
@NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableFunction<V,R> returnFunction)
Apply a function to update the state of a visible, and apply a function to return a result object synchronously.
|
asset, checkKey, checkValue, clear, containsKey, entrySet, get, getAndPut, getAndRemove, getUsing, isEmpty, keySet, keyType, longSize, put, putAll, registerKeySubscriber, registerSubscriber, registerSubscriber, registerTopicSubscriber, remove, set, toString, underlying, values, valueType
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
forEach, getOrDefault
public RemoteMapView(@NotNull(exception=java.lang.NullPointerException.class) @NotNull(exception=java.lang.NullPointerException.class) RequestContext context, @NotNull(exception=java.lang.NullPointerException.class) @NotNull(exception=java.lang.NullPointerException.class) Asset asset, @NotNull(exception=java.lang.NullPointerException.class) @NotNull(exception=java.lang.NullPointerException.class) KeyValueStore<K,V> kvStore)
public boolean containsValue(Object value)
containsValue
in interface Map<K,V>
containsValue
in class VanillaMapView<K,V>
public void registerKeySubscriber(@NotNull(exception=java.lang.NullPointerException.class) @NotNull(exception=java.lang.NullPointerException.class) Subscriber<? super K> subscriber, @NotNull(exception=java.lang.NullPointerException.class) @NotNull(exception=java.lang.NullPointerException.class) Filter filter, @NotNull(exception=java.lang.NullPointerException.class) @NotNull(exception=java.lang.NullPointerException.class) Set<RequestContext.Operation> contextOperations)
MapView
Any given instance of a subscriber must at most be registered once with a DataGrid instance at any given time.
This method is asynchronous and the provided subscriber will be eligible for receiving events as some later unspecified time.
registerKeySubscriber
in interface MapView<K,V>
registerKeySubscriber
in class VanillaMapView<K,V>
subscriber
- to addfilter
- a list of filter operationscontextOperations
- which optional operations to consider (e.g. bootstrap and ending after bootstrap)public void replaceAll(BiFunction<? super K,? super V,? extends V> function)
public boolean equals(Object o)
@NotNull public @NotNull Reference<V> referenceFor(K key)
MapView
referenceFor
in interface MapView<K,V>
referenceFor
in class VanillaMapView<K,V>
key
- to bind the reference topublic int hashCode()
@Nullable public V putIfAbsent(@NotNull(exception=java.lang.NullPointerException.class) K key, V value)
putIfAbsent
in interface ConcurrentMap<K,V>
putIfAbsent
in interface Map<K,V>
putIfAbsent
in class VanillaMapView<K,V>
public boolean remove(@NotNull(exception=java.lang.NullPointerException.class) @NotNull(exception=java.lang.NullPointerException.class) Object key, Object value)
public boolean replace(@NotNull(exception=java.lang.NullPointerException.class) K key, @NotNull(exception=java.lang.NullPointerException.class) V oldValue, @NotNull(exception=java.lang.NullPointerException.class) V newValue)
@Nullable public V replace(@NotNull(exception=java.lang.NullPointerException.class) K key, @NotNull(exception=java.lang.NullPointerException.class) V value)
@NotNull public V computeIfAbsent(K key, @NotNull @NotNull Function<? super K,? extends V> mappingFunction)
@NotNull public V computeIfPresent(K key, @NotNull @NotNull BiFunction<? super K,? super V,? extends V> remappingFunction)
@NotNull public V compute(K key, @NotNull @NotNull BiFunction<? super K,? super V,? extends V> remappingFunction)
@NotNull public V merge(K key, V value, BiFunction<? super V,? super V,? extends V> remappingFunction)
@Nullable public <A,R> R applyTo(@NotNull(exception=java.lang.NullPointerException.class) @NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableBiFunction<MapView<K,V>,A,R> function, A arg)
Updatable
A
- argument type.R
- return type.function
- to apply to derive data from this Updatable.arg
- argument to applypublic <A> void asyncUpdate(@NotNull(exception=java.lang.NullPointerException.class) @NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableUpdaterWithArg<MapView<K,V>,A> updateFunction, A arg)
Updatable
A
- argument type.updateFunction
- to apply.arg
- argument to apply@Nullable public <UA,RA,R> R syncUpdate(@NotNull(exception=java.lang.NullPointerException.class) @NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableUpdaterWithArg<MapView<K,V>,UA> updateFunction, UA ua, @NotNull @NotNull net.openhft.chronicle.core.util.SerializableBiFunction<MapView<K,V>,RA,R> returnFunction, RA returnArgument)
Updatable
UA
- update argument typeRA
- return argument typeR
- return typeupdateFunction
- to apply the update.ua
- update argumentreturnFunction
- to derive some datareturnArgument
- return argument@Nullable public <R> R applyTo(@NotNull(exception=java.lang.NullPointerException.class) @NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableFunction<MapView<K,V>,R> function)
Updatable
R
- return type.function
- to apply to derive data from this Updatable.public void asyncUpdate(@NotNull(exception=java.lang.NullPointerException.class) @NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableUpdater<MapView<K,V>> updateFunction)
Updatable
updateFunction
- to apply.@Nullable public <R> R syncUpdate(@NotNull(exception=java.lang.NullPointerException.class) @NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableUpdater<MapView<K,V>> updateFunction, @NotNull @NotNull net.openhft.chronicle.core.util.SerializableFunction<MapView<K,V>,R> returnFunction)
Updatable
R
- data type to return.updateFunction
- to apply the update.returnFunction
- to derive some data@Nullable public <R> R applyToKey(K key, @NotNull(exception=java.lang.NullPointerException.class) @NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableFunction<V,R> function)
KeyedVisitable
R
- data type to return.key
- to visit within this collection.function
- to apply e.g. call a getter@Nullable public <T,R> R applyToKey(K key, @NotNull(exception=java.lang.NullPointerException.class) @NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableBiFunction<V,T,R> function, T argument)
KeyedVisitable
T
- type of the argumentR
- type of the return value.key
- to visit within this collection.function
- to applyargument
- for the functions use.public void asyncUpdateKey(K key, @NotNull(exception=java.lang.NullPointerException.class) @NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableFunction<V,V> updateFunction)
KeyedVisitable
key
- to visit within this collection.updateFunction
- to update the state of the visibility.public <T> void asyncUpdateKey(K key, @NotNull(exception=java.lang.NullPointerException.class) @NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableBiFunction<V,T,V> updateFunction, T argument)
KeyedVisitable
T
- type of the argumentkey
- to update within this collectionupdateFunction
- to update the state of the visitable.argument
- for the functions use.@Nullable public <R> R syncUpdateKey(K key, @NotNull @NotNull net.openhft.chronicle.core.util.SerializableFunction<V,V> updateFunction, @NotNull(exception=java.lang.NullPointerException.class) @NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableFunction<V,R> returnFunction)
KeyedVisitable
R
- data type to return.key
- to update within this collection.updateFunction
- update to apply to the value.returnFunction
- derive an object to return@Nullable public <T,RT,R> R syncUpdateKey(K key, @NotNull(exception=java.lang.NullPointerException.class) @NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableBiFunction<V,T,V> updateFunction, @Nullable T updateArgument, @NotNull(exception=java.lang.NullPointerException.class) @NotNull(exception=java.lang.NullPointerException.class) net.openhft.chronicle.core.util.SerializableBiFunction<V,RT,R> returnFunction, @Nullable RT returnArgument)
KeyedVisitable
T
- update argument type.RT
- return argument type.R
- data type to return.key
- to update within this collectionupdateFunction
- update to apply to the value.updateArgument
- for the update function to use.returnFunction
- derive an object to returnreturnArgument
- for the return value function to useCopyright © 2021. All rights reserved.