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 @@ -927,6 +927,13 @@ public IDictionary<string, object> Variables
927
927
}
928
928
}
929
929
930
+ /// <summary>
931
+ /// Is fired just before an scriptExpression is evaluate.<para/>
932
+ /// Allow to redefine the scriptExpression to evaluate or to force a result value.
933
+ /// </summary>
934
+ public event EventHandler < ExpressionEvaluationEventArg > ScriptExpressionEvaluating ;
935
+
936
+
930
937
/// <summary>
931
938
/// Is fired just before an expression is evaluate.<para/>
932
939
/// Allow to redefine the expression to evaluate or to force a result value.
@@ -1084,6 +1091,13 @@ public virtual T ScriptEvaluate<T>(string script)
1084
1091
public virtual object ScriptEvaluate ( string script )
1085
1092
{
1086
1093
inScript = true ;
1094
+
1095
+ ExpressionEvaluationEventArg expressionEvaluationEventArg = new ExpressionEvaluationEventArg ( script , this ) ;
1096
+
1097
+ ExpressionEvaluating ? . Invoke ( this , expressionEvaluationEventArg ) ;
1098
+
1099
+ script = expressionEvaluationEventArg . Expression ;
1100
+
1087
1101
try
1088
1102
{
1089
1103
bool isReturn = false ;
You can’t perform that action at this time.
0 commit comments