Added ETSI Delete VNF BB
[so.git] / bpmn / so-bpmn-tasks / src / main / java / org / onap / so / bpmn / infrastructure / adapter / vnfm / tasks / VnfmAdapterUrlProvider.java
index 03ee071..61063fe 100644 (file)
@@ -21,7 +21,6 @@
 package org.onap.so.bpmn.infrastructure.adapter.vnfm.tasks;
 
 import java.net.URI;
-
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 import org.springframework.web.util.UriComponentsBuilder;
@@ -36,23 +35,34 @@ import org.springframework.web.util.UriComponentsBuilder;
 @Service
 public class VnfmAdapterUrlProvider {
 
-    private final URI baseUri;
-
-    @Autowired
-    public VnfmAdapterUrlProvider(final VnfmBasicHttpConfigProvider etsiVnfmAdapter) {
-        this.baseUri = UriComponentsBuilder.fromHttpUrl(etsiVnfmAdapter.getUrl()).build().toUri();
-    }
-
-    /**
-     * Get VNFM create and instantiate URL
-     * 
-     * @param vnfId The identifier of the VNF. This must be the vnf-id of an existing generic-vnf in
-     *        AAI.
-     * @return VNFM create and instantiate URL
-     */
-    public String getCreateInstantiateUrl(final String vnfId) {
-        return UriComponentsBuilder.fromUri(baseUri).pathSegment("vnfs").pathSegment(vnfId).build().toString();
-    }
+  private final URI baseUri;
+
+  @Autowired
+  public VnfmAdapterUrlProvider(final VnfmBasicHttpConfigProvider etsiVnfmAdapter) {
+    this.baseUri = UriComponentsBuilder.fromHttpUrl(etsiVnfmAdapter.getUrl()).build().toUri();
+  }
+
+  /**
+   * Get VNFM create and instantiate URL
+   * 
+   * @param vnfId The identifier of the VNF. This must be the vnf-id of an existing generic-vnf in
+   *        AAI.
+   * @return VNFM create and instantiate URL
+   */
+  public String getCreateInstantiateUrl(final String vnfId) {
+    return UriComponentsBuilder.fromUri(baseUri).pathSegment("vnfs").pathSegment(vnfId).build().toString();
+  }
+
+  /**
+   * Get VNFM delete URL
+   * 
+   * @param vnfId The identifier of the VNF. This must be the vnf-id of an existing generic-vnf in
+   *        AAI.
+   * @return VNFM delete URL
+   */
+  public String getDeleteUrl(final String vnfId) {
+    return UriComponentsBuilder.fromUri(baseUri).pathSegment("vnfs").pathSegment(vnfId).build().toString();
+  }
 
 
 }