Package bsh
Class ClassGenerator
- java.lang.Object
-
- bsh.ClassGenerator
-
- Direct Known Subclasses:
ClassGeneratorImpl
public abstract class ClassGenerator extends Object
-
-
Constructor Summary
Constructors Constructor Description ClassGenerator()
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract Class
generateClass(String name, Modifiers modifiers, Class[] interfaces, Class superClass, bsh.BSHBlock block, boolean isInterface, CallStack callstack, Interpreter interpreter)
Parse the BSHBlock for the class definition and generate the class.static ClassGenerator
getClassGenerator()
abstract Object
invokeSuperclassMethod(BshClassManager bcm, Object instance, String methodName, Object[] args)
Invoke a super.method() style superclass method on an object instance.abstract void
setInstanceNameSpaceParent(Object instance, String className, NameSpace parent)
Change the parent of the class instance namespace.
-
-
-
Method Detail
-
getClassGenerator
public static ClassGenerator getClassGenerator() throws UtilEvalError
- Throws:
UtilEvalError
-
generateClass
public abstract Class generateClass(String name, Modifiers modifiers, Class[] interfaces, Class superClass, bsh.BSHBlock block, boolean isInterface, CallStack callstack, Interpreter interpreter) throws EvalError
Parse the BSHBlock for the class definition and generate the class.- Throws:
EvalError
-
invokeSuperclassMethod
public abstract Object invokeSuperclassMethod(BshClassManager bcm, Object instance, String methodName, Object[] args) throws UtilEvalError, bsh.ReflectError, InvocationTargetException
Invoke a super.method() style superclass method on an object instance. This is not a normal function of the Java reflection API and is provided by generated class accessor methods.- Throws:
UtilEvalError
bsh.ReflectError
InvocationTargetException
-
-