Class AbstractKeyValueStore<K,​V>

    • Constructor Detail

      • AbstractKeyValueStore

        protected AbstractKeyValueStore​(String namespace,
                                        boolean readOnly)
        Instantiates a new Abstract navigable key value store.
        Parameters:
        namespace - the namespace
        readOnly - the read only
    • Method Detail

      • clear

        public void clear()
        Specified by:
        clear in interface Map<K,​V>
      • delegate

        protected abstract Map<K,​V> delegate()
        Delegate navigable map.
        Returns:
        the navigable map
      • get

        public V get​(Object o)
        Specified by:
        get in interface Map<K,​V>
      • isEmpty

        public boolean isEmpty()
        Specified by:
        isEmpty in interface Map<K,​V>
      • isReadOnly

        public boolean isReadOnly()
        Description copied from interface: KeyValueStore
        Is this key-value store read-only?
        Specified by:
        isReadOnly in interface KeyValueStore<K,​V>
        Returns:
        True - read only, False - writeable
      • keySet

        public Set<K> keySet()
        Specified by:
        keySet in interface Map<K,​V>
      • put

        public V put​(K k,
                     V v)
        Specified by:
        put in interface Map<K,​V>
      • putAll

        public void putAll​(Map<? extends K,​? extends V> map)
        Specified by:
        putAll in interface Map<K,​V>
      • size

        public int size()
        Specified by:
        size in interface Map<K,​V>
      • sizeAsLong

        public long sizeAsLong()
        Description copied from interface: KeyValueStore
        Gets the number of keys in the store as a long
        Specified by:
        sizeAsLong in interface KeyValueStore<K,​V>
        Returns:
        the number of keys in the store