/*
* Copyright © 2018-2019 AT&T Intellectual Property.
*
+ * Modifications Copyright © 2020 Bell Canada.
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
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,
fun host(host: String) = host(host.asJsonPrimitive())
fun host(host: JsonNode) = property(SshClientProperties::host.name, host)
+
+ fun logging(logging: Boolean) = logging(logging.asJsonPrimitive())
+
+ fun logging(logging: JsonNode) = property(SshClientProperties::logging.name, logging)
}
class BasicAuthSshClientPropertiesAssignmentBuilder : SshClientPropertiesAssignmentBuilder() {