Renaming openecomp to onap
[aai/model-loader.git] / src / main / java / org / onap / aai / modelloader / service / ModelLoaderInterface.java
1 /**\r
2  * ============LICENSE_START=======================================================\r
3  * org.onap.aai\r
4  * ================================================================================\r
5  * Copyright © 2017 AT&T Intellectual Property.\r
6  * Copyright © 2017 Amdocs\r
7  * All rights reserved.\r
8  * ================================================================================\r
9  * Licensed under the Apache License, Version 2.0 (the "License");\r
10  * you may not use this file except in compliance with the License.\r
11  * You may obtain a copy of the License at\r
12  *\r
13  *     http://www.apache.org/licenses/LICENSE-2.0\r
14  *\r
15  * Unless required by applicable law or agreed to in writing, software\r
16  * distributed under the License is distributed on an "AS IS" BASIS,\r
17  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
18  * See the License for the specific language governing permissions and\r
19  * limitations under the License.\r
20  * ============LICENSE_END=========================================================\r
21  *\r
22  * ECOMP is a trademark and service mark of AT&T Intellectual Property.\r
23  */\r
24 package org.onap.aai.modelloader.service;\r
25 \r
26 import java.io.IOException;\r
27 \r
28 import javax.servlet.http.HttpServletRequest;\r
29 import javax.ws.rs.Consumes;\r
30 import javax.ws.rs.GET;\r
31 import javax.ws.rs.POST;\r
32 import javax.ws.rs.PUT;\r
33 import javax.ws.rs.Path;\r
34 import javax.ws.rs.PathParam;\r
35 import javax.ws.rs.Produces;\r
36 import javax.ws.rs.core.Context;\r
37 import javax.ws.rs.core.Response;\r
38 \r
39 public interface ModelLoaderInterface {\r
40 \r
41   @GET\r
42   @Path("/loadModel/{modelid}")\r
43   public Response loadModel(@PathParam("modelid") String modelid);\r
44 \r
45   @PUT\r
46   @Path("/saveModel/{modelid}/{modelname}")\r
47   public Response saveModel(@PathParam("modelid") String modelid,\r
48       @PathParam("modelname") String modelname);\r
49 \r
50   @POST\r
51   @Consumes("application/xml")\r
52   @Produces("application/xml")\r
53   @Path("/ingestModel/{modelid}")\r
54   public Response ingestModel(@PathParam("modelid") String modelid, @Context HttpServletRequest req,\r
55       String payload) throws IOException;\r
56 }\r