Class DateTimeNowFunction
- java.lang.Object
-
- com.ezylang.evalex.functions.AbstractFunction
-
- com.ezylang.evalex.functions.datetime.DateTimeNowFunction
-
- All Implemented Interfaces:
FunctionIfc
public class DateTimeNowFunction extends AbstractFunction
Produces a new DATE_TIME that represents the current date and time.It is useful to calculate a value based on the current date and time. For example, if you know the start DATE_TIME of a running process, you might use the following expression to find the DURATION that represents the process age:
DT_NOW() - startDateTime- Author:
- oswaldobapvicjr
-
-
Field Summary
-
Fields inherited from class com.ezylang.evalex.functions.AbstractFunction
MINUS_ONE
-
-
Constructor Summary
Constructors Constructor Description DateTimeNowFunction()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description EvaluationValueevaluate(Expression expression, Token functionToken, EvaluationValue... parameterValues)Performs the function logic and returns an evaluation result.-
Methods inherited from class com.ezylang.evalex.functions.AbstractFunction
getFunctionParameterDefinitions, hasVarArgs, validatePreEvaluation
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.ezylang.evalex.functions.FunctionIfc
getCountOfNonVarArgParameters, isParameterLazy
-
-
-
-
Method Detail
-
evaluate
public EvaluationValue evaluate(Expression expression, Token functionToken, EvaluationValue... parameterValues)
Description copied from interface:FunctionIfcPerforms the function logic and returns an evaluation result.- Parameters:
expression- The expression, where this function is executed. Can be used to access the expression configuration.functionToken- The function token from the parsed expression.parameterValues- The parameter values.- Returns:
- The evaluation result in form of a
EvaluationValue.
-
-