public class X4OLanguageClassLoader extends Object
Constructor and Description |
---|
X4OLanguageClassLoader() |
Modifier and Type | Method and Description |
---|---|
static ClassLoader |
getClassLoader()
Gets the thread classloader or the normal classloader.
|
static Class<?> |
loadClass(String className)
Loads a Class from the ContextClassLoader and if that is not set, then
uses the class of the String className instance.
|
static Object |
newInstance(Class<?> clazz)
Creates new instance of clazz.
|
static Object |
newInstance(String className)
Creates new instance of className.
|
public X4OLanguageClassLoader()
public static ClassLoader getClassLoader()
public static Class<?> loadClass(String className) throws ClassNotFoundException
className
- The class name to loadClassNotFoundException
- if class not loaded.public static Object newInstance(Class<?> clazz) throws InstantiationException, IllegalAccessException
clazz
- The class to make object from.InstantiationException
- When className has no default constructor.IllegalAccessException
- When class loading has security error.public static Object newInstance(String className) throws ClassNotFoundException, InstantiationException, IllegalAccessException
className
- The className to create object from.ClassNotFoundException
- When className is not found.InstantiationException
- When className has no default constructor.IllegalAccessException
- When class loading has security error.Copyright © 2004-2012 X4O. All Rights Reserved.