-
public interface ResourceLeakTracker<T>
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description booleanclose(T trackedObject)Close the leak so thatResourceLeakTrackerdoes not warn about leaked resources.voidrecord()Records the caller's current stack trace so that theResourceLeakDetectorcan tell where the leaked resource was accessed lastly.voidrecord(Object hint)Records the caller's current stack trace and the specified additional arbitrary information so that theResourceLeakDetectorcan tell where the leaked resource was accessed lastly.
-
-
-
Method Detail
-
record
void record()
Records the caller's current stack trace so that theResourceLeakDetectorcan tell where the leaked resource was accessed lastly. This method is a shortcut torecord(null).
-
record
void record(Object hint)
Records the caller's current stack trace and the specified additional arbitrary information so that theResourceLeakDetectorcan tell where the leaked resource was accessed lastly.
-
close
boolean close(T trackedObject)
Close the leak so thatResourceLeakTrackerdoes not warn about leaked resources. After this method is called a leak associated with this ResourceLeakTracker should not be reported.- Returns:
trueif called first time,falseif called already
-
-