/src/Otis/Functions/MinFunction.cs
http://otis-lib.googlecode.com/ · C# · 21 lines · 18 code · 2 blank · 1 comment · 0 complexity · 7cf78166e81dc976a8c1fa61f15d2b1d MD5 · raw file
- using System;
- using System.Collections.Generic;
- using System.Text;
- using Otis.CodeGen;
-
- namespace Otis.Functions
- {
- public class MinFunction : MinMaxFunctionBase
- {
- protected override string GetFormatForExecutedExpression(AggregateFunctionContext context)
- {
- // todo: test
- return "if(CURR_ITEM < FN_OBJ) FN_OBJ = CURR_ITEM;";
- }
-
- protected override string GetFieldNameForInitialValue()
- {
- return "MaxValue";
- }
- }
- }