Interface CacheEntryLocator<I,V>

Type Parameters:
I - the identifier type of the located value
V - the located value type
All Known Subinterfaces:
BiCacheEntryLocator<I,K,V>, ImmutableSessionAttributesFactory<V>, ImmutableSessionFactory<MV,AV>, ImmutableSessionMetaDataFactory<V>, SessionAttributesFactory<C,V>, SessionFactory<C,MV,AV,SC>, SessionMetaDataFactory<V>, UserContextFactory<V,PC,TC>, UserFactory<CV,C,T,SV,D,S>, UserSessionsFactory<V,D,S>
All Known Implementing Classes:
CoarseSessionAttributesFactory, CoarseSessionAttributesFactory, CompositeImmutableSessionFactory, CompositeSessionFactory, CompositeUserFactory, FineSessionAttributesFactory, FineSessionAttributesFactory, HotRodSessionFactory, HotRodSessionMetaDataFactory, HotRodUserContextFactory, HotRodUserSessionsFactory, InfinispanSessionMetaDataFactory, InfinispanUserContextFactory, InfinispanUserSessionsFactory

public interface CacheEntryLocator<I,V>
Locates a value from a cache.
Author:
Paul Ferraro
  • Method Summary

    Modifier and Type
    Method
    Description
    default V
    Locates the value in the cache with the specified identifier.
    Locates the value in the cache with the specified identifier.
    default V
    tryValue(I id)
    Returns the value for the specified key, if possible without contention.
    Returns the value for the specified key, if possible without contention.
  • Method Details

    • findValue

      default V findValue(I id)
      Locates the value in the cache with the specified identifier.
      Parameters:
      id - the cache entry identifier
      Returns:
      the value of the cache entry, or null if not found.
    • findValueAsync

      CompletionStage<V> findValueAsync(I id)
      Locates the value in the cache with the specified identifier.
      Parameters:
      id - the cache entry identifier
      Returns:
      the value of the cache entry, or null if not found.
    • tryValue

      default V tryValue(I id)
      Returns the value for the specified key, if possible without contention.
      Parameters:
      id - a logical key
      Returns:
      the value of the cache entry, or null if not found or unavailable.
    • tryValueAsync

      default CompletionStage<V> tryValueAsync(I id)
      Returns the value for the specified key, if possible without contention.
      Parameters:
      id - a logical key
      Returns:
      the value of the cache entry, or null if not found or unavailable.