|
@@ -51,8 +51,10 @@ namespace FormulaEnginePoC.FormulaEngine.Internal
|
|
|
, {"<=", "<="}
|
|
|
, {">=", ">="}
|
|
|
, {"%", "%"}
|
|
|
+ , {"如果", ""}
|
|
|
, {"那么", "?"}
|
|
|
, {"否则", ":"}
|
|
|
+ , {"否则如果", ":"}
|
|
|
, {"或者", "||"}
|
|
|
, {"并且", "&&"}
|
|
|
,
|
|
@@ -68,6 +70,22 @@ namespace FormulaEnginePoC.FormulaEngine.Internal
|
|
|
, {"(文本)结尾为", ".EndsWith"}
|
|
|
, {"(文本)包含", ".Contains"}
|
|
|
};
|
|
|
+
|
|
|
+ //TODO: functions
|
|
|
+ /* ABS(expression)
|
|
|
+ * ROUND(expression)
|
|
|
+ * CEIL(expression)
|
|
|
+ * FLOOR(expression)
|
|
|
+ * TRUNCATE(expression,expression)
|
|
|
+ * MOD(expression)
|
|
|
+ * STR(expression)
|
|
|
+ * INT(expression)
|
|
|
+ * INT(expression,expression)
|
|
|
+ * AVG(ex1,ex2,ex3...)
|
|
|
+ * MAX(ex1,ex2,ex3...)
|
|
|
+ * MIN(ex1,ex2,ex3...)
|
|
|
+ * SUM(ex1,ex2,ex3...)
|
|
|
+ */
|
|
|
}
|
|
|
|
|
|
public static string Convert(string friendInput, TypeMapping mapping)
|