Class DoubleNode<K,​V>

  • Type Parameters:
    K - key
    V - value

    public class DoubleNode<K,​V>
    extends java.lang.Object
    Used for doubly linked lists with weak keys
    • Field Detail

      • weakKey

        private final java.lang.ref.WeakReference<K> weakKey
      • value

        private final V value
      • hardenedKey

        private K hardenedKey
    • Constructor Detail

      • DoubleNode

        public DoubleNode​(K key,
                          V value,
                          java.lang.ref.ReferenceQueue<? super K> queue)
    • Method Detail

      • getPrevious

        public DoubleNode<K,​V> getPrevious()
        Returns:
        the previous
      • setPrevious

        public void setPrevious​(DoubleNode<K,​V> previous)
        Parameters:
        previous - the previous to set
      • getNext

        public DoubleNode<K,​V> getNext()
        Returns:
        the next
      • setNext

        public void setNext​(DoubleNode<K,​V> next)
        Parameters:
        next - the next to set
      • getWeakKey

        public java.lang.ref.WeakReference<K> getWeakKey()
        Returns:
        the weakKey
      • getValue

        public V getValue()
        Returns:
        the value
      • getHardenedKey

        public K getHardenedKey()
        Returns:
        the hardenedKey
      • setHardenedKey

        public void setHardenedKey​(K hardenedKey)
        Parameters:
        hardenedKey - the hardenedKey to set