Returns the reference count of this object. If {@code 0}, it means this object has been deallocated.
Decreases the reference count by the specified {@code decrement} and deallocates this object if the reference count reaches at {@code 0}.
Decreases the reference count by {@code 1} and deallocates this object if the reference count reaches at {@code 0}.
Increases the reference count by {@code 1}.
Increases the reference count by the specified {@code increment}.
Records the current access location of this object for debugging purposes. If this object is determined to be leaked, the information recorded by this operation will be provided to you via {@link ResourceLeakDetector}. This method is a shortcut to {@link #touch(Object) touch(null)}.
Records the current access location of this object with an additional arbitrary information for debugging purposes. If this object is determined to be leaked, the information recorded by this operation will be provided to you via {@link ResourceLeakDetector}.
A reference-counted object that requires explicit deallocation. <p> When a new {@link ReferenceCounted} is instantiated, it starts with the reference count of {@code 1}. {@link #retain()} increases the reference count, and {@link #release()} decreases the reference count. If the reference count is decreased to {@code 0}, the object will be deallocated explicitly, and accessing the deallocated object will usually result in an access violation. </p> <p> If an object that implements {@link ReferenceCounted} is a container of other objects that implement {@link ReferenceCounted}, the contained objects will also be released via {@link #release()} when the container's reference count becomes 0. </p>