Response for PUT and POST operations
[controller.git] / opendaylight / md-sal / sal-rest-connector / src / main / java / org / opendaylight / controller / sal / rest / api / RestconfServiceLegacy.java
1 package org.opendaylight.controller.sal.rest.api;
2
3 import static org.opendaylight.controller.sal.restconf.impl.MediaTypes.API;
4
5 import javax.ws.rs.GET;
6 import javax.ws.rs.POST;
7 import javax.ws.rs.PUT;
8 import javax.ws.rs.Path;
9 import javax.ws.rs.PathParam;
10 import javax.ws.rs.Produces;
11 import javax.ws.rs.core.Response;
12
13 import org.opendaylight.controller.sal.restconf.impl.StructuredData;
14 import org.opendaylight.yangtools.yang.data.api.CompositeNode;
15
16 public interface RestconfServiceLegacy {
17
18     public static final String XML = "+xml";
19     public static final String JSON = "+json";
20     
21     @Deprecated
22     @GET
23     @Path("/datastore")
24     @Produces({API+JSON,API+XML})
25     public StructuredData readAllData();
26
27     @Deprecated
28     @GET
29     @Path("/datastore/{identifier:.+}")
30     @Produces({API+JSON,API+XML})
31     public StructuredData readData(@PathParam("identifier") String identifier);
32
33     @Deprecated
34     @PUT
35     @Path("/datastore/{identifier:.+}")
36     @Produces({API+JSON,API+XML})
37     public Response createConfigurationDataLegacy(@PathParam("identifier") String identifier, CompositeNode payload);
38
39     @Deprecated
40     @POST
41     @Path("/datastore/{identifier:.+}")
42     @Produces({API+JSON,API+XML})
43     public Response updateConfigurationDataLegacy(@PathParam("identifier") String identifier, CompositeNode payload);
44
45 }