diff options
author | Pavel Aharoni <pa0916@att.com> | 2017-11-07 21:58:37 +0200 |
---|---|---|
committer | Pavel Aharoni <pa0916@att.com> | 2017-11-07 21:58:37 +0200 |
commit | a5ae1468e16834137bc8331dc1661e700f181dc8 (patch) | |
tree | eedaaf99365dc9c03d20a4db524e659283392066 /src | |
parent | ddfa0448cc31009a8fcad826440f130c2f5a1abf (diff) |
[SDC-643] Fix Constraint validation
Change-Id: I02b5b8b4516f0c190d460c067ea40bb6880dc8cf
Signed-off-by: Pavel Aharoni <pa0916@att.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/main/java/org/openecomp/sdc/toscaparser/api/elements/constraints/Constraint.java | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/main/java/org/openecomp/sdc/toscaparser/api/elements/constraints/Constraint.java b/src/main/java/org/openecomp/sdc/toscaparser/api/elements/constraints/Constraint.java index 253cc0c..5cf7444 100644 --- a/src/main/java/org/openecomp/sdc/toscaparser/api/elements/constraints/Constraint.java +++ b/src/main/java/org/openecomp/sdc/toscaparser/api/elements/constraints/Constraint.java @@ -5,6 +5,7 @@ import java.util.LinkedHashMap; import org.openecomp.sdc.toscaparser.api.common.JToscaValidationIssue; import org.openecomp.sdc.toscaparser.api.elements.ScalarUnit; +import org.openecomp.sdc.toscaparser.api.functions.Function; import org.openecomp.sdc.toscaparser.api.utils.ThreadLocalsHolder; public abstract class Constraint { @@ -141,6 +142,11 @@ public abstract class Constraint { } public void validate(Object value) { + if (Function.isFunction(value)){ + //skipping constraints check for functions + return; + } + valueMsg = value; boolean bFound = false; for(String s: ScalarUnit.SCALAR_UNIT_TYPES) { |