diff options
Diffstat (limited to 'openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/ValidationResponse.java')
-rw-r--r-- | openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/ValidationResponse.java | 44 |
1 files changed, 42 insertions, 2 deletions
diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/ValidationResponse.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/ValidationResponse.java index eb03ba62b4..ea5bef13dc 100644 --- a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/ValidationResponse.java +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/ValidationResponse.java @@ -22,10 +22,10 @@ package org.openecomp.sdc.vendorsoftwareproduct.types; import org.apache.commons.collections4.CollectionUtils; import org.apache.commons.collections4.MapUtils; -import org.openecomp.sdc.logging.api.Logger; -import org.openecomp.sdc.logging.api.LoggerFactory; import org.openecomp.sdc.common.errors.ErrorCode; import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdc.logging.api.Logger; +import org.openecomp.sdc.logging.api.LoggerFactory; import org.openecomp.sdc.logging.types.LoggerServiceName; import org.openecomp.sdc.vendorsoftwareproduct.utils.VendorSoftwareProductUtils; @@ -41,6 +41,9 @@ public class ValidationResponse { private Map<String, List<ErrorMessage>> uploadDataErrors; private Map<String, List<ErrorMessage>> compilationErrors; private QuestionnaireValidationResult questionnaireValidationResult; + private ComponentValidationResult componentValidationResult; + private DeploymentFlavorValidationResult deploymentFlavorValidationResult; + public boolean isValid() { return valid; @@ -67,6 +70,7 @@ public class ValidationResponse { VendorSoftwareProductUtils.setErrorsIntoLogger(vspErrors, serviceName, targetServiceName); } + public Collection<ErrorCode> getLicensingDataErrors() { return licensingDataErrors; } @@ -145,4 +149,40 @@ public class ValidationResponse { } + public ComponentValidationResult getComponentValidationResult() { + return componentValidationResult; + } + + /** + * Sets Component validation result. + * + * @param componentValidationResult the Component validation result + */ + public void setComponentValidationResult( + ComponentValidationResult componentValidationResult) { + this.componentValidationResult = componentValidationResult; + if (componentValidationResult != null && !componentValidationResult.isValid()) { + valid = false; + } + } + + + public DeploymentFlavorValidationResult getDeploymentFlavorValidationResult() { + return deploymentFlavorValidationResult; + } + + /** + * Sets Deployment validation result. + * + * @param deploymentFlavorValidationResult the Deployment validation result + */ + public void setDeploymentFlavorValidationResult( + DeploymentFlavorValidationResult deploymentFlavorValidationResult) { + this.deploymentFlavorValidationResult = deploymentFlavorValidationResult; + if (deploymentFlavorValidationResult != null && !deploymentFlavorValidationResult.isValid()) { + valid = false; + } + } + + } |