Class CloseableMonitor.Hold
java.lang.Object
com.google.cloud.pubsublite.internal.CloseableMonitor.Hold
- All Implemented Interfaces:
AutoCloseable
- Enclosing class:
- CloseableMonitor
This is meant for use in the try-with-resources pattern. It will call leave() on a Monitor when
it goes out of scope. This is cannot be constructed directly, but through usage of the static
utility methods above.
-
Method Summary
-
Method Details
-
close
public void close()- Specified by:
closein interfaceAutoCloseable
-