|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.toronto.cs.expr.AbstractExpr
edu.toronto.cs.expr.ClosureExpr
public class ClosureExpr
Field Summary | |
---|---|
static Operator |
CLOSURE
|
Fields inherited from interface edu.toronto.cs.expr.Expr |
---|
EMPTY_EXPR_ARRAY |
Constructor Summary | |
---|---|
ClosureExpr(Expr _body,
Expr[] _params)
|
Method Summary | |
---|---|
Expr |
arg(int i)
returns i'th argument constraint: 0 <= i < arity () |
java.util.List |
args()
The list of arguments |
int |
arity()
True arity of this expression, i.e. |
Expr |
getBody()
|
ExprFactory |
getFactory()
Returns a factory for this expression |
Expr[] |
getParams()
|
boolean |
isWellFormed()
Checks if this expression is well formed |
Expr |
naryApply(Expr[] args)
n-ary application |
Operator |
op()
Operator of this expression |
Expr |
subst(java.util.Map subMap)
Substitution of expressions by expressions |
Expr |
substOp(java.util.Map subMap)
Substitutes operators in the expression |
Methods inherited from class edu.toronto.cs.expr.AbstractExpr |
---|
binApply, contains, naryApply, unaryApply |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static Operator CLOSURE
Constructor Detail |
---|
public ClosureExpr(Expr _body, Expr[] _params)
Method Detail |
---|
public Expr getBody()
public Expr[] getParams()
public Operator op()
Expr
Operator
valuepublic Expr naryApply(Expr[] args)
Expr
args
- an Expr[]
value
Expr
valuepublic int arity()
Expr
int
valuepublic Expr arg(int i)
Expr
i
- an int
value
Expr
valuepublic java.util.List args()
Expr
Collection
valuepublic boolean isWellFormed()
Expr
boolean
valuepublic Expr subst(java.util.Map subMap)
Expr
subMap
- a Map
of type Expr -> Expr
Expr
valuepublic Expr substOp(java.util.Map subMap)
Expr
subMap
- a map of type Operator -> Expr
mapping operators to be replaced by an expression
Expr
valuepublic ExprFactory getFactory()
Expr
ExprFactory
value
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |