@ParametersAreNonnullByDefault public class MockExternalCache<T> extends Object implements com.atlassian.vcache.DirectExternalCache<T>, com.atlassian.vcache.StableReadExternalCache<T>
Constructor and Description |
---|
MockExternalCache(String name,
com.atlassian.vcache.Marshaller<T> marshaller,
com.atlassian.vcache.ExternalCacheSettings settings) |
@Nonnull public CompletionStage<Optional<com.atlassian.vcache.IdentifiedValue<T>>> getIdentified(String s)
getIdentified
in interface com.atlassian.vcache.DirectExternalCache<T>
public CompletionStage<com.atlassian.vcache.IdentifiedValue<T>> getIdentified(String s, java.util.function.Supplier<T> supplier)
getIdentified
in interface com.atlassian.vcache.DirectExternalCache<T>
public CompletionStage<Map<String,Optional<com.atlassian.vcache.IdentifiedValue<T>>>> getBulkIdentified(String... keys)
getBulkIdentified
in interface com.atlassian.vcache.DirectExternalCache<T>
@Nonnull public CompletionStage<Map<String,Optional<com.atlassian.vcache.IdentifiedValue<T>>>> getBulkIdentified(Iterable<String> iterable)
getBulkIdentified
in interface com.atlassian.vcache.DirectExternalCache<T>
@Nonnull public CompletionStage<Boolean> removeIf(String s, com.atlassian.vcache.CasIdentifier casIdentifier)
removeIf
in interface com.atlassian.vcache.DirectExternalCache<T>
@Nonnull public CompletionStage<Boolean> replaceIf(String s, com.atlassian.vcache.CasIdentifier casIdentifier, T t)
replaceIf
in interface com.atlassian.vcache.DirectExternalCache<T>
@Nonnull public CompletionStage<Optional<T>> get(String key)
get
in interface com.atlassian.vcache.ExternalCache<T>
@Nonnull public CompletionStage<T> get(String key, java.util.function.Supplier<T> supplier)
get
in interface com.atlassian.vcache.ExternalCache<T>
public CompletionStage<Map<String,Optional<T>>> getBulk(String... keys)
getBulk
in interface com.atlassian.vcache.ExternalCache<T>
@Nonnull public CompletionStage<Map<String,Optional<T>>> getBulk(Iterable<String> iterable)
getBulk
in interface com.atlassian.vcache.ExternalCache<T>
public CompletionStage<Map<String,T>> getBulk(java.util.function.Function<Set<String>,Map<String,T>> factory, String... keys)
getBulk
in interface com.atlassian.vcache.ExternalCache<T>
@Nonnull public CompletionStage<Map<String,T>> getBulk(java.util.function.Function<Set<String>,Map<String,T>> function, Iterable<String> iterable)
getBulk
in interface com.atlassian.vcache.ExternalCache<T>
@Nonnull public CompletionStage<Boolean> put(String key, T value, com.atlassian.vcache.PutPolicy putPolicy)
put
in interface com.atlassian.vcache.ExternalWriteOperationsUnbuffered<T>
public CompletionStage<Void> remove(String... keys)
remove
in interface com.atlassian.vcache.ExternalWriteOperationsUnbuffered<T>
@Nonnull public CompletionStage<Void> remove(Iterable<String> iterable)
remove
in interface com.atlassian.vcache.ExternalWriteOperationsUnbuffered<T>
@Nonnull public CompletionStage<Void> removeAll()
removeAll
in interface com.atlassian.vcache.ExternalWriteOperationsUnbuffered<T>
Copyright © 2002-2021 Atlassian. All Rights Reserved.