edu.toronto.cs.expr
Class AbstractExpr

java.lang.Object
  extended by edu.toronto.cs.expr.AbstractExpr
All Implemented Interfaces:
Expr
Direct Known Subclasses:
ClosureExpr

public abstract class AbstractExpr
extends java.lang.Object
implements Expr


Field Summary
 
Fields inherited from interface edu.toronto.cs.expr.Expr
EMPTY_EXPR_ARRAY
 
Constructor Summary
AbstractExpr()
           
 
Method Summary
 Expr binApply(Expr expr1, Expr expr2)
          Binary application
 boolean contains(Expr e)
          Returns true if this contains e, false otherwise.
 Expr naryApply(java.util.List expr)
           
 Expr unaryApply(Expr expr)
          Unary application
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface edu.toronto.cs.expr.Expr
arg, args, arity, getFactory, isWellFormed, naryApply, op, subst, substOp
 

Constructor Detail

AbstractExpr

public AbstractExpr()
Method Detail

unaryApply

public Expr unaryApply(Expr expr)
Description copied from interface: Expr
Unary application

Specified by:
unaryApply in interface Expr
Parameters:
expr - an Expr value
Returns:
an Expr value

binApply

public Expr binApply(Expr expr1,
                     Expr expr2)
Description copied from interface: Expr
Binary application

Specified by:
binApply in interface Expr
Returns:
an Expr value

naryApply

public Expr naryApply(java.util.List expr)
Specified by:
naryApply in interface Expr

contains

public boolean contains(Expr e)
Description copied from interface: Expr
Returns true if this contains e, false otherwise.

Specified by:
contains in interface Expr
Returns: