Skip to content

Commit 1c6d2fd

Browse files
author
Achim Brandt
committed
changed source formatting
1 parent 19abf30 commit 1c6d2fd

12 files changed

+607
-619
lines changed

src/main/java/com/arangodb/BaseArangoDriver.java

+341-339
Large diffs are not rendered by default.
Original file line numberDiff line numberDiff line change
@@ -1,45 +1,42 @@
11
package com.arangodb;
22

3-
import com.arangodb.entity.CollectionOptions;
43
import com.arangodb.entity.CollectionEntity;
5-
import com.arangodb.entity.CollectionKeyOption;
6-
import com.arangodb.entity.CollectionType;
4+
import com.arangodb.entity.CollectionOptions;
75
import com.arangodb.entity.CollectionsEntity;
86
import com.arangodb.impl.BaseDriverInterface;
97

108
/**
119
* Created by fbartels on 10/27/14.
1210
*/
13-
public interface InternalCollectionDriver extends BaseDriverInterface {
14-
CollectionEntity createCollection(
15-
String database,
16-
String name,
17-
CollectionOptions collectionOptions
18-
) throws ArangoException;
11+
public interface InternalCollectionDriver extends BaseDriverInterface {
12+
CollectionEntity createCollection(String database, String name, CollectionOptions collectionOptions)
13+
throws ArangoException;
1914

20-
CollectionEntity getCollection(String database, String name) throws ArangoException;
15+
CollectionEntity getCollection(String database, String name) throws ArangoException;
2116

22-
CollectionEntity getCollectionRevision(String database, String name) throws ArangoException;
17+
CollectionEntity getCollectionRevision(String database, String name) throws ArangoException;
2318

24-
CollectionEntity getCollectionProperties(String database, String name) throws ArangoException;
19+
CollectionEntity getCollectionProperties(String database, String name) throws ArangoException;
2520

26-
CollectionEntity getCollectionCount(String database, String name) throws ArangoException;
21+
CollectionEntity getCollectionCount(String database, String name) throws ArangoException;
2722

28-
CollectionEntity getCollectionFigures(String database, String name) throws ArangoException;
23+
CollectionEntity getCollectionFigures(String database, String name) throws ArangoException;
2924

30-
CollectionEntity getCollectionChecksum(String database, String name, Boolean withRevisions, Boolean withData) throws ArangoException;
25+
CollectionEntity getCollectionChecksum(String database, String name, Boolean withRevisions, Boolean withData)
26+
throws ArangoException;
3127

32-
CollectionsEntity getCollections(String database, Boolean excludeSystem) throws ArangoException;
28+
CollectionsEntity getCollections(String database, Boolean excludeSystem) throws ArangoException;
3329

34-
CollectionEntity loadCollection(String database, String name, Boolean count) throws ArangoException;
30+
CollectionEntity loadCollection(String database, String name, Boolean count) throws ArangoException;
3531

36-
CollectionEntity unloadCollection(String database, String name) throws ArangoException;
32+
CollectionEntity unloadCollection(String database, String name) throws ArangoException;
3733

38-
CollectionEntity truncateCollection(String database, String name) throws ArangoException;
34+
CollectionEntity truncateCollection(String database, String name) throws ArangoException;
3935

40-
CollectionEntity setCollectionProperties(String database, String name, Boolean newWaitForSync, Long journalSize) throws ArangoException;
36+
CollectionEntity setCollectionProperties(String database, String name, Boolean newWaitForSync, Long journalSize)
37+
throws ArangoException;
4138

42-
CollectionEntity renameCollection(String database, String name, String newName) throws ArangoException;
39+
CollectionEntity renameCollection(String database, String name, String newName) throws ArangoException;
4340

44-
CollectionEntity deleteCollection(String database, String name) throws ArangoException;
41+
CollectionEntity deleteCollection(String database, String name) throws ArangoException;
4542
}
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,17 @@
11
package com.arangodb;
22

3-
import com.arangodb.entity.JobsEntity;
43
import com.arangodb.entity.TransactionEntity;
54
import com.arangodb.entity.TransactionResultEntity;
65
import com.arangodb.impl.BaseDriverInterface;
76

8-
import java.util.List;
9-
107
/**
118
* Created by fbartels on 10/28/14.
129
*/
1310
public interface InternalTransactionDriver extends BaseDriverInterface {
1411

12+
TransactionEntity createTransaction(String action);
1513

16-
TransactionEntity createTransaction (String action);
17-
18-
19-
TransactionResultEntity executeTransaction(String database, TransactionEntity transactionEntity) throws ArangoException;
20-
14+
TransactionResultEntity executeTransaction(String database, TransactionEntity transactionEntity)
15+
throws ArangoException;
2116

2217
}

src/main/java/com/arangodb/entity/AqlFunctionsEntity.java

+16-17
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616

1717
package com.arangodb.entity;
1818

19-
import java.util.List;
2019
import java.util.Map;
2120

2221
/**
@@ -27,24 +26,24 @@
2726
*/
2827
public class AqlFunctionsEntity extends BaseEntity {
2928

30-
/**
31-
* A map containing the function name as key and the function as value
32-
*/
33-
Map<String, String> aqlFunctions;
29+
/**
30+
* A map containing the function name as key and the function as value
31+
*/
32+
Map<String, String> aqlFunctions;
3433

35-
public AqlFunctionsEntity () {
36-
}
34+
public AqlFunctionsEntity() {
35+
}
3736

38-
AqlFunctionsEntity (Map<String, String> aqlfunctions) {
39-
this.aqlFunctions = aqlfunctions;
40-
}
37+
AqlFunctionsEntity(Map<String, String> aqlfunctions) {
38+
this.aqlFunctions = aqlfunctions;
39+
}
4140

42-
public Map<String, String> getAqlFunctions() {
43-
return aqlFunctions;
44-
}
41+
public Map<String, String> getAqlFunctions() {
42+
return aqlFunctions;
43+
}
44+
45+
public int size() {
46+
return this.aqlFunctions.size();
47+
}
4548

46-
public int size() {
47-
return this.aqlFunctions.size();
48-
}
49-
5049
}

src/main/java/com/arangodb/entity/BatchResponseEntity.java

+25-29
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,6 @@
1616

1717
package com.arangodb.entity;
1818

19-
import java.io.Serializable;
20-
2119
import com.arangodb.http.HttpResponseEntity;
2220
import com.arangodb.http.InvocationObject;
2321

@@ -29,39 +27,37 @@
2927
*/
3028
public class BatchResponseEntity extends BaseEntity {
3129

32-
/**
33-
* The context of the function call, this is used to to process the server response to
34-
* an api entity.
35-
*/
36-
InvocationObject invocationObject;
37-
38-
/**
39-
* The http response of the batch part.
40-
*/
41-
public HttpResponseEntity httpResponseEntity;
42-
43-
public BatchResponseEntity(InvocationObject invocationObject) {
44-
this.invocationObject = invocationObject;
45-
this.httpResponseEntity = new HttpResponseEntity();
46-
}
30+
/**
31+
* The context of the function call, this is used to to process the server
32+
* response to an api entity.
33+
*/
34+
InvocationObject invocationObject;
4735

48-
public InvocationObject getInvocationObject() {
36+
/**
37+
* The http response of the batch part.
38+
*/
39+
public HttpResponseEntity httpResponseEntity;
4940

50-
return invocationObject;
51-
}
41+
public BatchResponseEntity(InvocationObject invocationObject) {
42+
this.invocationObject = invocationObject;
43+
this.httpResponseEntity = new HttpResponseEntity();
44+
}
5245

53-
public void setInvocationObject(InvocationObject invocationObject) {
54-
this.invocationObject = invocationObject;
55-
}
46+
public InvocationObject getInvocationObject() {
5647

48+
return invocationObject;
49+
}
5750

58-
public HttpResponseEntity getHttpResponseEntity() {
59-
return httpResponseEntity;
60-
}
51+
public void setInvocationObject(InvocationObject invocationObject) {
52+
this.invocationObject = invocationObject;
53+
}
6154

62-
public void setHttpResponseEntity(HttpResponseEntity httpResponseEntity) {
63-
this.httpResponseEntity = httpResponseEntity;
64-
}
55+
public HttpResponseEntity getHttpResponseEntity() {
56+
return httpResponseEntity;
57+
}
6558

59+
public void setHttpResponseEntity(HttpResponseEntity httpResponseEntity) {
60+
this.httpResponseEntity = httpResponseEntity;
61+
}
6662

6763
}

src/main/java/com/arangodb/entity/BatchResponseListEntity.java

+23-25
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,8 @@
1717
package com.arangodb.entity;
1818

1919
import java.util.List;
20-
import java.util.Map;
2120

2221
import com.arangodb.ArangoException;
23-
import com.arangodb.http.HttpManager;
2422

2523
/**
2624
* A representation of the complete result of a batch request.
@@ -30,28 +28,28 @@
3028
*/
3129
public class BatchResponseListEntity extends BaseEntity {
3230

33-
/**
34-
* A list of BatchResponseEntities, each one representing a single batch part of a batch request.
35-
*/
36-
List<BatchResponseEntity> batchResponseEntities;
37-
38-
public List<BatchResponseEntity> getBatchResponseEntities() {
39-
return batchResponseEntities;
40-
}
41-
42-
43-
public void setBatchResponseEntities(List<BatchResponseEntity> batchResponseEntities) {
44-
this.batchResponseEntities = batchResponseEntities;
45-
}
46-
47-
public BatchResponseEntity getResponseFromRequestId(String requestId) throws ArangoException {
48-
for (BatchResponseEntity bpe : this.batchResponseEntities) {
49-
if (bpe.getRequestId().equals(requestId)) {
50-
return bpe;
51-
}
52-
}
53-
throw new ArangoException("RequestId not found in batch.");
54-
55-
}
31+
/**
32+
* A list of BatchResponseEntities, each one representing a single batch
33+
* part of a batch request.
34+
*/
35+
List<BatchResponseEntity> batchResponseEntities;
36+
37+
public List<BatchResponseEntity> getBatchResponseEntities() {
38+
return batchResponseEntities;
39+
}
40+
41+
public void setBatchResponseEntities(List<BatchResponseEntity> batchResponseEntities) {
42+
this.batchResponseEntities = batchResponseEntities;
43+
}
44+
45+
public BatchResponseEntity getResponseFromRequestId(String requestId) throws ArangoException {
46+
for (BatchResponseEntity bpe : this.batchResponseEntities) {
47+
if (bpe.getRequestId().equals(requestId)) {
48+
return bpe;
49+
}
50+
}
51+
throw new ArangoException("RequestId not found in batch.");
52+
53+
}
5654

5755
}

src/main/java/com/arangodb/entity/DocumentsEntity.java

+17-17
Original file line numberDiff line numberDiff line change
@@ -29,21 +29,21 @@
2929
*/
3030
public class DocumentsEntity extends BaseEntity implements Iterable<String> {
3131

32-
/**
33-
* the list of document ids
34-
*/
35-
List<String> documents;
36-
37-
public Iterator<String> iterator() {
38-
return CollectionUtils.safetyIterator(documents);
39-
}
40-
41-
public List<String> getDocuments() {
42-
return documents;
43-
}
44-
45-
public void setDocuments(List<String> documents) {
46-
this.documents = documents;
47-
}
48-
32+
/**
33+
* the list of document ids
34+
*/
35+
List<String> documents;
36+
37+
public Iterator<String> iterator() {
38+
return CollectionUtils.safetyIterator(documents);
39+
}
40+
41+
public List<String> getDocuments() {
42+
return documents;
43+
}
44+
45+
public void setDocuments(List<String> documents) {
46+
this.documents = documents;
47+
}
48+
4949
}

src/main/java/com/arangodb/entity/EdgeDefinitionEntity.java

+21-23
Original file line numberDiff line numberDiff line change
@@ -2,35 +2,33 @@
22

33
import java.util.List;
44

5-
import com.google.gson.annotations.SerializedName;
6-
75
public class EdgeDefinitionEntity {
86

9-
String collection;
10-
List<String> from;
11-
List<String> to;
7+
String collection;
8+
List<String> from;
9+
List<String> to;
1210

13-
public String getCollection() {
14-
return collection;
15-
}
11+
public String getCollection() {
12+
return collection;
13+
}
1614

17-
public void setCollection(String collection) {
18-
this.collection = collection;
19-
}
15+
public void setCollection(String collection) {
16+
this.collection = collection;
17+
}
2018

21-
public List<String> getFrom() {
22-
return from;
23-
}
19+
public List<String> getFrom() {
20+
return from;
21+
}
2422

25-
public void setFrom(List<String> from) {
26-
this.from = from;
27-
}
23+
public void setFrom(List<String> from) {
24+
this.from = from;
25+
}
2826

29-
public List<String> getTo() {
30-
return to;
31-
}
27+
public List<String> getTo() {
28+
return to;
29+
}
3230

33-
public void setTo(List<String> to) {
34-
this.to = to;
35-
}
31+
public void setTo(List<String> to) {
32+
this.to = to;
33+
}
3634
}

0 commit comments

Comments
 (0)