| java.lang.Object gnu.mapping.Procedure gnu.mapping.ProcedureN gnu.expr.ModuleBody
ModuleBody | public class ModuleBody extends ProcedureN (Code) | | Abstract class for the dummy top-level function of a module.
This provides the functionality of gnu.mapping.ApplyMethodContainer,
but it is class rather than an interface (thus ModuleMethod can use
faster virtual method calls instead of slower interface calls).
|
Method Summary | |
public Object | apply0(ModuleMethod method) | public Object | apply1(ModuleMethod method, Object arg1) | public Object | apply2(ModuleMethod method, Object arg1, Object arg2) | public Object | apply3(ModuleMethod method, Object arg1, Object arg2, Object arg3) | public Object | apply4(ModuleMethod method, Object arg1, Object arg2, Object arg3, Object arg4) | public Object | applyN(Object[] o) This is invoked by main when ModuleBody is compiled with --main. | public Object | applyN(ModuleMethod method, Object[] args) | public static boolean | getMainPrintValues() True if runAsMain should print values (in top-level expressions). | public static void | setMainPrintValues(boolean value) |
apply0 | public Object apply0(ModuleMethod method)(Code) | | A subclass will typically override this like:
switch (method.selector) {
case 3: return function3();
case 5: return function5();
default: super.apply0(method);
}
|
applyN | public Object applyN(Object[] o)(Code) | | This is invoked by main when ModuleBody is compiled with --main.
|
getMainPrintValues | public static boolean getMainPrintValues()(Code) | | True if runAsMain should print values (in top-level expressions).
|
setMainPrintValues | public static void setMainPrintValues(boolean value)(Code) | | |
Methods inherited from gnu.mapping.Procedure | public void apply(Runnable ctx) throws Throwable(Code)(Java Doc) abstract public Object apply0() throws Throwable(Code)(Java Doc) abstract public Object apply1(Object arg1) throws Throwable(Code)(Java Doc) abstract public Object apply2(Object arg1, Object arg2) throws Throwable(Code)(Java Doc) abstract public Object apply3(Object arg1, Object arg2, Object arg3) throws Throwable(Code)(Java Doc) abstract public Object apply4(Object arg1, Object arg2, Object arg3, Object arg4) throws Throwable(Code)(Java Doc) abstract public Object applyN(Object[] args) throws Throwable(Code)(Java Doc) public static void checkArgCount(Procedure proc, int argCount)(Code)(Java Doc) public String getName()(Code)(Java Doc) public Object getProperty(Object key, Object defaultValue)(Code)(Java Doc) public Procedure getSetter()(Code)(Java Doc) final public int maxArgs()(Code)(Java Doc) final public int minArgs()(Code)(Java Doc) final public String name()(Code)(Java Doc) public int numArgs()(Code)(Java Doc) public Object removeProperty(Object key)(Code)(Java Doc) public void set0(Object result) throws Throwable(Code)(Java Doc) public void set1(Object arg1, Object value) throws Throwable(Code)(Java Doc) public void setN(Object[] args) throws Throwable(Code)(Java Doc) final public void setName(String name)(Code)(Java Doc) public synchronized void setProperty(Object key, Object value)(Code)(Java Doc) public static Object[] setProperty(Object[] properties, Object key, Object value)(Code)(Java Doc) public String toString()(Code)(Java Doc)
|
|
|