diff options
author | 2019-12-31 10:53:59 -0500 | |
---|---|---|
committer | 2019-12-31 10:53:59 -0500 | |
commit | ba75d2fad2b0111a510f4ee4cc87e658fb32ac4b (patch) | |
tree | 92c50b5bea79bb6c424aab6b0ac2e805a9e36e07 /ms/blueprintsprocessor/modules/commons/ssh-lib/src/main | |
parent | 1fdaf4953daf15970afe6ee10491dfa2d0a76753 (diff) |
Flexible DSL Types and Templates definition.
Easy search definitions Types and Templates inside ServiceTemplate DSL builder.
Unit test modifications to support this change.
Issue-ID: CCSDK-1054
Signed-off-by: Brinda Santh <bs2796@att.com>
Change-Id: Ie944ff5f75f80c852555306e1a4e0fa7f5b803d7
Diffstat (limited to 'ms/blueprintsprocessor/modules/commons/ssh-lib/src/main')
-rw-r--r-- | ms/blueprintsprocessor/modules/commons/ssh-lib/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/ssh/SshPropertiesDSL.kt | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/ms/blueprintsprocessor/modules/commons/ssh-lib/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/ssh/SshPropertiesDSL.kt b/ms/blueprintsprocessor/modules/commons/ssh-lib/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/ssh/SshPropertiesDSL.kt index e63f2eb49..ee7a7dead 100644 --- a/ms/blueprintsprocessor/modules/commons/ssh-lib/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/ssh/SshPropertiesDSL.kt +++ b/ms/blueprintsprocessor/modules/commons/ssh-lib/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/ssh/SshPropertiesDSL.kt @@ -24,10 +24,17 @@ import org.onap.ccsdk.cds.controllerblueprints.core.asJsonType import org.onap.ccsdk.cds.controllerblueprints.core.data.RelationshipType import org.onap.ccsdk.cds.controllerblueprints.core.dsl.PropertiesAssignmentBuilder import org.onap.ccsdk.cds.controllerblueprints.core.dsl.RelationshipTemplateBuilder +import org.onap.ccsdk.cds.controllerblueprints.core.dsl.ServiceTemplateBuilder import org.onap.ccsdk.cds.controllerblueprints.core.dsl.TopologyTemplateBuilder import org.onap.ccsdk.cds.controllerblueprints.core.dsl.relationshipType /** Relationships Types DSL for Message Producer */ +fun ServiceTemplateBuilder.relationshipTypeConnectsToSshClient() { + val relationshipType = BluePrintTypes.relationshipTypeConnectsToSshClient() + if (this.relationshipTypes == null) this.relationshipTypes = hashMapOf() + this.relationshipTypes!![relationshipType.id!!] = relationshipType +} + fun BluePrintTypes.relationshipTypeConnectsToSshClient(): RelationshipType { return relationshipType( id = BluePrintConstants.MODEL_TYPE_RELATIONSHIPS_CONNECTS_TO_SSH_CLIENT, |