Bug 5526 - Mark old services methods with @Deprecated 08/38008/8
authorJakub Toth <jatoth@cisco.com>
Fri, 22 Apr 2016 09:12:40 +0000 (11:12 +0200)
committerJakub Toth <jatoth@cisco.com>
Tue, 3 May 2016 10:55:48 +0000 (12:55 +0200)
Change-Id: I8f65897d45327d2bf257f51fc541f9fc1210cc08
Signed-off-by: Jakub Toth <jatoth@cisco.com>
restconf/sal-rest-connector/src/main/java/org/opendaylight/netconf/md/sal/rest/schema/SchemaRetrievalService.java
restconf/sal-rest-connector/src/main/java/org/opendaylight/netconf/sal/rest/api/RestconfService.java

index 3020ab08edb2d0c6150399b6774ce14960175851..52999a5cd2019ed580d3a9dce9315b0b132cbaec 100644 (file)
@@ -12,7 +12,13 @@ import javax.ws.rs.GET;
 import javax.ws.rs.Path;
 import javax.ws.rs.PathParam;
 import javax.ws.rs.Produces;
+import org.opendaylight.restconf.rest.api.services.schema.RestconfSchemaService;
 
+/**
+ * @deprecated do not use this api. It is replaced by
+ *             {@link RestconfSchemaService}
+ */
+@Deprecated
 @Beta
 public interface SchemaRetrievalService {
 
index 17731de775d582fa4c21e94c998c0acd3d43d8ed..5bb80f7d2efe92e10ec51175fb249e4e8bcebdae 100644 (file)
@@ -26,6 +26,9 @@ import org.opendaylight.netconf.sal.rest.impl.PATCH;
 import org.opendaylight.netconf.sal.restconf.impl.NormalizedNodeContext;
 import org.opendaylight.netconf.sal.restconf.impl.PATCHContext;
 import org.opendaylight.netconf.sal.restconf.impl.PATCHStatusContext;
+import org.opendaylight.restconf.rest.api.services.RestconfModulesService;
+import org.opendaylight.restconf.rest.api.services.RestconfOperationsService;
+import org.opendaylight.restconf.rest.api.services.RestconfStreamsService;
 
 /**
  * The URI hierarchy for the RESTCONF resources consists of an entry point container, 4 top-level resources, and 1
@@ -58,30 +61,55 @@ public interface RestconfService {
     @GET
     public Object getRoot();
 
+    /**
+     * @deprecated do not use this method. It is replaced by
+     *             {@link RestconfModulesService#getModules(UriInfo)}
+     */
+    @Deprecated
     @GET
     @Path("/modules")
     @Produces({ Draft02.MediaTypes.API + JSON, Draft02.MediaTypes.API + XML, MediaType.APPLICATION_JSON,
             MediaType.APPLICATION_XML, MediaType.TEXT_XML })
     public NormalizedNodeContext getModules(@Context UriInfo uriInfo);
 
+    /**
+     * @deprecated do not use this method. It is replaced by
+     *             {@link RestconfModulesService#getModules(String, UriInfo)}
+     */
+    @Deprecated
     @GET
     @Path("/modules/{identifier:.+}")
     @Produces({ Draft02.MediaTypes.API + JSON, Draft02.MediaTypes.API + XML, MediaType.APPLICATION_JSON,
             MediaType.APPLICATION_XML, MediaType.TEXT_XML })
     public NormalizedNodeContext getModules(@PathParam("identifier") String identifier, @Context UriInfo uriInfo);
 
+    /**
+     * @deprecated do not use this method. It is replaced by
+     *             {@link RestconfModulesService#getModule(String, UriInfo)}
+     */
+    @Deprecated
     @GET
     @Path("/modules/module/{identifier:.+}")
     @Produces({ Draft02.MediaTypes.API + JSON, Draft02.MediaTypes.API + XML, MediaType.APPLICATION_JSON,
             MediaType.APPLICATION_XML, MediaType.TEXT_XML })
     public NormalizedNodeContext getModule(@PathParam("identifier") String identifier, @Context UriInfo uriInfo);
 
+    /**
+     * @deprecated do not use this method. It is replaced by
+     *             {@link RestconfOperationsService#getOperations(UriInfo)}
+     */
+    @Deprecated
     @GET
     @Path("/operations")
     @Produces({ Draft02.MediaTypes.API + JSON, Draft02.MediaTypes.API + XML, MediaType.APPLICATION_JSON,
             MediaType.APPLICATION_XML, MediaType.TEXT_XML })
     public NormalizedNodeContext getOperations(@Context UriInfo uriInfo);
 
+    /**
+     * @deprecated do not use this method. It is replaced by
+     *             {@link RestconfOperationsService#getOperations(String, UriInfo)}
+     */
+    @Deprecated
     @GET
     @Path("/operations/{identifier:.+}")
     @Produces({ Draft02.MediaTypes.API + JSON, Draft02.MediaTypes.API + XML, MediaType.APPLICATION_JSON,
@@ -149,6 +177,11 @@ public interface RestconfService {
     @Path("/streams/stream/{identifier:.+}")
     public Response subscribeToStream(@Encoded @PathParam("identifier") String identifier, @Context UriInfo uriInfo);
 
+    /**
+     * @deprecated do not use this method. It is replaced by
+     *             {@link RestconfStreamsService#getAvailableStreams(UriInfo)}
+     */
+    @Deprecated
     @GET
     @Path("/streams")
     @Produces({ Draft02.MediaTypes.API + JSON, Draft02.MediaTypes.API + XML, MediaType.APPLICATION_JSON,