Class SQLFunctionMathAbstract
- java.lang.Object
-
- com.arcadedb.query.sql.function.SQLFunctionAbstract
-
- com.arcadedb.query.sql.function.SQLFunctionConfigurableAbstract
-
- com.arcadedb.query.sql.function.math.SQLFunctionMathAbstract
-
- All Implemented Interfaces:
SQLFunction
- Direct Known Subclasses:
SQLFunctionAbsoluteValue
,SQLFunctionAverage
,SQLFunctionCount
,SQLFunctionHeuristicPathFinderAbstract
,SQLFunctionMax
,SQLFunctionMin
,SQLFunctionPathFinder
,SQLFunctionShortestPath
,SQLFunctionSum
public abstract class SQLFunctionMathAbstract extends SQLFunctionConfigurableAbstract
Abstract class for math function.- Author:
- Luca Garulli (l.garulli--(at)--gmail.com)
-
-
Field Summary
-
Fields inherited from class com.arcadedb.query.sql.function.SQLFunctionConfigurableAbstract
configuredParameters
-
Fields inherited from class com.arcadedb.query.sql.function.SQLFunctionAbstract
name
-
-
Constructor Summary
Constructors Constructor Description SQLFunctionMathAbstract(String iName, int iMinParams, int iMaxParams)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
aggregateResults()
A function can make calculation on several records before returning a result.protected Class<? extends Number>
getClassWithMorePrecision(Class<? extends Number> iClass1, Class<? extends Number> iClass2)
protected Number
getContextValue(Object iContext, Class<? extends Number> iClass)
-
Methods inherited from class com.arcadedb.query.sql.function.SQLFunctionConfigurableAbstract
config, toString
-
Methods inherited from class com.arcadedb.query.sql.function.SQLFunctionAbstract
getName, getResult
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface com.arcadedb.query.sql.executor.SQLFunction
execute, getSyntax
-
-
-
-
Constructor Detail
-
SQLFunctionMathAbstract
public SQLFunctionMathAbstract(String iName, int iMinParams, int iMaxParams)
-
-
Method Detail
-
getClassWithMorePrecision
protected Class<? extends Number> getClassWithMorePrecision(Class<? extends Number> iClass1, Class<? extends Number> iClass2)
-
aggregateResults
public boolean aggregateResults()
Description copied from interface:SQLFunction
A function can make calculation on several records before returning a result.Example of such function : sum, count, max, min ...
The final result of the aggregation is obtained by calling
SQLFunction.getResult()
- Specified by:
aggregateResults
in interfaceSQLFunction
- Overrides:
aggregateResults
in classSQLFunctionAbstract
- Returns:
- true if function aggregate results
-
-