31
31
import java .util .ArrayList ;
32
32
import java .util .Collection ;
33
33
34
+ import com .arangodb .model .*;
34
35
import org .junit .After ;
35
36
import org .junit .Before ;
36
37
import org .junit .Test ;
45
46
import com .arangodb .entity .EdgeEntity ;
46
47
import com .arangodb .entity .EdgeUpdateEntity ;
47
48
import com .arangodb .entity .VertexEntity ;
48
- import com .arangodb .model .CollectionCreateOptions ;
49
- import com .arangodb .model .DocumentReadOptions ;
50
- import com .arangodb .model .EdgeDeleteOptions ;
51
- import com .arangodb .model .EdgeReplaceOptions ;
52
- import com .arangodb .model .EdgeUpdateOptions ;
53
49
54
50
/**
55
51
* @author Mark Vollmary
@@ -148,7 +144,7 @@ public void getEdge() {
148
144
public void getEdgeIfMatch () {
149
145
final BaseEdgeDocument value = createEdgeValue ();
150
146
final EdgeEntity edge = db .graph (GRAPH_NAME ).edgeCollection (EDGE_COLLECTION_NAME ).insertEdge (value , null );
151
- final DocumentReadOptions options = new DocumentReadOptions ().ifMatch (edge .getRev ());
147
+ final GraphDocumentReadOptions options = new GraphDocumentReadOptions ().ifMatch (edge .getRev ());
152
148
final BaseDocument document = db .graph (GRAPH_NAME ).edgeCollection (EDGE_COLLECTION_NAME ).getEdge (edge .getKey (),
153
149
BaseDocument .class , options );
154
150
assertThat (document , is (notNullValue ()));
@@ -159,7 +155,7 @@ public void getEdgeIfMatch() {
159
155
public void getEdgeIfMatchFail () {
160
156
final BaseEdgeDocument value = createEdgeValue ();
161
157
final EdgeEntity edge = db .graph (GRAPH_NAME ).edgeCollection (EDGE_COLLECTION_NAME ).insertEdge (value , null );
162
- final DocumentReadOptions options = new DocumentReadOptions ().ifMatch ("no" );
158
+ final GraphDocumentReadOptions options = new GraphDocumentReadOptions ().ifMatch ("no" );
163
159
final BaseEdgeDocument edge2 = db .graph (GRAPH_NAME ).edgeCollection (EDGE_COLLECTION_NAME ).getEdge (edge .getKey (),
164
160
BaseEdgeDocument .class , options );
165
161
assertThat (edge2 , is (nullValue ()));
@@ -169,7 +165,7 @@ public void getEdgeIfMatchFail() {
169
165
public void getEdgeIfNoneMatch () {
170
166
final BaseEdgeDocument value = createEdgeValue ();
171
167
final EdgeEntity edge = db .graph (GRAPH_NAME ).edgeCollection (EDGE_COLLECTION_NAME ).insertEdge (value , null );
172
- final DocumentReadOptions options = new DocumentReadOptions ().ifNoneMatch ("no" );
168
+ final GraphDocumentReadOptions options = new GraphDocumentReadOptions ().ifNoneMatch ("no" );
173
169
final BaseDocument document = db .graph (GRAPH_NAME ).edgeCollection (EDGE_COLLECTION_NAME ).getEdge (edge .getKey (),
174
170
BaseDocument .class , options );
175
171
assertThat (document , is (notNullValue ()));
@@ -180,7 +176,7 @@ public void getEdgeIfNoneMatch() {
180
176
public void getEdgeIfNoneMatchFail () {
181
177
final BaseEdgeDocument value = createEdgeValue ();
182
178
final EdgeEntity edge = db .graph (GRAPH_NAME ).edgeCollection (EDGE_COLLECTION_NAME ).insertEdge (value , null );
183
- final DocumentReadOptions options = new DocumentReadOptions ().ifNoneMatch (edge .getRev ());
179
+ final GraphDocumentReadOptions options = new GraphDocumentReadOptions ().ifNoneMatch (edge .getRev ());
184
180
final BaseEdgeDocument edge2 = db .graph (GRAPH_NAME ).edgeCollection (EDGE_COLLECTION_NAME ).getEdge (edge .getKey (),
185
181
BaseEdgeDocument .class , options );
186
182
assertThat (edge2 , is (nullValue ()));
0 commit comments