treeNodes
Class AbstractUnaryOperation

java.lang.Object
  extended by generalHelpers.TreeNode
      extended by treeNodes.AbstractExpression
          extended by treeNodes.AbstractUnaryOperation
Direct Known Subclasses:
Complement, IsVoid, Negate

public abstract class AbstractUnaryOperation
extends AbstractExpression

This class is used to join the common code of all unary operations. From class all unary operations (arithmetical, logical and other) are derived.


Field Summary
protected  AbstractExpression e1
           
 
Fields inherited from class generalHelpers.TreeNode
lineNumber
 
Constructor Summary
AbstractUnaryOperation(int lineNumber, AbstractExpression a1)
           
 
Method Summary
 void dump(java.io.Writer out, int n)
          Pretty-prints this node to this output stream.
 void dumpWithTypes(java.io.Writer out, int n)
           
 AbstractExpression getExpr()
           
protected abstract  java.lang.String getTag()
          This function is used by the dump-functions to specialize output to the subclass
 
Methods inherited from class treeNodes.AbstractExpression
dumpType, getType, setType
 
Methods inherited from class generalHelpers.TreeNode
copy, copyAbstractSymbol, copyBoolean, dumpAbstractSymbol, dumpBoolean, dumpLine, getLineNumber, set
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

e1

protected AbstractExpression e1
Constructor Detail

AbstractUnaryOperation

public AbstractUnaryOperation(int lineNumber,
                              AbstractExpression a1)
Method Detail

getExpr

public AbstractExpression getExpr()

dump

public void dump(java.io.Writer out,
                 int n)
          throws java.io.IOException
Description copied from class: TreeNode
Pretty-prints this node to this output stream.

Specified by:
dump in class TreeNode
Parameters:
out - the output stream
n - the number of spaces to indent the output
Throws:
java.io.IOException

dumpWithTypes

public void dumpWithTypes(java.io.Writer out,
                          int n)
                   throws java.io.IOException
Specified by:
dumpWithTypes in class AbstractExpression
Throws:
java.io.IOException

getTag

protected abstract java.lang.String getTag()
This function is used by the dump-functions to specialize output to the subclass

Returns:
a tag specific to the subclass