org.ow2.petals.component.framework.util
Class ClassLoaderUtil

java.lang.Object
  extended by org.ow2.petals.component.framework.util.ClassLoaderUtil

public final class ClassLoaderUtil
extends java.lang.Object

This class is used to create classloader for JBI components.

Since:
1.0
Author:
alouis - EBM Websourcing

Method Summary
static java.net.URLClassLoader createClassLoader(java.lang.String rootPath, java.lang.ClassLoader parent)
          Return an URLClassLoader object, with the root path directory and all Jar contained in the given directory path.
static java.net.URL[] getUrls(java.lang.String directoryName)
          Returns an URL[] table, with the root path directory and all Jar contained in the given directory path.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getUrls

public static java.net.URL[] getUrls(java.lang.String directoryName)
Returns an URL[] table, with the root path directory and all Jar contained in the given directory path.

Parameters:
directoryName - directory containing the Jars
Returns:
an URL[] table

createClassLoader

public static java.net.URLClassLoader createClassLoader(java.lang.String rootPath,
                                                        java.lang.ClassLoader parent)
Return an URLClassLoader object, with the root path directory and all Jar contained in the given directory path.

Parameters:
rootPath - directory containing the Jars
parent - the parent classloader to use
Returns:
a classLoader


Copyright © 2005-2011 Petals Link (EBM Websourcing). All Rights Reserved.