org.outerj.daisy.query.model.functions
Class ModFunction

java.lang.Object
  extended by org.outerj.daisy.query.model.AbstractFunction
      extended by org.outerj.daisy.query.model.functions.AbstractBinaryMathFunction
          extended by org.outerj.daisy.query.model.functions.ModFunction
All Implemented Interfaces:
Expression, Function, ValueExpr

public class ModFunction
extends AbstractBinaryMathFunction


Field Summary
static java.lang.String NAME
           
 
Fields inherited from class org.outerj.daisy.query.model.AbstractFunction
params
 
Constructor Summary
ModFunction()
           
 
Method Summary
 void generateSqlValueExpr(java.lang.StringBuffer sql, SqlGenerationContext context)
          Generates the SQL for this expression.
 java.lang.String getExpression()
          Get a textual representation of this expression, i.e.
 java.lang.String getFunctionName()
           
protected  java.lang.String getMathSymbol()
           
protected  java.lang.Object performCalculation(java.math.BigDecimal value1, java.math.BigDecimal value2)
           
 
Methods inherited from class org.outerj.daisy.query.model.functions.AbstractBinaryMathFunction
evaluate, evaluate, getOutputValue, getOutputValueType, getTitle, getValueType, prepare
 
Methods inherited from class org.outerj.daisy.query.model.AbstractFunction
addParam, bindPreConditions, bindValueExpr, canTestAppliesTo, getColumn, getLine, getLocation, getParam, getSqlPreConditions, isAclAllowed, isMultiValue, isOutputOnly, isSymbolicIdentifier, setLocation, translateSymbolic
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

NAME

public static final java.lang.String NAME
See Also:
Constant Field Values
Constructor Detail

ModFunction

public ModFunction()
Method Detail

getFunctionName

public java.lang.String getFunctionName()

performCalculation

protected java.lang.Object performCalculation(java.math.BigDecimal value1,
                                              java.math.BigDecimal value2)
Specified by:
performCalculation in class AbstractBinaryMathFunction

generateSqlValueExpr

public void generateSqlValueExpr(java.lang.StringBuffer sql,
                                 SqlGenerationContext context)
                          throws org.outerj.daisy.repository.query.QueryException
Description copied from interface: ValueExpr
Generates the SQL for this expression.

Should throw an exception if this is an output-only ValueExpr.

Specified by:
generateSqlValueExpr in interface ValueExpr
Overrides:
generateSqlValueExpr in class AbstractBinaryMathFunction
Throws:
org.outerj.daisy.repository.query.QueryException

getExpression

public java.lang.String getExpression()
Description copied from interface: ValueExpr
Get a textual representation of this expression, i.e. something that could be parsed again and give the same ValueExpr again.

Specified by:
getExpression in interface ValueExpr
Overrides:
getExpression in class AbstractBinaryMathFunction

getMathSymbol

protected java.lang.String getMathSymbol()
Specified by:
getMathSymbol in class AbstractBinaryMathFunction


Copyright © -2012 . All Rights Reserved.