Class ConcurrentWeakValueHashMap.MyReference<K,​T>

  • Enclosing class:
    ConcurrentWeakValueHashMap<K,​V>

    private static class ConcurrentWeakValueHashMap.MyReference<K,​T>
    extends java.lang.ref.WeakReference<T>
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private K key  
    • Constructor Summary

      Constructors 
      Constructor Description
      MyReference​(K key, T referent, java.lang.ref.ReferenceQueue<? super T> q)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      private boolean areEqual​(java.lang.Object p1, java.lang.Object p2)  
      boolean equals​(java.lang.Object o)  
      int hashCode()  
      • Methods inherited from class java.lang.ref.Reference

        clear, clone, enqueue, get, isEnqueued, reachabilityFence
      • Methods inherited from class java.lang.Object

        finalize, getClass, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • key

        private final K key
    • Constructor Detail

      • MyReference

        public MyReference​(K key,
                           T referent,
                           java.lang.ref.ReferenceQueue<? super T> q)
    • Method Detail

      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object
      • areEqual

        private boolean areEqual​(java.lang.Object p1,
                                 java.lang.Object p2)
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object