Renaming Files having BluePrint to have Blueprint
[ccsdk/cds.git] / ms / blueprintsprocessor / modules / commons / grpc-lib / src / main / kotlin / org / onap / ccsdk / cds / blueprintsprocessor / grpc / service / BlueprintGrpcLibPropertyService.kt
@@ -18,7 +18,7 @@
 package org.onap.ccsdk.cds.blueprintsprocessor.grpc.service
 
 import com.fasterxml.jackson.databind.JsonNode
-import org.onap.ccsdk.cds.blueprintsprocessor.core.BluePrintPropertiesService
+import org.onap.ccsdk.cds.blueprintsprocessor.core.BlueprintPropertiesService
 import org.onap.ccsdk.cds.blueprintsprocessor.grpc.BasicAuthGrpcClientProperties
 import org.onap.ccsdk.cds.blueprintsprocessor.grpc.GRPCLibConstants
 import org.onap.ccsdk.cds.blueprintsprocessor.grpc.GrpcClientProperties
@@ -27,20 +27,20 @@ import org.onap.ccsdk.cds.blueprintsprocessor.grpc.TLSAuthGrpcClientProperties
 import org.onap.ccsdk.cds.blueprintsprocessor.grpc.TLSAuthGrpcServerProperties
 import org.onap.ccsdk.cds.blueprintsprocessor.grpc.TokenAuthGrpcClientProperties
 import org.onap.ccsdk.cds.blueprintsprocessor.grpc.TokenAuthGrpcServerProperties
-import org.onap.ccsdk.cds.controllerblueprints.core.BluePrintProcessorException
+import org.onap.ccsdk.cds.controllerblueprints.core.BlueprintProcessorException
 import org.onap.ccsdk.cds.controllerblueprints.core.returnNullIfMissing
 import org.onap.ccsdk.cds.controllerblueprints.core.utils.JacksonUtils
 import org.springframework.stereotype.Service
 
 @Service(GRPCLibConstants.SERVICE_BLUEPRINT_GRPC_LIB_PROPERTY)
-open class BluePrintGrpcLibPropertyService(private var bluePrintPropertiesService: BluePrintPropertiesService) {
+open class BlueprintGrpcLibPropertyService(private var bluePrintPropertiesService: BlueprintPropertiesService) {
 
-    fun blueprintGrpcServerService(jsonNode: JsonNode): BluePrintGrpcServerService {
+    fun blueprintGrpcServerService(jsonNode: JsonNode): BlueprintGrpcServerService {
         val grpcServerProperties = grpcServerProperties(jsonNode)
         return blueprintGrpcServerService(grpcServerProperties)
     }
 
-    fun blueprintGrpcServerService(selector: String): BluePrintGrpcServerService {
+    fun blueprintGrpcServerService(selector: String): BlueprintGrpcServerService {
         val prefix = "${GRPCLibConstants.PROPERTY_GRPC_SERVER_PREFIX}$selector"
         val grpcServerProperties = grpcServerProperties(prefix)
         return blueprintGrpcServerService(grpcServerProperties)
@@ -56,7 +56,7 @@ open class BluePrintGrpcLibPropertyService(private var bluePrintPropertiesServic
                 JacksonUtils.readValue(jsonNode, TLSAuthGrpcServerProperties::class.java)!!
             }
             else -> {
-                throw BluePrintProcessorException("Grpc type($type) not supported")
+                throw BlueprintProcessorException("Grpc type($type) not supported")
             }
         }
     }
@@ -73,7 +73,7 @@ open class BluePrintGrpcLibPropertyService(private var bluePrintPropertiesServic
                 tlsAuthGrpcServerProperties(prefix)
             }
             else -> {
-                throw BluePrintProcessorException("Grpc type($type) not supported")
+                throw BlueprintProcessorException("Grpc type($type) not supported")
             }
         }
     }
@@ -87,25 +87,25 @@ open class BluePrintGrpcLibPropertyService(private var bluePrintPropertiesServic
     }
 
     private fun blueprintGrpcServerService(grpcServerProperties: GrpcServerProperties):
-        BluePrintGrpcServerService {
+        BlueprintGrpcServerService {
             when (grpcServerProperties) {
                 is TLSAuthGrpcServerProperties -> {
                     return TLSAuthGrpcServerService(grpcServerProperties)
                 }
                 else -> {
-                    throw BluePrintProcessorException("couldn't get grpc client service for properties $grpcServerProperties")
+                    throw BlueprintProcessorException("couldn't get grpc client service for properties $grpcServerProperties")
                 }
             }
         }
 
     /** GRPC Client Lib Property Service */
 
-    fun blueprintGrpcClientService(jsonNode: JsonNode): BluePrintGrpcClientService {
+    fun blueprintGrpcClientService(jsonNode: JsonNode): BlueprintGrpcClientService {
         val restClientProperties = grpcClientProperties(jsonNode)
         return blueprintGrpcClientService(restClientProperties)
     }
 
-    fun blueprintGrpcClientService(selector: String): BluePrintGrpcClientService {
+    fun blueprintGrpcClientService(selector: String): BlueprintGrpcClientService {
         val prefix = "${GRPCLibConstants.PROPERTY_GRPC_CLIENT_PREFIX}$selector"
         val restClientProperties = grpcClientProperties(prefix)
         return blueprintGrpcClientService(restClientProperties)
@@ -113,7 +113,7 @@ open class BluePrintGrpcLibPropertyService(private var bluePrintPropertiesServic
 
     fun grpcClientProperties(jsonNode: JsonNode): GrpcClientProperties {
         val type = jsonNode.get("type").returnNullIfMissing()?.textValue()
-            ?: BluePrintProcessorException("missing type property")
+            ?: BlueprintProcessorException("missing type property")
         return when (type) {
             GRPCLibConstants.TYPE_TOKEN_AUTH -> {
                 JacksonUtils.readValue(jsonNode, TokenAuthGrpcClientProperties::class.java)!!
@@ -125,7 +125,7 @@ open class BluePrintGrpcLibPropertyService(private var bluePrintPropertiesServic
                 JacksonUtils.readValue(jsonNode, BasicAuthGrpcClientProperties::class.java)!!
             }
             else -> {
-                throw BluePrintProcessorException("Grpc type($type) not supported")
+                throw BlueprintProcessorException("Grpc type($type) not supported")
             }
         }
     }
@@ -145,13 +145,13 @@ open class BluePrintGrpcLibPropertyService(private var bluePrintPropertiesServic
                 basicAuthGrpcClientProperties(prefix)
             }
             else -> {
-                throw BluePrintProcessorException("Grpc type($type) not supported")
+                throw BlueprintProcessorException("Grpc type($type) not supported")
             }
         }
     }
 
     fun blueprintGrpcClientService(grpcClientProperties: GrpcClientProperties):
-        BluePrintGrpcClientService {
+        BlueprintGrpcClientService {
             return when (grpcClientProperties) {
                 is TokenAuthGrpcClientProperties -> {
                     TokenAuthGrpcClientService(grpcClientProperties)
@@ -163,7 +163,7 @@ open class BluePrintGrpcLibPropertyService(private var bluePrintPropertiesServic
                     BasicAuthGrpcClientService(grpcClientProperties)
                 }
                 else -> {
-                    throw BluePrintProcessorException("couldn't get grpc service for type(${grpcClientProperties.type})")
+                    throw BlueprintProcessorException("couldn't get grpc service for type(${grpcClientProperties.type})")
                 }
             }
         }