edu.toronto.cs.expr
Class NamedOp

java.lang.Object
  extended by edu.toronto.cs.expr.NamedOp
All Implemented Interfaces:
Operator
Direct Known Subclasses:
BiLatticeOp, BoolOp, CILAssignOp, CILBitwiseOp, CILBreakOp, CILDeclarationOp, CILEnumOp, CILFunctionCallOp, CILFunctionDefOp, CILGotoOp, CILIfStmtOp, CILIndirectionOp, CILLabelledStmtOp, CILListOp, CILNDGotoOp, CILProgramOp, CILRecordOp, CILReturnOp, CILScopeOp, CILTypeSpecifierOp, CILUnknownOp, CILWhileOp, ComparisonOp, CTLOp, NumericOp

public abstract class NamedOp
extends java.lang.Object
implements Operator


Constructor Summary
NamedOp(java.lang.String _name, int _arity)
           
 
Method Summary
 int arity()
          Arrity of this operator
 boolean equals(java.lang.Object o)
           
 boolean isWellFormed(Expr[] args)
          true if this operator is well-formed with this arguments provided that the arguments are well formed themselves
 java.lang.String name()
          Name of this operator
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NamedOp

public NamedOp(java.lang.String _name,
               int _arity)
Method Detail

arity

public int arity()
Description copied from interface: Operator
Arrity of this operator

Specified by:
arity in interface Operator
Returns:
an int value

name

public java.lang.String name()
Description copied from interface: Operator
Name of this operator

Specified by:
name in interface Operator
Returns:
a String value

isWellFormed

public boolean isWellFormed(Expr[] args)
Description copied from interface: Operator
true if this operator is well-formed with this arguments provided that the arguments are well formed themselves

Specified by:
isWellFormed in interface Operator
Parameters:
args - an Expr[] value
Returns:
a boolean value

equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class java.lang.Object