Class PDWR<K,​V>

    • Constructor Detail

      • PDWR

        PDWR()
      • PDWR

        PDWR​(K key,
             java.lang.ref.ReferenceQueue<K> keyReferenceQueue,
             V value,
             java.lang.ref.ReferenceQueue<V> valueReferenceQueue,
             int weight,
             long now)
      • PDWR

        PDWR​(java.lang.Object keyReference,
             V value,
             java.lang.ref.ReferenceQueue<V> valueReferenceQueue,
             int weight,
             long now)
    • Method Detail

      • casWriteTime

        public final boolean casWriteTime​(long expect,
                                          long update)
        Description copied from class: Node
        Atomically sets the write time to the given updated value if the current value equals the expected value and returns if the update was successful.
        Overrides:
        casWriteTime in class Node<K,​V>
      • newNode

        public Node<K,​V> newNode​(K key,
                                       java.lang.ref.ReferenceQueue<K> keyReferenceQueue,
                                       V value,
                                       java.lang.ref.ReferenceQueue<V> valueReferenceQueue,
                                       int weight,
                                       long now)
        Description copied from interface: NodeFactory
        Returns a node optimized for the specified features.
        Specified by:
        newNode in interface NodeFactory<K,​V>
        Overrides:
        newNode in class PDW<K,​V>
      • newNode

        public Node<K,​V> newNode​(java.lang.Object keyReference,
                                       V value,
                                       java.lang.ref.ReferenceQueue<V> valueReferenceQueue,
                                       int weight,
                                       long now)
        Description copied from interface: NodeFactory
        Returns a node optimized for the specified features.
        Specified by:
        newNode in interface NodeFactory<K,​V>
        Overrides:
        newNode in class PDW<K,​V>