Class RegionalCache<K extends Locatable, V>
java.lang.Object
com.github.darksoulq.abyssallib.server.util.regional.RegionalCache<K,V>
- All Implemented Interfaces:
Map<K,V>
-
Nested Class Summary
-
Constructor Summary
ConstructorsConstructorDescriptionRegionalCache(long defaultDuration, @NotNull TimeUnit unit) RegionalCache(long defaultDuration, @NotNull TimeUnit unit, boolean forceConcurrent) -
Method Summary
Modifier and TypeMethodDescriptionvoidclear()computeIfAbsent(K key, @NotNull Function<? super K, ? extends V> mappingFunction) booleancontainsKey(@Nullable Object key) booleancontainsValue(@Nullable Object value) entrySet()voidforEach(@NotNull BiConsumer<? super K, ? super V> action) getOrDefault(@Nullable Object key, V defaultValue) booleanisEmpty()keySet()voidputIfAbsent(K key, V value) booleanbooleanvoidreplaceAll(@NotNull BiFunction<? super K, ? super V, ? extends V> function) intsize()@NotNull Collection<V> values()
-
Constructor Details
-
RegionalCache
-
RegionalCache
public RegionalCache(long defaultDuration, @NotNull @NotNull TimeUnit unit, boolean forceConcurrent)
-
-
Method Details
-
size
-
isEmpty
-
containsKey
-
containsValue
-
get
-
put
-
put
-
remove
-
putAll
-
clear
-
keySet
-
values
-
entrySet
-
getOrDefault
-
forEach
-
replaceAll
- Specified by:
replaceAllin interfaceMap<K extends Locatable, V>
-
putIfAbsent
-
remove
-
replace
-
replace
-
computeIfAbsent
-
getRegion
-