Class AbstractCaffeineCache<K,V>

java.lang.Object
ru.tinkoff.kora.cache.caffeine.AbstractCaffeineCache<K,V>
All Implemented Interfaces:
ru.tinkoff.kora.cache.Cache<K,V>, CaffeineCache<K,V>

public abstract class AbstractCaffeineCache<K,V> extends Object implements CaffeineCache<K,V>
  • Constructor Details

  • Method Details

    • get

      public V get(@Nonnull K key)
      Specified by:
      get in interface ru.tinkoff.kora.cache.Cache<K,V>
    • get

      @Nonnull public Map<K,V> get(@Nonnull Collection<K> keys)
      Specified by:
      get in interface ru.tinkoff.kora.cache.Cache<K,V>
    • computeIfAbsent

      public V computeIfAbsent(@Nonnull K key, @Nonnull Function<K,V> mappingFunction)
      Specified by:
      computeIfAbsent in interface ru.tinkoff.kora.cache.Cache<K,V>
    • computeIfAbsent

      @Nonnull public Map<K,V> computeIfAbsent(@Nonnull Collection<K> keys, @Nonnull Function<Set<K>,Map<K,V>> mappingFunction)
      Specified by:
      computeIfAbsent in interface ru.tinkoff.kora.cache.Cache<K,V>
    • put

      @Nonnull public V put(@Nonnull K key, @Nonnull V value)
      Specified by:
      put in interface ru.tinkoff.kora.cache.Cache<K,V>
    • invalidate

      public void invalidate(@Nonnull K key)
      Specified by:
      invalidate in interface ru.tinkoff.kora.cache.Cache<K,V>
    • invalidate

      public void invalidate(@Nonnull Collection<K> keys)
      Specified by:
      invalidate in interface ru.tinkoff.kora.cache.Cache<K,V>
    • invalidateAll

      public void invalidateAll()
      Specified by:
      invalidateAll in interface ru.tinkoff.kora.cache.Cache<K,V>
    • getAsync

      @Nonnull public reactor.core.publisher.Mono<V> getAsync(@Nonnull K key)
      Specified by:
      getAsync in interface ru.tinkoff.kora.cache.Cache<K,V>
    • getAsync

      @Nonnull public reactor.core.publisher.Mono<Map<K,V>> getAsync(@Nonnull Collection<K> keys)
      Specified by:
      getAsync in interface ru.tinkoff.kora.cache.Cache<K,V>
    • putAsync

      @Nonnull public reactor.core.publisher.Mono<V> putAsync(@Nonnull K key, @Nonnull V value)
      Specified by:
      putAsync in interface ru.tinkoff.kora.cache.Cache<K,V>
    • computeIfAbsentAsync

      public reactor.core.publisher.Mono<V> computeIfAbsentAsync(@Nonnull K key, @Nonnull Function<K,reactor.core.publisher.Mono<V>> mappingFunction)
      Specified by:
      computeIfAbsentAsync in interface ru.tinkoff.kora.cache.Cache<K,V>
    • computeIfAbsentAsync

      @Nonnull public reactor.core.publisher.Mono<Map<K,V>> computeIfAbsentAsync(@Nonnull Collection<K> keys, @Nonnull Function<Set<K>,reactor.core.publisher.Mono<Map<K,V>>> mappingFunction)
      Specified by:
      computeIfAbsentAsync in interface ru.tinkoff.kora.cache.Cache<K,V>
    • invalidateAsync

      @Nonnull public reactor.core.publisher.Mono<Boolean> invalidateAsync(@Nonnull K key)
      Specified by:
      invalidateAsync in interface ru.tinkoff.kora.cache.Cache<K,V>
    • invalidateAsync

      public reactor.core.publisher.Mono<Boolean> invalidateAsync(@Nonnull Collection<K> keys)
      Specified by:
      invalidateAsync in interface ru.tinkoff.kora.cache.Cache<K,V>
    • invalidateAllAsync

      @Nonnull public reactor.core.publisher.Mono<Boolean> invalidateAllAsync()
      Specified by:
      invalidateAllAsync in interface ru.tinkoff.kora.cache.Cache<K,V>