SmartFrog 3.10.000

org.smartfrog.sfcore.languages.sf.functions
Class BaseOperator

java.lang.Object
  extended by org.smartfrog.sfcore.languages.sf.functions.BaseFunction
      extended by org.smartfrog.sfcore.languages.sf.functions.BaseOperator
All Implemented Interfaces:
Function
Direct Known Subclasses:
And, Concatenate, Or, Product, Sum

public abstract class BaseOperator
extends BaseFunction

Defines the baseoperator for the operator functions. The operator is assumed to be left associative (earlier attributes are "left"), and placed between all relevant attributes defined in the component description


Field Summary
 
Fields inherited from class org.smartfrog.sfcore.languages.sf.functions.BaseFunction
context, name
 
Constructor Summary
BaseOperator()
           
 
Method Summary
protected  java.lang.Object doFunction()
          Implements the functionality of base operator.
protected abstract  java.lang.Object doOperator(java.lang.Object a, java.lang.Object b)
          The method to implement the functionality of any operator.
 
Methods inherited from class org.smartfrog.sfcore.languages.sf.functions.BaseFunction
doit
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BaseOperator

public BaseOperator()
Method Detail

doOperator

protected abstract java.lang.Object doOperator(java.lang.Object a,
                                               java.lang.Object b)
                                        throws SmartFrogCompileResolutionException
The method to implement the functionality of any operator.

Parameters:
a - Object 1 for operator
b - Object 2 for operator
Returns:
an Object
Throws:
SmartFrogCompileResolutionException

doFunction

protected java.lang.Object doFunction()
                               throws SmartFrogCompileResolutionException
Implements the functionality of base operator.

Specified by:
doFunction in class BaseFunction
Returns:
the result of the function: an Object
Throws:
SmartFrogCompileResolutionException

SmartFrog CORE 3.10.000

(C) Copyright 1998-2006 Hewlett-Packard Development Company, LP