Package io.netty.util
Interface ResourceLeakTracker<T>
- All Known Implementing Classes:
ResourceLeakDetector.DefaultResourceLeak
public interface ResourceLeakTracker<T>
-
Method Summary
Modifier and TypeMethodDescriptionboolean
Close the leak so thatResourceLeakTracker
does not warn about leaked resources.void
record()
Records the caller's current stack trace so that theResourceLeakDetector
can tell where the leaked resource was accessed lastly.void
Records the caller's current stack trace and the specified additional arbitrary information so that theResourceLeakDetector
can tell where the leaked resource was accessed lastly.
-
Method Details
-
record
void record()Records the caller's current stack trace so that theResourceLeakDetector
can tell where the leaked resource was accessed lastly. This method is a shortcut torecord(null)
. -
record
Records the caller's current stack trace and the specified additional arbitrary information so that theResourceLeakDetector
can tell where the leaked resource was accessed lastly. -
close
Close the leak so thatResourceLeakTracker
does not warn about leaked resources. After this method is called a leak associated with this ResourceLeakTracker should not be reported.- Returns:
true
if called first time,false
if called already
-