JBoss Modules 1.1.2.GA

org.jboss.modules
Class NativeLibraryResourceLoader

java.lang.Object
  extended by org.jboss.modules.AbstractResourceLoader
      extended by org.jboss.modules.NativeLibraryResourceLoader
All Implemented Interfaces:
ResourceLoader

public class NativeLibraryResourceLoader
extends AbstractResourceLoader

A base class for resource loaders which can load native libraries.

Author:
David M. Lloyd

Constructor Summary
NativeLibraryResourceLoader(File root)
          Construct a new instance.
 
Method Summary
static String getArchName()
          Get the detected architecture name for this platform.
 String getLibrary(String name)
          Get the absolute physical filesystem path for a library with the given name.
 File getRoot()
          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
 

Constructor Detail

NativeLibraryResourceLoader

public NativeLibraryResourceLoader(File root)
Construct a new instance.

Parameters:
root - the filesystem root of the resource loader
Method Detail

getLibrary

public String getLibrary(String name)
Get the absolute physical filesystem path for a library with the given name. The resultant path should be path-separated using "/" characters. Returns null by default.

Specified by:
getLibrary in interface ResourceLoader
Overrides:
getLibrary in class AbstractResourceLoader
Parameters:
name - the name
Returns:
the path or null if the library is not present

getRoot

public File getRoot()
Get the filesystem root of the resource loader.

Returns:
the filesystem root of the resource loader

getArchName

public static String getArchName()
Get the detected architecture name for this platform.

Returns:
the architecture name

JBoss Modules 1.1.2.GA

Copyright © 2012 JBoss by Red Hat. All Rights Reserved.