summaryrefslogtreecommitdiffstats
path: root/ms/controllerblueprints
diff options
context:
space:
mode:
authorOleg Mitsura <oleg.mitsura@amdocs.com>2019-08-20 14:13:59 -0400
committerOleg Mitsura <oleg.mitsura@amdocs.com>2019-08-20 14:13:59 -0400
commit6fa3015125978bac1e255293cb98a472682f28db (patch)
treefc4efba8d6b24088c3e8d29458c3c5c842191dac /ms/controllerblueprints
parent82949f958eb17f0f06a8779598e84af8f0cca558 (diff)
Update input paramtype for populatePrimitiveValues
Issue-Id: CCSDK-1614 Signed-off-by: Oleg Mitsura <oleg.mitsura@amdocs.com> Change-Id: Iecd47868b4b9971a555d6ab0c8bbac8213b6b4c8
Diffstat (limited to 'ms/controllerblueprints')
-rw-r--r--ms/controllerblueprints/modules/blueprint-core/src/main/kotlin/org/onap/ccsdk/cds/controllerblueprints/core/utils/JacksonUtils.kt8
1 files changed, 4 insertions, 4 deletions
diff --git a/ms/controllerblueprints/modules/blueprint-core/src/main/kotlin/org/onap/ccsdk/cds/controllerblueprints/core/utils/JacksonUtils.kt b/ms/controllerblueprints/modules/blueprint-core/src/main/kotlin/org/onap/ccsdk/cds/controllerblueprints/core/utils/JacksonUtils.kt
index 9e71bfef9..73dff9379 100644
--- a/ms/controllerblueprints/modules/blueprint-core/src/main/kotlin/org/onap/ccsdk/cds/controllerblueprints/core/utils/JacksonUtils.kt
+++ b/ms/controllerblueprints/modules/blueprint-core/src/main/kotlin/org/onap/ccsdk/cds/controllerblueprints/core/utils/JacksonUtils.kt
@@ -236,7 +236,7 @@ class JacksonUtils {
}
}
- fun populatePrimitiveValues(key: String, value: Any, primitiveType: String, objectNode: ObjectNode) {
+ fun populatePrimitiveValues(key: String, value: JsonNode, primitiveType: String, objectNode: ObjectNode) {
when (primitiveType.toLowerCase()) {
BluePrintConstants.DATA_TYPE_BOOLEAN,
BluePrintConstants.DATA_TYPE_INTEGER,
@@ -244,19 +244,19 @@ class JacksonUtils {
BluePrintConstants.DATA_TYPE_DOUBLE,
BluePrintConstants.DATA_TYPE_TIMESTAMP,
BluePrintConstants.DATA_TYPE_STRING ->
- objectNode.set(key, value as JsonNode)
+ objectNode.set(key, value)
else -> throw BluePrintException("populatePrimitiveValues expected only primitive values! Received: ($value)")
}
}
- fun populatePrimitiveValues(value: Any, primitiveType: String, arrayNode: ArrayNode) {
+ fun populatePrimitiveValues(value: JsonNode, primitiveType: String, arrayNode: ArrayNode) {
when (primitiveType.toLowerCase()) {
BluePrintConstants.DATA_TYPE_BOOLEAN,
BluePrintConstants.DATA_TYPE_INTEGER,
BluePrintConstants.DATA_TYPE_FLOAT,
BluePrintConstants.DATA_TYPE_DOUBLE,
BluePrintConstants.DATA_TYPE_TIMESTAMP,
- BluePrintConstants.DATA_TYPE_STRING -> arrayNode.add(value as JsonNode)
+ BluePrintConstants.DATA_TYPE_STRING -> arrayNode.add(value)
else -> throw BluePrintException("populatePrimitiveValues expected only primitive values! Received: ($value)")
}
}