|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.objectweb.proactive.core.mop.MOP
A place where static methods go
Field Summary | |
protected static java.lang.Class[] |
EMPTY_CLASS_ARRAY
Class array representing no parameters |
protected static java.lang.Object[] |
EMPTY_OBJECT_ARRAY
Empty object array |
protected static java.util.HashMap |
loadedClass
As this class is center to the API, its static initializer is a good place to initialize general stuff. |
protected static org.apache.log4j.Logger |
logger
|
protected static java.lang.Class[] |
PROXY_CONSTRUCTOR_PARAMETERS_TYPES_ARRAY
Class array representing (Constructor Call, Object[]) |
protected static java.util.Hashtable |
proxyTable
A Hashtable to cache (proxy class, proxy class constructor) couples |
protected static java.util.Hashtable |
secondProxyTable
A Hashtable to cache (Class name, proxy class name) couples this is meant for class-based reification |
protected static MOPClassLoader |
singleton
|
protected static java.lang.Class |
STUB_OBJECT_INTERFACE
|
protected static java.lang.String |
STUB_OBJECT_INTERFACE_NAME
The name of the interface that caracterizes all stub classes |
protected static java.util.Hashtable |
stubTable
A Hashtable to cache (reified class, stub class constructor) couples. |
Constructor Summary | |
MOP()
|
Method Summary | |
protected static void |
addClassToCache(java.lang.String name,
java.lang.Class cl)
|
static void |
checkClassIsReifiable(java.lang.Class cl)
|
protected static boolean |
checkNoArgsConstructor(java.lang.Class cl)
Checks if class c has a noargs constructor |
static java.lang.Class |
forName(java.lang.String s)
Loads a class using standard classloader or a hashtable |
static boolean |
isReifiedObject(java.lang.Object o)
Checks if an object is a stub object Being a stub object is equivalent to implementing the StubObject interface |
static java.lang.Class |
loadClass(java.lang.String name)
|
static java.lang.Object |
newInstance(java.lang.Class clazz,
java.lang.Object[] constructorParameters,
java.lang.String nameOfProxy,
java.lang.Object[] proxyParameters)
|
static java.lang.Object |
newInstance(java.lang.Class stubClass,
java.lang.String nameOfClass,
java.lang.Object[] constructorParameters,
java.lang.String nameOfProxy,
java.lang.Object[] proxyParameters)
|
static java.lang.Object |
newInstance(java.lang.String nameOfClass,
java.lang.Object[] constructorParameters,
java.lang.String nameOfProxy,
java.lang.Object[] proxyParameters)
Creates an instance of an object |
static java.lang.Object |
newInstance(java.lang.String nameOfStubClass,
java.lang.String nameOfClass,
java.lang.Object[] constructorParameters,
java.lang.String nameOfProxy,
java.lang.Object[] proxyParameters)
Creates an instance of an object |
static java.lang.Object |
turnReified(java.lang.String nameOfProxyClass,
java.lang.Object[] proxyParameters,
java.lang.Object target)
Reifies an object |
static java.lang.Object |
turnReified(java.lang.String nameOfStubClass,
java.lang.String nameOfProxyClass,
java.lang.Object[] proxyParameters,
java.lang.Object target)
Reifies an object |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected static java.lang.String STUB_OBJECT_INTERFACE_NAME
protected static java.lang.Class STUB_OBJECT_INTERFACE
protected static org.apache.log4j.Logger logger
protected static final java.lang.Class[] EMPTY_CLASS_ARRAY
protected static final java.lang.Object[] EMPTY_OBJECT_ARRAY
protected static java.lang.Class[] PROXY_CONSTRUCTOR_PARAMETERS_TYPES_ARRAY
protected static java.util.Hashtable stubTable
protected static java.util.Hashtable proxyTable
protected static java.util.Hashtable secondProxyTable
protected static MOPClassLoader singleton
protected static java.util.HashMap loadedClass
Constructor Detail |
public MOP()
Method Detail |
public static java.lang.Class forName(java.lang.String s) throws java.lang.ClassNotFoundException
s
- the name of the class to fetch
java.lang.ClassNotFoundException
public static java.lang.Object newInstance(java.lang.String nameOfClass, java.lang.Object[] constructorParameters, java.lang.String nameOfProxy, java.lang.Object[] proxyParameters) throws java.lang.ClassNotFoundException, ClassNotReifiableException, InvalidProxyClassException, ConstructionOfProxyObjectFailedException, ConstructionOfReifiedObjectFailedException
nameOfClass
- The class to instanciateconstructorParameters
- Array of the constructor's parameters [wrapper]nameOfProxy
- The name of its proxy classproxyParameters
- The array holding the proxy parameter
java.lang.ClassNotFoundException
ClassNotReifiableException
InvalidProxyClassException
ConstructionOfProxyObjectFailedException
ConstructionOfReifiedObjectFailedException
public static java.lang.Object newInstance(java.lang.Class clazz, java.lang.Object[] constructorParameters, java.lang.String nameOfProxy, java.lang.Object[] proxyParameters) throws java.lang.ClassNotFoundException, ClassNotReifiableException, InvalidProxyClassException, ConstructionOfProxyObjectFailedException, ConstructionOfReifiedObjectFailedException
java.lang.ClassNotFoundException
ClassNotReifiableException
InvalidProxyClassException
ConstructionOfProxyObjectFailedException
ConstructionOfReifiedObjectFailedException
public static java.lang.Object newInstance(java.lang.String nameOfStubClass, java.lang.String nameOfClass, java.lang.Object[] constructorParameters, java.lang.String nameOfProxy, java.lang.Object[] proxyParameters) throws java.lang.ClassNotFoundException, ClassNotReifiableException, ReifiedCastException, InvalidProxyClassException, ConstructionOfProxyObjectFailedException, ConstructionOfReifiedObjectFailedException
nameOfStubClass
- The name of the Stub class corresponding to the objectnameOfClass
- The class to instanciateconstructorParameters
- Array of the constructor's parameters [wrapper]nameOfProxy
- The name of its proxy classproxyParameters
- The array holding the proxy parameter
java.lang.ClassNotFoundException
ClassNotReifiableException
ReifiedCastException
InvalidProxyClassException
ConstructionOfProxyObjectFailedException
ConstructionOfReifiedObjectFailedException
public static java.lang.Object newInstance(java.lang.Class stubClass, java.lang.String nameOfClass, java.lang.Object[] constructorParameters, java.lang.String nameOfProxy, java.lang.Object[] proxyParameters) throws java.lang.ClassNotFoundException, ClassNotReifiableException, ReifiedCastException, InvalidProxyClassException, ConstructionOfProxyObjectFailedException, ConstructionOfReifiedObjectFailedException
java.lang.ClassNotFoundException
ClassNotReifiableException
ReifiedCastException
InvalidProxyClassException
ConstructionOfProxyObjectFailedException
ConstructionOfReifiedObjectFailedException
public static java.lang.Object turnReified(java.lang.String nameOfProxyClass, java.lang.Object[] proxyParameters, java.lang.Object target) throws java.lang.ClassNotFoundException, ClassNotReifiableException, InvalidProxyClassException, ConstructionOfProxyObjectFailedException
nameOfProxyClass
- the name of the object's proxyproxyParameters
- Array holding the proxy parameterstarget
- the object to reify
java.lang.ClassNotFoundException
ClassNotReifiableException
InvalidProxyClassException
ConstructionOfProxyObjectFailedException
public static java.lang.Object turnReified(java.lang.String nameOfStubClass, java.lang.String nameOfProxyClass, java.lang.Object[] proxyParameters, java.lang.Object target) throws java.lang.ClassNotFoundException, ReifiedCastException, ClassNotReifiableException, InvalidProxyClassException, ConstructionOfProxyObjectFailedException
nameOfProxyClass
- the name of the object's proxynameOfStubClass
- The name of the object's stub classproxyParameters
- Array holding the proxy parameterstarget
- the object to reify
java.lang.ClassNotFoundException
ReifiedCastException
ClassNotReifiableException
InvalidProxyClassException
ConstructionOfProxyObjectFailedException
public static void checkClassIsReifiable(java.lang.Class cl) throws ClassNotReifiableException
ClassNotReifiableException
protected static boolean checkNoArgsConstructor(java.lang.Class cl)
c
has a noargs constructor
public static boolean isReifiedObject(java.lang.Object o)
o
- the object to check
true
if it is a stub object, false
otherwiseprotected static void addClassToCache(java.lang.String name, java.lang.Class cl)
public static java.lang.Class loadClass(java.lang.String name) throws java.lang.ClassNotFoundException
java.lang.ClassNotFoundException
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |