| java.lang.Object gnu.mapping.Procedure gnu.mapping.ProcedureN gnu.mapping.MethodProc gnu.expr.PrimProcedure
Constructor Summary | |
public | PrimProcedure(java.lang.reflect.Method method, Class thisClass, Class[] parameterClasses, Interpreter interpreter) | public | PrimProcedure(java.lang.reflect.Method method, Interpreter interpreter) | public | PrimProcedure(Method method) | public | PrimProcedure(Method method, java.util.Stack[] parameterCopies) | public | PrimProcedure(Method method, Interpreter interpreter) | public | PrimProcedure(Method method, LambdaExp source) | public | PrimProcedure(int opcode, Type retType, Type[] argTypes) | public | PrimProcedure(int op_code, ClassType classtype, String name, Type retType, Type[] argTypes) | public | PrimProcedure(ClassType classtype, Type[] argTypes) Use to compile new followed by constructor. |
Method Summary | |
public Object | applyV(CallContext ctx) | public void | compile(ApplyExp exp, Compilation comp, Target target) | public void | compile(Type thisType, Expression[] args, Compilation comp, Target target) | public static void | compileArgs(Expression[] args, Type thisType, Type[] argTypes, boolean variable, String name, LambdaExp source, Compilation comp) | public static void | compileArgs(Expression[] args, Type thisType, Type[] argTypes, boolean variable, String name, LambdaExp source, Compilation comp, java.util.Stack[] parameterCopies) Compile arguments and push unto stack.
Parameters: args - arguments to evaluate and push. Parameters: thisType - If we are calling a non-static function,then args[0] is the receiver and thisType is its expected class.If thisType==Type.void_type, ignore argTypes[0]. | public static PrimProcedure | getMethodFor(Procedure pproc, Expression[] args) | public static PrimProcedure | getMethodFor(Procedure pproc, Declaration decl, Expression[] args, Interpreter interpreter) Search for a matching static method in a procedure's class.
a PrimProcedure that is suitable, or null. | public static PrimProcedure | getMethodFor(Class procClass, String name, Declaration decl, Expression[] args, Interpreter interpreter) Get PrimProcedure for matching method in given class. | public String | getName() | public Type | getParameterType(int index) | final public Type[] | getParameterTypes() | public static Class | getProcedureClass(Object pproc) | public Type | getReturnType() | public Type | getReturnType(Expression[] args) | final public boolean | getStaticFlag() | public String | getVerboseName() | public static PrimProcedure | makeBuiltinBinary(int opcode, Type type) | public int | match(CallContext ctx, Object[] args) | public int | numArgs() | final public int | opcode() | public void | print(java.io.PrintWriter ps) | public void | setReturnType(Type retType) | public static PrimProcedure | specialCall(Method method) | public boolean | takesVarArgs() Return true iff the last parameter is a "rest" argument. | public String | toString() |
source | LambdaExp source(Code) | | If non-null, the LambdaExp that this PrimProcedure implements.
|
PrimProcedure | public PrimProcedure(int opcode, Type retType, Type[] argTypes)(Code) | | |
PrimProcedure | public PrimProcedure(ClassType classtype, Type[] argTypes)(Code) | | Use to compile new followed by constructor.
|
compileArgs | public static void compileArgs(Expression[] args, Type thisType, Type[] argTypes, boolean variable, String name, LambdaExp source, Compilation comp, java.util.Stack[] parameterCopies)(Code) | | Compile arguments and push unto stack.
Parameters: args - arguments to evaluate and push. Parameters: thisType - If we are calling a non-static function,then args[0] is the receiver and thisType is its expected class.If thisType==Type.void_type, ignore argTypes[0]. (It is used to topass a link to a closure environment, which was pushed by our caller.)If this_type==null, no special handling of args[0] or argTypes[0]. |
getParameterType | public Type getParameterType(int index)(Code) | | |
getParameterTypes | final public Type[] getParameterTypes()(Code) | | |
getStaticFlag | final public boolean getStaticFlag()(Code) | | |
numArgs | public int numArgs()(Code) | | |
opcode | final public int opcode()(Code) | | |
setReturnType | public void setReturnType(Type retType)(Code) | | |
takesVarArgs | public boolean takesVarArgs()(Code) | | Return true iff the last parameter is a "rest" argument.
|
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)
|
|
|