Class ProxyManagerView<K,​KeyOld>

    • Method Detail

      • getProxy

        public BucketProxy getProxy​(K key,
                                    Supplier<BucketConfiguration> configurationSupplier)
        Description copied from interface: ProxyManager
        Creates bucket-proxy that configured by default parameters that set on proxy-manager level. In case if you need to configure something special for bucket like implicit config replacement you should to use ProxyManager.builder() instead of this method.
        Specified by:
        getProxy in interface ProxyManager<K>
        Parameters:
        key - the key that used in external storage to distinguish one bucket from another.
        configurationSupplier - provider for bucket configuration
        Returns:
        new instance of BucketProxy
      • getProxyConfiguration

        public Optional<BucketConfiguration> getProxyConfiguration​(K key)
        Description copied from interface: ProxyManager
        Locates configuration of bucket which actually stored in the underlying storage.
        Specified by:
        getProxyConfiguration in interface ProxyManager<K>
        Parameters:
        key - the unique identifier used to point to the bucket in external storage.
        Returns:
        Optional surround the configuration or empty optional if bucket with specified key is not stored.
      • removeProxy

        public void removeProxy​(K key)
        Description copied from interface: ProxyManager
        Removes persisted state of bucket from underlying storage.
        Specified by:
        removeProxy in interface ProxyManager<K>
        Parameters:
        key - the primary key of bucket which state need to be removed from underlying storage.
      • isExpireAfterWriteSupported

        public boolean isExpireAfterWriteSupported()
        Description copied from interface: ProxyManager
        Describes whether this manager supports expire-after-write feature.
        Specified by:
        isExpireAfterWriteSupported in interface ProxyManager<K>
        Returns:
        true if this manager supports expire-after-write feature.
      • withMapper

        public <K2> ProxyManager<K2> withMapper​(Function<? super K2,​? extends K> innerMapper)
        Description copied from interface: ProxyManager
        Returns a proxy object that wraps this ProxyManager such that keys are first mapped using the specified mapping function before being sent to the remote store. The returned ProxyManager shares the same underlying store as the original, and keys that map to the same value will share the same remote state.
        Specified by:
        withMapper in interface ProxyManager<K>
        Type Parameters:
        K2 - the type of key accepted by returned ProxyManager
        Parameters:
        innerMapper - the mapper function to apply to keys
        Returns:
        a proxy object that wraps this ProxyManager