public interface AutoDisposable extends Disposable
Disposablethat keeps track of references to it and disposes the object automatically when there are no references left. At creation time an
AutoDisposablehas zero reference count so whenever same number of
acquire()calls, it will be automatically closed. Calling
Disposable.dispose()directly will dispose the object immediately regardless of the reference count.
|Modifier and Type||Method and Description|
Acquires a reference to this object preventing it from being automatically disposed until the reference is released.
Return the current reference count for this object.
Releases one of these object's references.
<T extends AutoDisposable> T acquire()
Copyright © 2010-2016 Stardog Union. All Rights Reserved.