Class ReferenceCountingMap.Instance<V extends Closeable>

java.lang.Object
io.grpc.xds.internal.security.ReferenceCountingMap.Instance<V>
Enclosing class:
ReferenceCountingMap<K,V extends Closeable>

private static final class ReferenceCountingMap.Instance<V extends Closeable> extends Object
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private int
     
    (package private) final V
     
  • Constructor Summary

    Constructors
    Constructor
    Description
    Instance(V value)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    (package private) V
    Increment refCount and acquire a reference to value.
    (package private) boolean
    Decrement refCount and return true if it has reached 0.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • value

      final V extends Closeable value
    • refCount

      private int refCount
  • Constructor Details

    • Instance

      Instance(V value)
  • Method Details

    • acquire

      V acquire()
      Increment refCount and acquire a reference to value.
    • release

      boolean release()
      Decrement refCount and return true if it has reached 0.