private static final class ResourceLeakDetectorFactory.DefaultResourceLeakDetectorFactory extends ResourceLeakDetectorFactory
| Modifier and Type | Field and Description |
|---|---|
private java.lang.reflect.Constructor<?> |
customClassConstructor |
| Constructor and Description |
|---|
DefaultResourceLeakDetectorFactory() |
| Modifier and Type | Method and Description |
|---|---|
private static java.lang.reflect.Constructor<?> |
customClassConstructor(java.lang.String customLeakDetector) |
<T> ResourceLeakDetector<T> |
newResourceLeakDetector(java.lang.Class<T> resource,
int samplingInterval,
long maxActive)
Returns a new instance of a
ResourceLeakDetector with the given resource class. |
instance, newResourceLeakDetector, setResourceLeakDetectorFactoryprivate final java.lang.reflect.Constructor<?> customClassConstructor
private static java.lang.reflect.Constructor<?> customClassConstructor(java.lang.String customLeakDetector)
public <T> ResourceLeakDetector<T> newResourceLeakDetector(java.lang.Class<T> resource, int samplingInterval, long maxActive)
ResourceLeakDetectorFactoryResourceLeakDetector with the given resource class.newResourceLeakDetector in class ResourceLeakDetectorFactoryT - - the type of the resource classresource - - the resource class used to initialize the ResourceLeakDetectorsamplingInterval - - the interval on which sampling takes placemaxActive - - the maximum active instancesResourceLeakDetector