[Boron] remove I*Aware interface
[neutron.git] / northbound-api / src / main / java / org / opendaylight / neutron / northbound / api / NeutronVPNIPSECPoliciesNorthbound.java
index b87f610056da061073566879ab492aa38e50d318..9510278c9e64a05bcfd44c5fa979415c93250f57 100644 (file)
@@ -31,7 +31,6 @@ import javax.ws.rs.core.UriInfo;
 import org.codehaus.enunciate.jaxrs.ResponseCode;
 import org.codehaus.enunciate.jaxrs.StatusCodes;
 import org.codehaus.enunciate.jaxrs.TypeHint;
-import org.opendaylight.neutron.spi.INeutronVPNIPSECPolicyAware;
 import org.opendaylight.neutron.spi.INeutronVPNIPSECPolicyCRUD;
 import org.opendaylight.neutron.spi.NeutronCRUDInterfaces;
 import org.opendaylight.neutron.spi.NeutronVPNIPSECPolicy;
@@ -56,7 +55,7 @@ import org.opendaylight.neutron.spi.NeutronVPNIPSECPolicy;
 
 @Path("/vpn/ipsecpolicies")
 public class NeutronVPNIPSECPoliciesNorthbound
-    extends AbstractNeutronNorthbound<NeutronVPNIPSECPolicy, NeutronVPNIPSECPolicyRequest, INeutronVPNIPSECPolicyCRUD, INeutronVPNIPSECPolicyAware> {
+    extends AbstractNeutronNorthbound<NeutronVPNIPSECPolicy, NeutronVPNIPSECPolicyRequest, INeutronVPNIPSECPolicyCRUD> {
 
     private static final String RESOURCE_NAME = "VPNIPSECPolicy";
 
@@ -84,47 +83,6 @@ public class NeutronVPNIPSECPoliciesNorthbound
         return new NeutronVPNIPSECPolicyRequest(o);
     }
 
-    @Override
-    protected Object[] getInstances() {
-        return NeutronUtil.getInstances(INeutronVPNIPSECPolicyAware.class, this);
-    }
-
-    @Override
-    protected int canCreate(Object instance, NeutronVPNIPSECPolicy singleton) {
-        INeutronVPNIPSECPolicyAware service = (INeutronVPNIPSECPolicyAware) instance;
-        return service.canCreateNeutronVPNIPSECPolicy(singleton);
-    }
-
-    @Override
-    protected void created(Object instance, NeutronVPNIPSECPolicy singleton) {
-        INeutronVPNIPSECPolicyAware service = (INeutronVPNIPSECPolicyAware) instance;
-        service.neutronVPNIPSECPolicyCreated(singleton);
-    }
-
-    @Override
-    protected int canUpdate(Object instance, NeutronVPNIPSECPolicy delta, NeutronVPNIPSECPolicy original) {
-        INeutronVPNIPSECPolicyAware service = (INeutronVPNIPSECPolicyAware) instance;
-        return service.canUpdateNeutronVPNIPSECPolicy(delta, original);
-    }
-
-    @Override
-    protected void updated(Object instance, NeutronVPNIPSECPolicy updated) {
-        INeutronVPNIPSECPolicyAware service = (INeutronVPNIPSECPolicyAware) instance;
-        service.neutronVPNIPSECPolicyUpdated(updated);
-    }
-
-    @Override
-    protected int canDelete(Object instance, NeutronVPNIPSECPolicy singleton) {
-        INeutronVPNIPSECPolicyAware service = (INeutronVPNIPSECPolicyAware) instance;
-        return service.canDeleteNeutronVPNIPSECPolicy(singleton);
-    }
-
-    @Override
-    protected void deleted(Object instance, NeutronVPNIPSECPolicy singleton) {
-        INeutronVPNIPSECPolicyAware service = (INeutronVPNIPSECPolicyAware) instance;
-        service.neutronVPNIPSECPolicyDeleted(singleton);
-    }
-
     @Context
     UriInfo uriInfo;
 
@@ -145,7 +103,6 @@ public class NeutronVPNIPSECPoliciesNorthbound
             @QueryParam("id") String queryID,
             @QueryParam("tenant_id") String queryTenantID,
             @QueryParam("name") String queryName,
-            @QueryParam("description") String queryDescription,
             @QueryParam("transform_protocol") String queryTransformProtocol,
             @QueryParam("encapsulation_mode") String queryEncapsulationMode,
             @QueryParam("auth_algorithm") String queryAuthAlgorithm,
@@ -161,7 +118,6 @@ public class NeutronVPNIPSECPoliciesNorthbound
             NeutronVPNIPSECPolicy oSS = i.next();
             if ((queryID == null || queryID.equals(oSS.getID())) &&
                     (queryName == null || queryName.equals(oSS.getName())) &&
-                    (queryDescription == null || queryDescription.equals(oSS.getDescription())) &&
                     (queryAuthAlgorithm == null || queryAuthAlgorithm.equals(oSS.getAuthAlgorithm())) &&
                     (queryEncryptionAlgorithm == null || queryEncryptionAlgorithm.equals(oSS.getEncryptionAlgorithm())) &&
                     (queryPFS == null || queryPFS.equals(oSS.getPerfectForwardSecrecy())) &&
@@ -222,6 +178,7 @@ public class NeutronVPNIPSECPoliciesNorthbound
     @Consumes({ MediaType.APPLICATION_JSON })
     @StatusCodes({
             @ResponseCode(code = HttpURLConnection.HTTP_OK, condition = "Operation successful"),
+            @ResponseCode(code = HttpURLConnection.HTTP_NOT_FOUND, condition = "Not Found"),
             @ResponseCode(code = HttpURLConnection.HTTP_UNAVAILABLE, condition = "No providers available") })
     public Response updateVPNIPSECPolicy(
             @PathParam("policyID") String policyUUID, final NeutronVPNIPSECPolicyRequest input
@@ -236,6 +193,7 @@ public class NeutronVPNIPSECPoliciesNorthbound
     @DELETE
     @StatusCodes({
             @ResponseCode(code = HttpURLConnection.HTTP_NO_CONTENT, condition = "No Content"),
+            @ResponseCode(code = HttpURLConnection.HTTP_NOT_FOUND, condition = "Not Found"),
             @ResponseCode(code = HttpURLConnection.HTTP_UNAVAILABLE, condition = "No providers available") })
     public Response deleteVPNIPSECPolicy(
             @PathParam("policyID") String policyUUID) {