File tree Expand file tree Collapse file tree 1 file changed +14
-0
lines changed
CodingSeb.ExpressionEvaluator Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -928,6 +928,13 @@ public IDictionary<string, object> Variables
928
928
}
929
929
}
930
930
931
+ /// <summary>
932
+ /// Is fired just before an scriptExpression is evaluate.<para/>
933
+ /// Allow to redefine the scriptExpression to evaluate or to force a result value.
934
+ /// </summary>
935
+ public event EventHandler < ExpressionEvaluationEventArg > ScriptExpressionEvaluating ;
936
+
937
+
931
938
/// <summary>
932
939
/// Is fired just before an expression is evaluate.<para/>
933
940
/// Allow to redefine the expression to evaluate or to force a result value.
@@ -1085,6 +1092,13 @@ public virtual T ScriptEvaluate<T>(string script)
1085
1092
public virtual object ScriptEvaluate ( string script )
1086
1093
{
1087
1094
inScript = true ;
1095
+
1096
+ ExpressionEvaluationEventArg expressionEvaluationEventArg = new ExpressionEvaluationEventArg ( script , this ) ;
1097
+
1098
+ ExpressionEvaluating ? . Invoke ( this , expressionEvaluationEventArg ) ;
1099
+
1100
+ script = expressionEvaluationEventArg . Expression ;
1101
+
1088
1102
try
1089
1103
{
1090
1104
bool isReturn = false ;
You can’t perform that action at this time.
0 commit comments