summaryrefslogtreecommitdiffstats
path: root/ms/blueprintsprocessor/functions/resource-resolution/src/main
diff options
context:
space:
mode:
authorBrinda Santh <brindasanth@in.ibm.com>2019-08-01 09:12:04 -0400
committerDan Timoney <dtimoney@att.com>2019-08-01 17:24:53 +0000
commit74c548363d3dafd8ac26f0aacaa9a457ce29dfd5 (patch)
tree94fb0a1bba97f7e6f2654341209d096c619c3f6a /ms/blueprintsprocessor/functions/resource-resolution/src/main
parentdd710215139505f26f052a7dbdcdb5bf7f2e0532 (diff)
Add remote python executor DSL properties
Change-Id: I7888ac302da2a51ca34c531b7553d04af13786ac Issue-ID: CCSDK-1380 Signed-off-by: Brinda Santh <brindasanth@in.ibm.com>
Diffstat (limited to 'ms/blueprintsprocessor/functions/resource-resolution/src/main')
-rw-r--r--ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/resource/resolution/ResourceResolutionComponentDSL.kt44
1 files changed, 12 insertions, 32 deletions
diff --git a/ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/resource/resolution/ResourceResolutionComponentDSL.kt b/ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/resource/resolution/ResourceResolutionComponentDSL.kt
index c71541efd..a44750d11 100644
--- a/ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/resource/resolution/ResourceResolutionComponentDSL.kt
+++ b/ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/resource/resolution/ResourceResolutionComponentDSL.kt
@@ -94,65 +94,49 @@ class ComponentResourceResolutionNodeTemplateImplBuilder(id: String, description
class ComponentResourceResolutionInputAssignmentBuilder : PropertiesAssignmentBuilder() {
- fun requestId(requestId: String) {
- requestId(requestId.asJsonPrimitive())
- }
+ fun requestId(requestId: String) = requestId(requestId.asJsonPrimitive())
fun requestId(requestId: JsonNode) {
property(ResourceResolutionComponent.INPUT_REQUEST_ID, requestId)
}
- fun resourceId(resourceId: String) {
- resourceId(resourceId.asJsonPrimitive())
- }
+ fun resourceId(resourceId: String) = resourceId(resourceId.asJsonPrimitive())
fun resourceId(resourceId: JsonNode) {
property(ResourceResolutionComponent.INPUT_RESOURCE_ID, resourceId)
}
- fun actionName(actionName: String) {
- actionName(actionName.asJsonPrimitive())
- }
+ fun actionName(actionName: String) = actionName(actionName.asJsonPrimitive())
fun actionName(actionName: JsonNode) {
property(ResourceResolutionComponent.INPUT_ACTION_NAME, actionName)
}
- fun resolutionKey(resolutionKey: String) {
- resolutionKey(resolutionKey.asJsonPrimitive())
- }
+ fun resolutionKey(resolutionKey: String) = resolutionKey(resolutionKey.asJsonPrimitive())
fun resolutionKey(resolutionKey: JsonNode) {
property(ResourceResolutionComponent.INPUT_RESOLUTION_KEY, resolutionKey)
}
- fun dynamicProperty(dynamicProperty: String) {
- dynamicProperty(dynamicProperty.asJsonType())
- }
+ fun dynamicProperties(dynamicProperties: String) = dynamicProperties(dynamicProperties.asJsonType())
- fun dynamicProperty(dynamicProperty: JsonNode) {
- property(ResourceResolutionComponent.INPUT_DYNAMIC_PROPERTIES, dynamicProperty)
+ fun dynamicProperties(dynamicProperties: JsonNode) {
+ property(ResourceResolutionComponent.INPUT_DYNAMIC_PROPERTIES, dynamicProperties)
}
- fun occurrence(occurrence: Int) {
- occurrence(occurrence.asJsonPrimitive())
- }
+ fun occurrence(occurrence: Int) = occurrence(occurrence.asJsonPrimitive())
fun occurrence(resolutionKey: JsonNode) {
property(ResourceResolutionComponent.INPUT_OCCURRENCE, resolutionKey)
}
- fun storeResult(storeResult: Boolean) {
- storeResult(storeResult.asJsonPrimitive())
- }
+ fun storeResult(storeResult: Boolean) = storeResult(storeResult.asJsonPrimitive())
fun storeResult(storeResult: JsonNode) {
property(ResourceResolutionComponent.INPUT_STORE_RESULT, storeResult)
}
- fun resourceType(resourceType: String) {
- resourceType(resourceType.asJsonPrimitive())
- }
+ fun resourceType(resourceType: String) = resourceType(resourceType.asJsonPrimitive())
fun resourceType(resourceType: JsonNode) {
property(ResourceResolutionComponent.INPUT_RESOURCE_TYPE, resourceType)
@@ -171,17 +155,13 @@ class ComponentResourceResolutionInputAssignmentBuilder : PropertiesAssignmentBu
class ComponentResourceResolutionOutputAssignmentBuilder : PropertiesAssignmentBuilder() {
- fun status(status: String) {
- status(status.asJsonPrimitive())
- }
+ fun status(status: String) = status(status.asJsonPrimitive())
fun status(status: JsonNode) {
property(ResourceResolutionComponent.OUTPUT_STATUS, status)
}
- fun resourceAssignmentParams(resourceAssignmentParams: String) {
- resourceAssignmentParams(resourceAssignmentParams.asJsonType())
- }
+ fun resourceAssignmentParams(resourceAssignmentParams: String) = resourceAssignmentParams(resourceAssignmentParams.asJsonType())
fun resourceAssignmentParams(resourceAssignmentParams: JsonNode) {
property(ResourceResolutionComponent.OUTPUT_RESOURCE_ASSIGNMENT_PARAMS, resourceAssignmentParams)