public static class ClassLoaderLimiter.Builder extends Object
| Modifier and Type | Method and Description |
|---|---|
ClassLoaderLimiter |
build() |
ClassLoaderLimiter.Builder |
loadedAtMostOnceResource(String resourceFullName)
Useful to check that a resource is being loaded only once, or never.
|
ClassLoaderLimiter.Builder |
neverLoadedClassName(String vetoedClassName)
List a fully qualified class name as one that you don't expect to be loaded ever.
|
ClassLoaderLimiter.Builder |
neverLoadedResource(String resourceFullName)
List a resource name as one that you don't expect to be loaded ever.
|
ClassLoaderLimiter.Builder |
produceStackTraceOnLoad(String resourceFullName)
When the specified resource is loaded, print a full stack trace on System out.
|
ClassLoaderLimiter.Builder |
traceAllResourceLoad(boolean enable)
Simply log all resource loading events.
|
public ClassLoaderLimiter.Builder neverLoadedResource(String resourceFullName)
resourceFullName - the resource namepublic ClassLoaderLimiter.Builder neverLoadedClassName(String vetoedClassName)
literal.class.getName() as this will implicitly get you
to load the class during the test, and produce a failure.
Limitations: if the class is being loaded using the bootstrap classloader we
can't check it. Most Quarkus extensions and frameworks will not use the bootstrap classloader,
but some code could make use of it explicitly.vetoedClassName - the fully qualified class namepublic ClassLoaderLimiter.Builder loadedAtMostOnceResource(String resourceFullName)
resourceFullName - the resource namepublic ClassLoaderLimiter.Builder produceStackTraceOnLoad(String resourceFullName)
resourceFullName - public ClassLoaderLimiter.Builder traceAllResourceLoad(boolean enable)
enable - public ClassLoaderLimiter build()
Copyright © 2021 JBoss by Red Hat. All rights reserved.