Interface CacheService

    • Method Detail

      • put

        void put​(Object key,
                 Object value)
        Stores the given object in the cache.
        Parameters:
        key - A key.
        value - A value.
      • get

        Object get​(Object key)
        Parameters:
        key - A key
        Returns:
        The cached object, or null if the object is not in the cache.
      • get

        default <V> V get​(Object key,
                          Callable<V> valueLoader)
                   throws ExecutionException
        Parameters:
        key - A key
        valueLoader - A value loader which will be used if null is returned for the given key.
        Returns:
        The cached object, or if the object is not in the cache the result of the value loader.
        Throws:
        ExecutionException