Skip to content

Commit a93fe6a

Browse files
committed
JavaDoc errors stop the build for me on java 1.8.0_71-b15
1 parent f3ede8b commit a93fe6a

3 files changed

Lines changed: 32 additions & 31 deletions

File tree

src/main/java/graphql/analysis/QueryReducer.java

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,10 @@
44

55
/**
66
* Used by {@link QueryTraversal} to reduce the fields of a Document (or part of it) to a single value.
7-
* <p/>
7+
* <p>
88
* How this happens in detail (pre vs post-order for example) is defined by {@link QueryTraversal}.
9-
* <p/>
9+
* <p>
1010
* See {@link QueryTraversal#reducePostOrder(QueryReducer, Object)} and {@link QueryTraversal#reducePreOrder(QueryReducer, Object)}
11-
*
12-
* @param <T>
1311
*/
1412
@PublicApi
1513
@FunctionalInterface
@@ -18,7 +16,7 @@ public interface QueryReducer<T> {
1816
/**
1917
* Called each time a field is visited.
2018
*
21-
* @param fieldEnvironment
19+
* @param fieldEnvironment the environment to this call
2220
* @param acc the previous result
2321
*
2422
* @return the new result

src/main/java/graphql/analysis/QueryTraversal.java

Lines changed: 27 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -38,10 +38,10 @@
3838

3939
/**
4040
* Helps to traverse (or reduce) a Document (or parts of it) and tracks at the same time the corresponding Schema types.
41-
* <p/>
41+
* <p>
4242
* This is an important distinction to just traversing the Document without any type information: Each field has a clearly
4343
* defined type. See {@link QueryVisitorFieldEnvironment}.
44-
* <p/>
44+
* <p>
4545
* Further are the built in Directives skip/include automatically evaluated: if parts of the Document should be ignored they will not
4646
* be visited. But this is not a full evaluation of a Query: every fragment will be visited/followed regardless of the type condition.
4747
*/
@@ -90,7 +90,7 @@ private QueryTraversal(GraphQLSchema schema,
9090
/**
9191
* Visits the Document (or parts of it) in post-order.
9292
*
93-
* @param visitor
93+
* @param visitor the query visitor that will be called back
9494
*/
9595
public void visitPostOrder(QueryVisitor visitor) {
9696
visitImpl(visitor, false);
@@ -99,7 +99,7 @@ public void visitPostOrder(QueryVisitor visitor) {
9999
/**
100100
* Visits the Document (or parts of it) in pre-order.
101101
*
102-
* @param visitor
102+
* @param visitor the query visitor that will be called back
103103
*/
104104
public void visitPreOrder(QueryVisitor visitor) {
105105
visitImpl(visitor, true);
@@ -108,9 +108,9 @@ public void visitPreOrder(QueryVisitor visitor) {
108108
/**
109109
* Reduces the fields of a Document (or parts of it) to a single value. The fields are visited in post-order.
110110
*
111-
* @param queryReducer
112-
* @param initialValue
113-
* @param <T>
111+
* @param queryReducer the query reducer
112+
* @param initialValue the initial value to pass to the reducer
113+
* @param <T> the type of reduced value
114114
*
115115
* @return the calculated overall value
116116
*/
@@ -130,9 +130,9 @@ public void visitField(QueryVisitorFieldEnvironment env) {
130130
/**
131131
* Reduces the fields of a Document (or parts of it) to a single value. The fields are visited in pre-order.
132132
*
133-
* @param queryReducer
134-
* @param initialValue
135-
* @param <T>
133+
* @param queryReducer the query reducer
134+
* @param initialValue the initial value to pass to the reducer
135+
* @param <T> the type of reduced value
136136
*
137137
* @return the calucalated overall value
138138
*/
@@ -299,9 +299,9 @@ public static class Builder {
299299
/**
300300
* The schema used to identify the types of the query.
301301
*
302-
* @param schema
302+
* @param schema the schema to use
303303
*
304-
* @return
304+
* @return this builder
305305
*/
306306
public Builder schema(GraphQLSchema schema) {
307307
this.schema = schema;
@@ -312,9 +312,9 @@ public Builder schema(GraphQLSchema schema) {
312312
* specify the operation if a document is traversed and there
313313
* are more than one operation.
314314
*
315-
* @param operationName
315+
* @param operationName the operation name to use
316316
*
317-
* @return
317+
* @return this builder
318318
*/
319319
public Builder operationName(String operationName) {
320320
this.operation = operationName;
@@ -325,9 +325,9 @@ public Builder operationName(String operationName) {
325325
* document to be used to traverse the whole query.
326326
* If set a {@link Builder#operationName(String)} might be required.
327327
*
328-
* @param document
328+
* @param document the document to use
329329
*
330-
* @return
330+
* @return this builder
331331
*/
332332
public Builder document(Document document) {
333333
this.document = document;
@@ -337,9 +337,9 @@ public Builder document(Document document) {
337337
/**
338338
* Variables used in the query.
339339
*
340-
* @param variables
340+
* @param variables the variables to use
341341
*
342-
* @return
342+
* @return this builder
343343
*/
344344
public Builder variables(Map<String, Object> variables) {
345345
this.variables = variables;
@@ -350,9 +350,9 @@ public Builder variables(Map<String, Object> variables) {
350350
* Specify the root node for the traversal. Needs to be provided if there is
351351
* no {@link Builder#document(Document)}.
352352
*
353-
* @param root
353+
* @param root the root node to use
354354
*
355-
* @return
355+
* @return this builder
356356
*/
357357
public Builder root(Node root) {
358358
this.root = root;
@@ -362,9 +362,9 @@ public Builder root(Node root) {
362362
/**
363363
* The type of the parent of the root node. (See {@link Builder#root(Node)}
364364
*
365-
* @param rootParentType
365+
* @param rootParentType the root parent type
366366
*
367-
* @return
367+
* @return this builder
368368
*/
369369
public Builder rootParentType(GraphQLObjectType rootParentType) {
370370
this.rootParentType = rootParentType;
@@ -374,15 +374,18 @@ public Builder rootParentType(GraphQLObjectType rootParentType) {
374374
/**
375375
* Fragment by name map. Needs to be provided together with a {@link Builder#root(Node)} and {@link Builder#rootParentType(GraphQLObjectType)}
376376
*
377-
* @param fragmentsByName
377+
* @param fragmentsByName the map of fragments
378378
*
379-
* @return
379+
* @return this builder
380380
*/
381381
public Builder fragmentsByName(Map<String, FragmentDefinition> fragmentsByName) {
382382
this.fragmentsByName = fragmentsByName;
383383
return this;
384384
}
385385

386+
/**
387+
* @return a built {@link graphql.analysis.QueryTraversal} object
388+
*/
386389
public QueryTraversal build() {
387390
checkState();
388391
if (document != null) {

src/main/java/graphql/analysis/QueryVisitor.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
import graphql.PublicApi;
44

55
/**
6-
* User by {@link QueryTraversal} to visit the nodes of a Query.
7-
* <p/>
6+
* Used by {@link QueryTraversal} to visit the nodes of a Query.
7+
* <p>
88
* How this happens in detail (pre vs post-order for example) is defined by {@link QueryTraversal}.
99
*/
1010
@PublicApi

0 commit comments

Comments
 (0)