Package org.jboss.modules
Class NativeLibraryResourceLoader
- java.lang.Object
-
- org.jboss.modules.AbstractResourceLoader
-
- org.jboss.modules.NativeLibraryResourceLoader
-
- All Implemented Interfaces:
java.lang.AutoCloseable,ResourceLoader
public class NativeLibraryResourceLoader extends AbstractResourceLoader
A base class for resource loaders which can load native libraries.- Author:
- David M. Lloyd
-
-
Constructor Summary
Constructors Constructor Description NativeLibraryResourceLoader(java.io.File root)Construct a new instance.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static java.lang.StringgetArchName()Get the detected architecture name for this platform.java.lang.StringgetLibrary(java.lang.String name)Get the absolute physical filesystem path for a library with the given name.java.net.URIgetLocation()Get the base location of the resources in this loader (if any).java.io.FilegetRoot()Get the filesystem root of the resource loader.-
Methods inherited from class org.jboss.modules.AbstractResourceLoader
getClassSpec, getPackageSpec, getPackageSpec, getPaths, getResource, getRootName
-
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.ResourceLoader
close, createSubloader
-
-
-
-
Method Detail
-
getLibrary
public java.lang.String getLibrary(java.lang.String name)
Get the absolute physical filesystem path for a library with the given name. The resultant path should be path-separated using "/" characters.- Specified by:
getLibraryin interfaceResourceLoader- Overrides:
getLibraryin classAbstractResourceLoader- Parameters:
name- the name- Returns:
- the path or
nullif the library is not present
-
getLocation
public java.net.URI getLocation()
Description copied from interface:ResourceLoaderGet the base location of the resources in this loader (if any). If the location is not known, or the resource loader does not support locations, or the resource loader does not support this method,nullis returned.- Returns:
- the base location of the resources in this loader, or
nullif not available
-
getRoot
public java.io.File getRoot()
Get the filesystem root of the resource loader.- Returns:
- the filesystem root of the resource loader
-
getArchName
public static java.lang.String getArchName()
Get the detected architecture name for this platform.- Returns:
- the architecture name
-
-