Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.nfunk.jep
Class ASTFunNode

    java.lang.Object
      org.nfunk.jep.SimpleNode
          org.nfunk.jep.ASTFunNode

All Implemented Interfaces:
  Node

Direct Known Subclasses:
  ASTMFunNode

    public class ASTFunNode

extends SimpleNode

Function Node

Field Summary

Fields inherited from class org.nfunk.jep.SimpleNode
`children, id, parent, parser`

Constructor Summary
`ASTFunNode(int id)` Creates a new ASTFunNode
`ASTFunNode(Parser p, int id)` Creates a new ASTFunNode

Method Summary
`java.lang.String` | `getName()` Returns the name of the node (operator symbol or function name).
`Operator` | `getOperator()` Returns the id number of the operator if the node is an operator.
`PostfixMathCommandI` | `getPFMC()` Returns the math command class associated with this node.
`boolean` | `isOperator()` Returns true if node is an operator.
`java.lang.Object` | `jjtAccept(ParserVisitor visitor, java.lang.Object data)` Accept the visitor.
`void` | `setFunction(java.lang.String name_in, PostfixMathCommandI pfmc_in)` Sets the function for a node.
`void` | `setOperator(Operator op)` Sets the opID, name and pfmc for this node by looking up the values in the Operators class
`java.lang.String` | `toString()` Returns a string containing the function name.

Methods inherited from class org.nfunk.jep.SimpleNode
`childrenAccept, dump, getId, jjtAddChild, jjtClose, jjtGetChild, jjtGetNumChildren, jjtGetParent, jjtOpen, jjtSetParent, toString`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Constructor Detail

### ASTFunNode

    public ASTFunNode(int id)

  Creates a new ASTFunNode

### ASTFunNode

    public ASTFunNode(Parser p,
                      int id)

  Creates a new ASTFunNode

Method Detail

### jjtAccept

    public java.lang.Object jjtAccept(ParserVisitor visitor,
                                      java.lang.Object data)
                               throws ParseException

  Accept the visitor.

  Specified by:
    `jjtAccept` in interface `Node`
  Overrides:
    `jjtAccept` in class `SimpleNode`
  Throws:
    `ParseException`

### setFunction

    public void setFunction(java.lang.String name_in,
                            PostfixMathCommandI pfmc_in)

  Sets the function for a node. A name and function class must be specified.

### setOperator

    public void setOperator(Operator op)

  Sets the opID, name and pfmc for this node by looking up the values in the Operators class

### toString

    public java.lang.String toString()

  Returns a string containing the function name.

  Overrides:
    `toString` in class `SimpleNode`

### getPFMC

    public PostfixMathCommandI getPFMC()

  Returns the math command class associated with this node.

### getName

    public java.lang.String getName()

  Returns the name of the node (operator symbol or function name).

### getOperator

    public Operator getOperator()

  Returns the id number of the operator if the node is an operator.

### isOperator

    public boolean isOperator()

  Returns true if node is an operator.

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

http://www.singularsys.com/jep Copyright © 2007 Singular Systems