Class TimerWheel.Sentinel<K,​V>

    • Constructor Detail

      • Sentinel

        Sentinel()
    • Method Detail

      • getKey

        public @Nullable K getKey()
        Description copied from class: Node
        Return the key or null if it has been reclaimed by the garbage collector.
        Specified by:
        getKey in class Node<K,​V>
      • getKeyReference

        public java.lang.Object getKeyReference()
        Description copied from class: Node
        Returns the reference that the cache is holding the entry by. This is either the key if strongly held or a WeakReference to that key.
        Specified by:
        getKeyReference in class Node<K,​V>
      • getValue

        public @Nullable V getValue()
        Description copied from class: Node
        Return the value or null if it has been reclaimed by the garbage collector.
        Specified by:
        getValue in class Node<K,​V>
      • getValueReference

        public java.lang.Object getValueReference()
        Description copied from class: Node
        Returns the reference to the value. This is either the value if strongly held or a Reference to that value.
        Specified by:
        getValueReference in class Node<K,​V>
      • setValue

        public void setValue​(V value,
                             @Nullable java.lang.ref.ReferenceQueue<V> referenceQueue)
        Description copied from class: Node
        Sets the value, which may be held strongly, weakly, or softly. This update may be set lazily and rely on the memory fence when the lock is released.
        Specified by:
        setValue in class Node<K,​V>
      • containsValue

        public boolean containsValue​(java.lang.Object value)
        Description copied from class: Node
        Returns true if the given objects are considered equivalent. A strongly held value is compared by equality and a weakly or softly held value is compared by identity.
        Specified by:
        containsValue in class Node<K,​V>
      • isAlive

        public boolean isAlive()
        Description copied from class: Node
        If the entry is available in the hash-table and page replacement policy.
        Specified by:
        isAlive in class Node<K,​V>
      • isRetired

        public boolean isRetired()
        Description copied from class: Node
        If the entry was removed from the hash-table and is awaiting removal from the page replacement policy.
        Specified by:
        isRetired in class Node<K,​V>
      • isDead

        public boolean isDead()
        Description copied from class: Node
        If the entry was removed from the hash-table and the page replacement policy.
        Specified by:
        isDead in class Node<K,​V>
      • retire

        public void retire()
        Description copied from class: Node
        Sets the node to the retired state.
        Specified by:
        retire in class Node<K,​V>
      • die

        public void die()
        Description copied from class: Node
        Sets the node to the dead state.
        Specified by:
        die in class Node<K,​V>