gnu.kawa.functions

Class ApplyToArgs

Implemented Interfaces:
CanInline, Named

public class ApplyToArgs
extends ProcedureN
implements CanInline

Implement the standard Scheme function "apply". This has been generalized so that the last (list argument) can be any sequence, or any primitive array coercible to Object[].

Field Summary

Fields inherited from class gnu.mapping.ProcedureN

noArgs

Constructor Summary

ApplyToArgs(String name, Language language)

Method Summary

Object
applyN(Object[] args)
void
check1(Object arg1, CallContext ctx)
void
check2(Object arg1, Object arg2, CallContext ctx)
void
check3(Object arg1, Object arg2, Object arg3, CallContext ctx)
void
check4(Object arg1, Object arg2, Object arg3, Object arg4, CallContext ctx)
void
checkN(Object[] args, CallContext ctx)
Expression
inline(ApplyExp exp, ExpWalker walker)
int
match1(Object arg1, CallContext ctx)
int
match2(Object arg1, Object arg2, CallContext ctx)
int
match3(Object arg1, Object arg2, Object arg3, CallContext ctx)
int
match4(Object arg1, Object arg2, Object arg3, Object arg4, CallContext ctx)
int
matchN(Object[] args, CallContext ctx)

Methods inherited from class gnu.mapping.ProcedureN

apply0, apply1, apply2, apply3, apply4, applyN

Methods inherited from class gnu.mapping.Procedure

apply, apply, apply0, apply1, apply2, apply3, apply4, applyN, check0, check1, check2, check3, check4, checkArgCount, checkN, getSetter, getSourceLocation, match0, match1, match2, match3, match4, matchN, maxArgs, minArgs, numArgs, set0, set1, setN, setSetter, setSourceLocation, toString

Methods inherited from class gnu.mapping.PropertySet

getName, getProperty, getSymbol, removeProperty, setName, setProperty, setProperty, setSymbol

Constructor Details

ApplyToArgs

public ApplyToArgs(String name,
                   Language language)

Method Details

applyN

public Object applyN(Object[] args)
            throws Throwable
Overrides:
applyN in interface ProcedureN

check1

public void check1(Object arg1,
                   CallContext ctx)
Overrides:
check1 in interface Procedure

check2

public void check2(Object arg1,
                   Object arg2,
                   CallContext ctx)
Overrides:
check2 in interface Procedure

check3

public void check3(Object arg1,
                   Object arg2,
                   Object arg3,
                   CallContext ctx)
Overrides:
check3 in interface Procedure

check4

public void check4(Object arg1,
                   Object arg2,
                   Object arg3,
                   Object arg4,
                   CallContext ctx)
Overrides:
check4 in interface Procedure

checkN

public void checkN(Object[] args,
                   CallContext ctx)
Overrides:
checkN in interface Procedure

inline

public Expression inline(ApplyExp exp,
                         ExpWalker walker)
Specified by:
inline in interface CanInline

match1

public int match1(Object arg1,
                  CallContext ctx)
Overrides:
match1 in interface Procedure

match2

public int match2(Object arg1,
                  Object arg2,
                  CallContext ctx)
Overrides:
match2 in interface Procedure

match3

public int match3(Object arg1,
                  Object arg2,
                  Object arg3,
                  CallContext ctx)
Overrides:
match3 in interface Procedure

match4

public int match4(Object arg1,
                  Object arg2,
                  Object arg3,
                  Object arg4,
                  CallContext ctx)
Overrides:
match4 in interface Procedure

matchN

public int matchN(Object[] args,
                  CallContext ctx)
Overrides:
matchN in interface Procedure