summaryrefslogtreecommitdiffstats
path: root/ms/controllerblueprints/modules/service/src
diff options
context:
space:
mode:
authorMuthuramalingam, Brinda Santh <brindasanth@in.ibm.com>2019-04-03 21:36:57 -0400
committerMuthuramalingam, Brinda Santh <brindasanth@in.ibm.com>2019-04-04 08:09:16 -0400
commit0007063cc856483e36dd49718dea5dda80ed6809 (patch)
treef97d43008e4f0d816a8041b02e5d986cc5f3557e /ms/controllerblueprints/modules/service/src
parenta2a21cd7a80c3ff3b754d7a4e47fc48f45ff2312 (diff)
Improve step data access.
Change-Id: I3917905b1e38cebcb26e4422784a5553e2dbac9f Issue-ID: CCSDK-1127 Signed-off-by: Muthuramalingam, Brinda Santh <brindasanth@in.ibm.com>
Diffstat (limited to 'ms/controllerblueprints/modules/service/src')
-rw-r--r--ms/controllerblueprints/modules/service/src/main/kotlin/org/onap/ccsdk/cds/controllerblueprints/service/handler/ResourceDictionaryHandler.kt11
1 files changed, 5 insertions, 6 deletions
diff --git a/ms/controllerblueprints/modules/service/src/main/kotlin/org/onap/ccsdk/cds/controllerblueprints/service/handler/ResourceDictionaryHandler.kt b/ms/controllerblueprints/modules/service/src/main/kotlin/org/onap/ccsdk/cds/controllerblueprints/service/handler/ResourceDictionaryHandler.kt
index df8cffdba..e339bcd68 100644
--- a/ms/controllerblueprints/modules/service/src/main/kotlin/org/onap/ccsdk/cds/controllerblueprints/service/handler/ResourceDictionaryHandler.kt
+++ b/ms/controllerblueprints/modules/service/src/main/kotlin/org/onap/ccsdk/cds/controllerblueprints/service/handler/ResourceDictionaryHandler.kt
@@ -21,7 +21,7 @@ import com.google.common.base.Preconditions
import org.apache.commons.collections.CollectionUtils
import org.apache.commons.lang3.StringUtils
import org.onap.ccsdk.cds.controllerblueprints.core.BluePrintException
-import org.onap.ccsdk.cds.controllerblueprints.core.checkNotEmptyOrThrow
+import org.onap.ccsdk.cds.controllerblueprints.core.checkNotEmpty
import org.onap.ccsdk.cds.controllerblueprints.resource.dict.ResourceSourceMapping
import org.onap.ccsdk.cds.controllerblueprints.resource.dict.factory.ResourceSourceMappingFactory
import org.onap.ccsdk.cds.controllerblueprints.service.domain.ResourceDictionary
@@ -137,12 +137,11 @@ class ResourceDictionaryHandler(private val resourceDictionaryRepository: Resour
}
private fun validateResourceDictionary(resourceDictionary: ResourceDictionary): Boolean {
- checkNotEmptyOrThrow(resourceDictionary.name, "DataDictionary Definition name is missing.")
+ checkNotEmpty(resourceDictionary.name){ "DataDictionary Definition name is missing."}
checkNotNull(resourceDictionary.definition) { "DataDictionary Definition Information is missing." }
- checkNotEmptyOrThrow(resourceDictionary.description, "DataDictionary Definition Information is missing.")
- checkNotEmptyOrThrow(resourceDictionary.tags, "DataDictionary Definition tags is missing.")
- checkNotEmptyOrThrow(resourceDictionary.updatedBy, "DataDictionary Definition updatedBy is missing.")
+ checkNotEmpty(resourceDictionary.description){ "DataDictionary Definition Information is missing."}
+ checkNotEmpty(resourceDictionary.tags){ "DataDictionary Definition tags is missing."}
+ checkNotEmpty(resourceDictionary.updatedBy){ "DataDictionary Definition updatedBy is missing."}
return true
-
}
} \ No newline at end of file