You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@unomi.apache.org by sh...@apache.org on 2021/04/22 06:58:48 UTC
[unomi] branch master updated: create a method for match
calculation (#246)
This is an automated email from the ASF dual-hosted git repository.
shuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/unomi.git
The following commit(s) were added to refs/heads/master by this push:
new 679263a create a method for match calculation (#246)
679263a is described below
commit 679263a5af3b325e346035d5ccfc4e21a989f66d
Author: liatiusim <62...@users.noreply.github.com>
AuthorDate: Thu Apr 22 09:58:40 2021 +0300
create a method for match calculation (#246)
---
.../plugins/baseplugin/conditions/PropertyConditionEvaluator.java | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/plugins/baseplugin/src/main/java/org/apache/unomi/plugins/baseplugin/conditions/PropertyConditionEvaluator.java b/plugins/baseplugin/src/main/java/org/apache/unomi/plugins/baseplugin/conditions/PropertyConditionEvaluator.java
index 8b6faca..422778e 100644
--- a/plugins/baseplugin/src/main/java/org/apache/unomi/plugins/baseplugin/conditions/PropertyConditionEvaluator.java
+++ b/plugins/baseplugin/src/main/java/org/apache/unomi/plugins/baseplugin/conditions/PropertyConditionEvaluator.java
@@ -197,6 +197,12 @@ public class PropertyConditionEvaluator implements ConditionEvaluator {
actualValue = ConditionContextHelper.foldToASCII((String) actualValue);
}
+ return isMatch(op, actualValue, expectedValue, expectedValueInteger, expectedValueDouble, expectedValueDate,
+ expectedValueDateExpr, condition);
+ }
+
+ protected boolean isMatch(String op, Object actualValue, String expectedValue, Object expectedValueInteger, Object expectedValueDouble,
+ Object expectedValueDate, Object expectedValueDateExpr, Condition condition) {
if (op == null) {
return false;
} else if (actualValue == null) {