org.moremotion.evaluator
Class MMSymbolResolver

java.lang.Object
  extended by org.moremotion.evaluator.MMSymbolResolver
All Implemented Interfaces:
SymbolResolver

public class MMSymbolResolver
extends java.lang.Object
implements SymbolResolver

The Global Symbol Resolver for all types of symbols used in a MoreMotion environment:

Version:
$Id: MMSymbolResolver.java 162 2008-06-30 16:03:12Z erkan $

Field Summary
static int ADOM_NODE_PROCESSING_MODE_FIRST
           
static int ADOM_NODE_PROCESSING_MODE_IGNORE
           
static int ADOM_NODE_PROCESSING_MODE_LAST
           
 SymbolResolver assistant
           
 boolean bypassRIE
           
 
Fields inherited from interface org.moremotion.evaluator.SymbolResolver
DT_BOOL, DT_NULL, DT_NUMBER, DT_STRING
 
Constructor Summary
MMSymbolResolver(MoreMotionRequest request)
          Creates a new instance of SymbolResolver
 
Method Summary
 boolean doubleTheBackSlashes()
           
 java.lang.String doubleTheQuotes(java.lang.String source)
           
 ADOMNode getADOMNode()
           
 boolean getBoolValue(java.lang.String symbol)
          Returns the value of the given symbol as boolean.
 boolean getDisableQSpecifier()
           
 Logger getLogger()
           
 double getNumberValue(java.lang.String symbol)
          Returns the value of the given symbol as double.
 java.lang.Object getObject(java.lang.String name)
           
 CallInstance getProcessCallInstance()
           
 MoreMotionRequest getRequest()
           
 java.lang.String getStringValue(java.lang.String symbol)
          Returns the value of the given symbol as String.
 int getType(java.lang.String symbol)
          Returns the type of the given symbol.
 java.lang.String getValue(java.lang.String symbol)
          Returns the value of the given symbol as String.
 VariablePool getVPool()
           
 boolean isNull(java.lang.String symbol)
           
static void main(java.lang.String[] args)
           
 ProcessRecord peekProcessRecord()
           
 void popProcessRecord()
           
 void popTCall()
           
 void pushProcessRecord(ProcessRecord prec)
           
 void pushTCall(java.util.HashMap tcall)
           
 void putObject(java.lang.String name, java.lang.Object o)
           
 void resetAdomNodeProcessingMode()
           
 void setADOMNode(ADOMNode adomnode)
           
 void setAdomNodeProcessingMode(int value)
           
 void setDisableQSpecifier(boolean value)
           
 void setDoubleBackSlashes(boolean value)
           
 void setLogger(Logger log)
           
 void setProcessCallInstance(CallInstance ci)
           
 void setValue(java.lang.String symbol, java.lang.String value)
          Although this method takes place in this interface it will not be called by Expression class.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ADOM_NODE_PROCESSING_MODE_IGNORE

public static final int ADOM_NODE_PROCESSING_MODE_IGNORE
See Also:
Constant Field Values

ADOM_NODE_PROCESSING_MODE_FIRST

public static final int ADOM_NODE_PROCESSING_MODE_FIRST
See Also:
Constant Field Values

ADOM_NODE_PROCESSING_MODE_LAST

public static final int ADOM_NODE_PROCESSING_MODE_LAST
See Also:
Constant Field Values

bypassRIE

public boolean bypassRIE

assistant

public SymbolResolver assistant
Constructor Detail

MMSymbolResolver

public MMSymbolResolver(MoreMotionRequest request)
Creates a new instance of SymbolResolver

Method Detail

setProcessCallInstance

public void setProcessCallInstance(CallInstance ci)

getProcessCallInstance

public CallInstance getProcessCallInstance()

setLogger

public void setLogger(Logger log)

getLogger

public Logger getLogger()

setDisableQSpecifier

public void setDisableQSpecifier(boolean value)

getDisableQSpecifier

public boolean getDisableQSpecifier()

pushProcessRecord

public void pushProcessRecord(ProcessRecord prec)

popProcessRecord

public void popProcessRecord()

peekProcessRecord

public ProcessRecord peekProcessRecord()

pushTCall

public void pushTCall(java.util.HashMap tcall)
               throws ConfigParameterException
Throws:
ConfigParameterException

popTCall

public void popTCall()

setADOMNode

public void setADOMNode(ADOMNode adomnode)

getADOMNode

public ADOMNode getADOMNode()

setAdomNodeProcessingMode

public void setAdomNodeProcessingMode(int value)

resetAdomNodeProcessingMode

public void resetAdomNodeProcessingMode()

getRequest

public MoreMotionRequest getRequest()

getVPool

public VariablePool getVPool()

getBoolValue

public boolean getBoolValue(java.lang.String symbol)
                     throws EvaluationException
Description copied from interface: SymbolResolver
Returns the value of the given symbol as boolean. This method will be called when type of the symbol is boolean.

Specified by:
getBoolValue in interface SymbolResolver
Throws:
EvaluationException

getNumberValue

public double getNumberValue(java.lang.String symbol)
                      throws EvaluationException
Description copied from interface: SymbolResolver
Returns the value of the given symbol as double. This method will be called when type of the symbol is either int or double.

Specified by:
getNumberValue in interface SymbolResolver
Throws:
EvaluationException

getStringValue

public java.lang.String getStringValue(java.lang.String symbol)
                                throws EvaluationException
Description copied from interface: SymbolResolver
Returns the value of the given symbol as String. This method will be called when type of the symbol is String.

Specified by:
getStringValue in interface SymbolResolver
Throws:
EvaluationException

getType

public int getType(java.lang.String symbol)
            throws EvaluationException
Description copied from interface: SymbolResolver
Returns the type of the given symbol. The types can be DT_STRING, DT_BOOL or DT_NUMBER

Specified by:
getType in interface SymbolResolver
Throws:
EvaluationException

getValue

public java.lang.String getValue(java.lang.String symbol)
                          throws EvaluationException
Description copied from interface: SymbolResolver
Returns the value of the given symbol as String. This method will be called when type of the symbol is undefined.

Specified by:
getValue in interface SymbolResolver
Throws:
EvaluationException

isNull

public boolean isNull(java.lang.String symbol)
               throws SymbolResolvingException
Throws:
SymbolResolvingException

doubleTheQuotes

public java.lang.String doubleTheQuotes(java.lang.String source)

setValue

public void setValue(java.lang.String symbol,
                     java.lang.String value)
              throws SymbolResolvingException
Description copied from interface: SymbolResolver
Although this method takes place in this interface it will not be called by Expression class.

Specified by:
setValue in interface SymbolResolver
Throws:
SymbolResolvingException

setDoubleBackSlashes

public void setDoubleBackSlashes(boolean value)

doubleTheBackSlashes

public boolean doubleTheBackSlashes()

putObject

public void putObject(java.lang.String name,
                      java.lang.Object o)

getObject

public java.lang.Object getObject(java.lang.String name)

main

public static void main(java.lang.String[] args)
                 throws java.lang.Exception
Throws:
java.lang.Exception


Copyright © 2002-2008 MOR YAZILIM. All Rights Reserved.