com.waveset.expression
Class ExRule.Argument

java.lang.Object
  extended bycom.waveset.expression.ExNode
      extended bycom.waveset.expression.ExRule.Argument
All Implemented Interfaces:
com.sun.idm.debugger.common.Locatable
Enclosing class:
ExRule

public static class ExRule.Argument
extends ExNode

A node found only within expressions to represent the arguments to the rule.


Field Summary
 
Fields inherited from class com.waveset.expression.ExNode
_bindingCount, _children, _decoration, _parent, code_id, trace
 
Constructor Summary
ExRule.Argument()
           
 
Method Summary
protected  ExValue evalInternal(ExState state)
          We should only be evaluated in the context of the ExRule.
 java.lang.String getFunctionName()
          Nodes representing functions must have a name.
 java.lang.String getName()
           
 ExNode getValueExpression()
           
 void parseXml(org.w3c.dom.Element el)
          Default XML parsing method.
 void setName(java.lang.String name)
           
 void setValueExpression(ExNode exp)
           
 void toXml(java.lang.StringBuffer b, int indent)
          Serialize the node back to XML.
 void toXmlAttributes(java.lang.StringBuffer b)
          Add our attributes to the default XML serialization.
 
Methods inherited from class com.waveset.expression.ExNode
addChild, addChildren, addCommonAttributes, beginTrace, clearOwner, endTrace, eval, evalChild, evalChildToObject, evalChildToString, evalToBoolean, evalToInt, evalToObject, evalToString, getBindingCount, getChild, getChildren, getDecoration, getHiddenVariable, getLocation, getOwner, getParent, isLiteral, parseCommonAttributes, postProcess, removeChild, resolveFunction, resolveVariable, setBindingCount, setChildren, setDecoration, setEnvironment, setLocation, setOwner, setOwner, setParent, toXml, toXml, toXmlChildren
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ExRule.Argument

public ExRule.Argument()
Method Detail

getFunctionName

public java.lang.String getFunctionName()
Description copied from class: ExNode
Nodes representing functions must have a name. This name is used in the formatting of default trace messages and the default XML rendering. If a node doesn't have a name for some reason, or needs more control over the trace messges and XML, they must overload beginTrace, endTrace, and toXml below.

Specified by:
getFunctionName in class ExNode

getName

public java.lang.String getName()

setName

public void setName(java.lang.String name)

getValueExpression

public ExNode getValueExpression()

setValueExpression

public void setValueExpression(ExNode exp)

parseXml

public void parseXml(org.w3c.dom.Element el)
              throws WavesetException
Description copied from class: ExNode
Default XML parsing method. Parses the child elements into a list of child nodes.

Overrides:
parseXml in class ExNode
Throws:
WavesetException

toXmlAttributes

public void toXmlAttributes(java.lang.StringBuffer b)
Add our attributes to the default XML serialization. Even though we don't call this, implement it for trace.

Overrides:
toXmlAttributes in class ExNode

toXml

public void toXml(java.lang.StringBuffer b,
                  int indent)
Serialize the node back to XML. The ExNode implementation is not usually overloaded, but here we want to convert the ExValueNode/ExReference expansion we did in parseXml back to a value attribute.

Overrides:
toXml in class ExNode

evalInternal

protected ExValue evalInternal(ExState state)
                        throws WavesetException
We should only be evaluated in the context of the ExRule. we only return the value of the argument, it is assumed the container is managing the association of the value and the argument name in some way.

Specified by:
evalInternal in class ExNode
Throws:
WavesetException