java.lang.Object
org.jboss.modules.FileSystemClassPathModuleFinder
- All Implemented Interfaces:
ModuleFinder
A module finder which loads modules from individual JARs or directories on the file system, supporting the JAR specification headers
as well as the extended
MANIFEST
headers supported by JBoss Modules. The JAR files or modules may in turn contain
nested module repositories inside of their modules
subdirectories. Modules in nested repositories are only visible
to the module that contains them.- Author:
- David M. Lloyd, Richard Opalka
-
Constructor Summary
ConstructorsConstructorDescriptionFileSystemClassPathModuleFinder
(Supplier<ModuleLoader> baseModuleLoaderSupplier, Supplier<ModuleLoader> extensionModuleLoaderSupplier) Construct a new instance.FileSystemClassPathModuleFinder
(ModuleLoader baseModuleLoader) Construct a new instance.FileSystemClassPathModuleFinder
(ModuleLoader baseModuleLoader, Supplier<ModuleLoader> extensionModuleLoaderSupplier) Construct a new instance. -
Method Summary
Modifier and TypeMethodDescriptionfindModule
(String name, ModuleLoader delegateLoader) Find a module specification for the given name.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.jboss.modules.ModuleFinder
findModule
-
Constructor Details
-
FileSystemClassPathModuleFinder
Construct a new instance.- Parameters:
baseModuleLoader
- the module loader to use to load module dependencies from (must not benull
)
-
FileSystemClassPathModuleFinder
public FileSystemClassPathModuleFinder(ModuleLoader baseModuleLoader, Supplier<ModuleLoader> extensionModuleLoaderSupplier) Construct a new instance.- Parameters:
baseModuleLoader
- the module loader to use to load module dependencies from (must not benull
)extensionModuleLoaderSupplier
- a supplier which yields a module loader for loading extensions (must not benull
)
-
FileSystemClassPathModuleFinder
public FileSystemClassPathModuleFinder(Supplier<ModuleLoader> baseModuleLoaderSupplier, Supplier<ModuleLoader> extensionModuleLoaderSupplier) Construct a new instance.- Parameters:
baseModuleLoaderSupplier
- the supplier to supply a module loader for loading dependencies (must not benull
)extensionModuleLoaderSupplier
- a supplier which yields a module loader for loading extensions (must not benull
)
-
-
Method Details
-
findModule
Description copied from interface:ModuleFinder
Find a module specification for the given name. The default implementation delegates to the legacyModuleFinder.findModule(ModuleIdentifier, ModuleLoader)
method.- Specified by:
findModule
in interfaceModuleFinder
- Parameters:
name
- the module namedelegateLoader
- the module loader from which dependencies should be resolved- Returns:
- the module specification, or
null
if no specification is found for this identifier - Throws:
ModuleLoadException
-