Performance Improvements for Gizmo bulk API
[aai/gizmo.git] / src / test / java / org / onap / crud / dao / champ / ChampDaoTest.java
1 /**
2  * ============LICENSE_START=======================================================
3  * org.onap.aai
4  * ================================================================================
5  * Copyright © 2017-2018 AT&T Intellectual Property. All rights reserved.
6  * Copyright © 2017-2018 Amdocs
7  * ================================================================================
8  * Licensed under the Apache License, Version 2.0 (the "License");
9  * you may not use this file except in compliance with the License.
10  * You may obtain a copy of the License at
11  *
12  *       http://www.apache.org/licenses/LICENSE-2.0
13  *
14  * Unless required by applicable law or agreed to in writing, software
15  * distributed under the License is distributed on an "AS IS" BASIS,
16  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17  * See the License for the specific language governing permissions and
18  * limitations under the License.
19  * ============LICENSE_END=========================================================
20  */
21
22 package org.onap.crud.dao.champ;
23
24 import java.util.List;
25 import java.util.Map;
26 import java.util.Set;
27
28 import org.onap.aai.restclient.client.OperationResult;
29 import org.onap.crud.dao.GraphDao;
30 import org.onap.crud.entity.Edge;
31 import org.onap.crud.entity.Vertex;
32 import org.onap.crud.exception.CrudException;
33
34 public class ChampDaoTest implements GraphDao {
35
36     @Override
37     public Vertex getVertex(String id, String version) throws CrudException {
38         // TODO Auto-generated method stub
39         return null;
40     }
41
42     @Override
43     public OperationResult getVertex(String id, String type, String version, Map<String, String> queryParams)
44             throws CrudException {
45         OperationResult res = new OperationResult();
46         Vertex v = new Vertex.Builder("pserver").id("50bdab41-ad1c-4d00-952c-a0aa5d827811").property("hostname", "oldhost").build();
47         res.setResult(200, v.toJson().replace("\"id\"", "\"key\""));
48         return res;
49     }
50
51     @Override
52     public List<Edge> getVertexEdges(String id, Map<String, String> queryParams, String txId) throws CrudException {
53         // TODO Auto-generated method stub
54         return null;
55     }
56
57     @Override
58     public OperationResult getVertices(String type, Map<String, Object> filter, String version) throws CrudException {
59         // TODO Auto-generated method stub
60         return null;
61     }
62
63     @Override
64     public OperationResult getVertices(String type, Map<String, Object> filter, Set<String> properties, String version)
65             throws CrudException {
66         // TODO Auto-generated method stub
67         return null;
68     }
69
70     @Override
71     public OperationResult getEdge(String id, String type, Map<String, String> queryParams) throws CrudException {
72         // TODO Auto-generated method stub
73         return null;
74     }
75
76     @Override
77     public OperationResult getEdges(String type, Map<String, Object> filter) throws CrudException {
78         // TODO Auto-generated method stub
79         return null;
80     }
81
82     @Override
83     public OperationResult addVertex(String type, Map<String, Object> properties, String version) throws CrudException {
84         // TODO Auto-generated method stub
85         return null;
86     }
87
88     @Override
89     public OperationResult updateVertex(String id, String type, Map<String, Object> properties, String version)
90             throws CrudException {
91         // TODO Auto-generated method stub
92         return null;
93     }
94
95     @Override
96     public void deleteVertex(String id, String type) throws CrudException {
97         // TODO Auto-generated method stub
98         
99     }
100
101     @Override
102     public OperationResult addEdge(String type, Vertex source, Vertex target, Map<String, Object> properties,
103             String version) throws CrudException {
104         // TODO Auto-generated method stub
105         return null;
106     }
107
108     @Override
109     public OperationResult updateEdge(Edge edge) throws CrudException {
110         // TODO Auto-generated method stub
111         return null;
112     }
113
114     @Override
115     public void deleteEdge(String id) throws CrudException {
116         // TODO Auto-generated method stub
117         
118     }
119
120     @Override
121     public String openTransaction() {
122         // TODO Auto-generated method stub
123         return null;
124     }
125
126     @Override
127     public void commitTransaction(String id) throws CrudException {
128         // TODO Auto-generated method stub
129         
130     }
131
132     @Override
133     public void rollbackTransaction(String id) throws CrudException {
134         // TODO Auto-generated method stub
135         
136     }
137
138     @Override
139     public boolean transactionExists(String id) throws CrudException {
140         // TODO Auto-generated method stub
141         return false;
142     }
143
144     @Override
145     public Vertex addVertex(String type, Map<String, Object> properties, String version, String txId)
146             throws CrudException {
147         // TODO Auto-generated method stub
148         return null;
149     }
150
151     @Override
152     public Edge addEdge(String type, Vertex source, Vertex target, Map<String, Object> properties, String version,
153             String txId) throws CrudException {
154         // TODO Auto-generated method stub
155         return null;
156     }
157
158     @Override
159     public Vertex updateVertex(String id, String type, Map<String, Object> properties, String version, String txId)
160             throws CrudException {
161         // TODO Auto-generated method stub
162         return null;
163     }
164
165     @Override
166     public Edge updateEdge(Edge edge, String txId) throws CrudException {
167         // TODO Auto-generated method stub
168         return null;
169     }
170
171     @Override
172     public void deleteVertex(String id, String type, String txId) throws CrudException {
173         // TODO Auto-generated method stub
174         
175     }
176
177     @Override
178     public void deleteEdge(String id, String txId) throws CrudException {
179         // TODO Auto-generated method stub
180         
181     }
182
183     @Override
184     public Edge getEdge(String id, String txId) throws CrudException {
185         // TODO Auto-generated method stub
186         return null;
187     }
188
189     @Override
190     public Edge getEdge(String id) throws CrudException {
191         Edge edge = new Edge.Builder("tosca.relationships.HostedOn").id("xxx-yyy-zzz").source(new Vertex.Builder("vserver").id("50bdab41-ad1c-4d00-952c-a0aa5d827811").build())
192                 .target(new Vertex.Builder("pserver").id("1d326bc7-b985-492b-9604-0d5d1f06f908").build()).build();
193         
194         return edge;
195     }
196
197     @Override
198     public OperationResult bulkOperation(ChampBulkPayload champPayload) throws CrudException {
199         // TODO Auto-generated method stub
200         return null;
201     }
202
203 }