Package org.apache.uima.internal.util
Class ClassLoaderUtils
java.lang.Object
org.apache.uima.internal.util.ClassLoaderUtils
INTERNAL API - Helper functions to obtain a suitable class loader.
-
Method Summary
Modifier and TypeMethodDescriptionstatic ClassLoader
Looks up a suitable class loader in the following order: TheUimaContext
in theUimaContextHolder
of the current thread(if any) The current thread-context class loader (if any) The class loader through which uimaFIT (i.e. this class) was loaded. For backwards compatibility then delegates togetDefaultClassLoader()
static ClassLoader
findClassLoader
(ResourceManager aResMgr) Looks up a suitable class loader in the following order: The extension class loader of the givenResourceManager
SeefindClassLoader()
static ClassLoader
findClassLoader
(UimaContext aContext) Looks up a suitable class loader in the following order: The extension class loader of theResourceManager
associated with the givenUimaContext
(if any) SeefindClassLoader(ResourceManager)
-
Method Details
-
findClassLoader
Looks up a suitable class loader in the following order:- The
UimaContext
in theUimaContextHolder
of the current thread(if any) - The current thread-context class loader (if any)
- The class loader through which uimaFIT (i.e. this class) was loaded.
- For backwards compatibility then delegates to
getDefaultClassLoader()
- Returns:
- a class loader or
null
if no suitable class loader could be found.
- The
-
findClassLoader
Looks up a suitable class loader in the following order:- The extension class loader of the given
ResourceManager
- See
findClassLoader()
- Returns:
- a class loader or
null
if no suitable class loader could be found.
- The extension class loader of the given
-
findClassLoader
Looks up a suitable class loader in the following order:- The extension class loader of the
ResourceManager
associated with the givenUimaContext
(if any) - See
findClassLoader(ResourceManager)
- Returns:
- a class loader or
null
if no suitable class loader could be found.
- The extension class loader of the
-