Class SQLFunctionMultiValueAbstract<T>
- java.lang.Object
-
- com.arcadedb.query.sql.function.SQLFunctionAbstract
-
- com.arcadedb.query.sql.function.SQLFunctionConfigurableAbstract
-
- com.arcadedb.query.sql.function.coll.SQLFunctionMultiValueAbstract<T>
-
- All Implemented Interfaces:
SQLFunction
- Direct Known Subclasses:
SQLFunctionDifference
,SQLFunctionIntersect
,SQLFunctionList
,SQLFunctionMap
,SQLFunctionSet
,SQLFunctionSymmetricDifference
,SQLFunctionUnionAll
public abstract class SQLFunctionMultiValueAbstract<T> extends SQLFunctionConfigurableAbstract
Abstract class for multi-value based function implementations.- Author:
- Luca Garulli (l.garulli--(at)--gmail.com)
-
-
Field Summary
Fields Modifier and Type Field Description protected T
context
-
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 SQLFunctionMultiValueAbstract(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.T
getResult()
Only called when function aggregates results after all records have been passed to the function.-
Methods inherited from class com.arcadedb.query.sql.function.SQLFunctionConfigurableAbstract
config, toString
-
Methods inherited from class com.arcadedb.query.sql.function.SQLFunctionAbstract
getName
-
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
-
-
-
-
Field Detail
-
context
protected T context
-
-
Constructor Detail
-
SQLFunctionMultiValueAbstract
public SQLFunctionMultiValueAbstract(String iName, int iMinParams, int iMaxParams)
-
-
Method Detail
-
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
-
getResult
public T getResult()
Description copied from interface:SQLFunction
Only called when function aggregates results after all records have been passed to the function.- Specified by:
getResult
in interfaceSQLFunction
- Overrides:
getResult
in classSQLFunctionAbstract
- Returns:
- Aggregation result
-
-