diff options
author | Brinda Santh <brindasanth@in.ibm.com> | 2019-08-01 21:00:05 -0400 |
---|---|---|
committer | Dan Timoney <dtimoney@att.com> | 2019-08-09 20:03:06 +0000 |
commit | 2d879240396861aa253dd65b2476f35a2ffc0493 (patch) | |
tree | 8d21c269942cd4ef708f915c79dc5e3f28a90698 /ms/blueprintsprocessor/functions/resource-resolution | |
parent | f48dcc232cfd6e7c11c1155a58f6017d3a71c007 (diff) |
Add property definition type DSL.
Change-Id: I83a3d1391c60cd426236b55d0d399e273e7c15dc
Issue-ID: CCSDK-1577
Signed-off-by: Brinda Santh <brindasanth@in.ibm.com>
Diffstat (limited to 'ms/blueprintsprocessor/functions/resource-resolution')
2 files changed, 6 insertions, 6 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 a44750d11..2ca7046b3 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 @@ -20,7 +20,7 @@ import com.fasterxml.jackson.databind.JsonNode import org.onap.ccsdk.cds.controllerblueprints.core.* import org.onap.ccsdk.cds.controllerblueprints.core.data.NodeTemplate import org.onap.ccsdk.cds.controllerblueprints.core.data.NodeType -import org.onap.ccsdk.cds.controllerblueprints.core.dsl.AbstractNodeTemplateImplBuilder +import org.onap.ccsdk.cds.controllerblueprints.core.dsl.AbstractNodeTemplateOperationImplBuilder import org.onap.ccsdk.cds.controllerblueprints.core.dsl.PropertiesAssignmentBuilder import org.onap.ccsdk.cds.controllerblueprints.core.dsl.nodeType @@ -81,13 +81,13 @@ fun BluePrintTypes.nodeTypeComponentResourceResolution(): NodeType { /** Component Builder */ fun BluePrintTypes.nodeTemplateComponentResourceResolution(id: String, description: String, - block: ComponentResourceResolutionNodeTemplateImplBuilder.() -> Unit) + block: ComponentResourceResolutionNodeTemplateOperationImplBuilder.() -> Unit) : NodeTemplate { - return ComponentResourceResolutionNodeTemplateImplBuilder(id, description).apply(block).build() + return ComponentResourceResolutionNodeTemplateOperationImplBuilder(id, description).apply(block).build() } -class ComponentResourceResolutionNodeTemplateImplBuilder(id: String, description: String) : - AbstractNodeTemplateImplBuilder<ComponentResourceResolutionInputAssignmentBuilder, +class ComponentResourceResolutionNodeTemplateOperationImplBuilder(id: String, description: String) : + AbstractNodeTemplateOperationImplBuilder<PropertiesAssignmentBuilder, ComponentResourceResolutionInputAssignmentBuilder, ComponentResourceResolutionOutputAssignmentBuilder>(id, "component-script-executor", "ComponentResourceResolution", description) diff --git a/ms/blueprintsprocessor/functions/resource-resolution/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/resource/resolution/ResourceResolutionComponentDSLTest.kt b/ms/blueprintsprocessor/functions/resource-resolution/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/resource/resolution/ResourceResolutionComponentDSLTest.kt index d0566785e..671acff95 100644 --- a/ms/blueprintsprocessor/functions/resource-resolution/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/resource/resolution/ResourceResolutionComponentDSLTest.kt +++ b/ms/blueprintsprocessor/functions/resource-resolution/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/resource/resolution/ResourceResolutionComponentDSLTest.kt @@ -33,7 +33,7 @@ class ResourceResolutionComponentDSLTest { @Test fun testNodeTemplateComponentResourceResolution() { val nodeTemplate = BluePrintTypes.nodeTemplateComponentResourceResolution("resource-resolve", "") { - operation("Resolve resources") { + definedOperation("Resolve resources") { inputs { actionName("resolve") requestId("1234") |