Skip to content

Commit 5803af9

Browse files
committed
Javadoc fixes for java 8 errors and warnings. Excluding antlr generated files
1 parent 66b70e6 commit 5803af9

File tree

7 files changed

+45
-31
lines changed

7 files changed

+45
-31
lines changed

build.gradle

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,12 +46,16 @@ task javadocJar(type: Jar, dependsOn: javadoc) {
4646
from javadoc.destinationDir
4747
}
4848

49-
5049
artifacts {
5150
archives sourcesJar
5251
archives javadocJar
5352
}
5453

54+
allprojects {
55+
tasks.withType(Javadoc) {
56+
exclude('**/antlr/**')
57+
}
58+
}
5559

5660
publishing {
5761
publications {

src/main/java/graphql/execution/ExecutorServiceExecutionStrategy.java

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,17 +15,17 @@
1515
import java.util.concurrent.Future;
1616

1717
/**
18-
* ExecutorServiceExecutionStrategy uses an {@link ExecutorService} to parallelize the resolve.
19-
* <p/>
18+
* <p>ExecutorServiceExecutionStrategy uses an {@link ExecutorService} to parallelize the resolve.</p>
19+
*
2020
* Due to the nature of {@link #execute(ExecutionContext, GraphQLObjectType, Object, Map)} implementation, {@link ExecutorService}
2121
* MUST have the following 2 characteristics:
2222
* <ul>
2323
* <li>1. The underlying {@link java.util.concurrent.ThreadPoolExecutor} MUST have a reasonable {@code maximumPoolSize}
2424
* <li>2. The underlying {@link java.util.concurrent.ThreadPoolExecutor} SHALL NOT use its task queue.
25-
* </ul><p>
26-
* <p/>
27-
* Failure to follow 1. and 2. can result in a very large number of threads created or hanging. (deadlock)
28-
* <p/>
25+
* </ul>
26+
*
27+
* <p>Failure to follow 1. and 2. can result in a very large number of threads created or hanging. (deadlock)</p>
28+
*
2929
* See {@code graphql.execution.ExecutorServiceExecutionStrategyTest} for example usage.
3030
*/
3131
public class ExecutorServiceExecutionStrategy extends ExecutionStrategy {

src/main/java/graphql/execution/batched/Batched.java

Lines changed: 13 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -14,44 +14,40 @@
1414
* This annotation must be used in conjunction with {@link BatchedExecutionStrategy}. Batching is valuable in many
1515
* situations, such as when a {@link graphql.schema.DataFetcher} must make a network or file system request.
1616
* </p>
17-
* <p/>
1817
* <p>
1918
* When a {@link graphql.schema.DataFetcher} is batched, the {@link DataFetchingEnvironment#getSource()} method is
2019
* guaranteed to return a {@link java.util.List}. The {@link graphql.schema.DataFetcher#get(DataFetchingEnvironment)}
2120
* method MUST return a parallel {@link java.util.List} which is equivalent to running a {@link graphql.schema.DataFetcher}
2221
* over each input element individually.
2322
* </p>
24-
* <p/>
2523
* <p>
2624
* Using the {@link Batched} annotation is equivalent to implementing {@link BatchedDataFetcher} instead of {@link graphql.schema.DataFetcher}.
2725
* It is preferred to use the {@link Batched} annotation.
2826
* </p>
29-
* <p/>
3027
* For example, the following two {@link graphql.schema.DataFetcher} objects are interchangeable if used with a
3128
* {@link BatchedExecutionStrategy}.
3229
* <pre>
3330
* <code>
3431
* new DataFetcher() {
35-
* {@literal @}Override
36-
* {@literal @}Batched
37-
* public Object get(DataFetchingEnvironment environment) {
38-
* {@code List<String> retVal = new ArrayList<>();}
39-
* {@code for (String s: (List<String>) environment.getSource())} {
40-
* retVal.add(s + environment.getArgument("text"));
41-
* }
42-
* return retVal;
43-
* }
32+
* {@literal @}Override
33+
* {@literal @}Batched
34+
* public Object get(DataFetchingEnvironment environment) {
35+
* {@literal List<String> retVal = new ArrayList<>();}
36+
* {@literal for (String s: (List<String>) environment.getSource()) {}
37+
* retVal.add(s + environment.getArgument("text"));
38+
* }
39+
* return retVal;
40+
* }
4441
* }
4542
* </code>
4643
* </pre>
47-
* <p/>
4844
* <pre>
4945
* <code>
5046
* new DataFetcher() {
51-
* {@literal @}Override
52-
* public Object get(DataFetchingEnvironment e) {
53-
* return ((String)e.getSource()) + e.getArgument("text");
54-
* }
47+
* {@literal @}Override
48+
* public Object get(DataFetchingEnvironment e) {
49+
* return ((String)e.getSource()) + e.getArgument("text");
50+
* }
5551
* }
5652
* </code>
5753
* </pre>

src/main/java/graphql/execution/batched/GraphQLExecutionResultContainer.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,9 @@ public abstract class GraphQLExecutionResultContainer {
99

1010
/**
1111
* Creates a child datum which is linked through the results container to this parent.
12+
* @param fieldName fieldName
13+
* @param value value
14+
* @return datum
1215
*/
1316
public GraphQLExecutionNodeDatum createAndPutChildDatum(String fieldName, Object value) {
1417
Map<String, Object> map = new HashMap<String, Object>();
@@ -24,6 +27,8 @@ public GraphQLExecutionResultList createAndPutEmptyChildList(String fieldName) {
2427

2528
/**
2629
* Inserts this result into the parent for the specified field.
30+
* @param fieldName fieldName
31+
* @param value value
2732
*/
2833
abstract void putResult(String fieldName, Object value);
2934

src/main/java/graphql/language/Node.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ public interface Node {
1212
/**
1313
* Compares just the content and not the children.
1414
*
15-
* @param node
16-
* @return
15+
* @param node the other node to compare to
16+
* @return isEqualTo
1717
*/
1818
boolean isEqualTo(Node node);
1919
}

src/main/java/graphql/schema/GraphQLDirective.java

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ public EnumSet<DirectiveLocation> validLocations() {
5252

5353
/**
5454
* @deprecated Use {@link #validLocations()}
55+
* @return onOperation
5556
*/
5657
@Deprecated
5758
public boolean isOnOperation() {
@@ -60,6 +61,7 @@ public boolean isOnOperation() {
6061

6162
/**
6263
* @deprecated Use {@link #validLocations()}
64+
* @return onFragment
6365
*/
6466
@Deprecated
6567
public boolean isOnFragment() {
@@ -68,6 +70,7 @@ public boolean isOnFragment() {
6870

6971
/**
7072
* @deprecated Use {@link #validLocations()}
73+
* @return onField
7174
*/
7275
@Deprecated
7376
public boolean isOnField() {
@@ -115,7 +118,9 @@ public Builder argument(GraphQLArgument fieldArgument) {
115118
}
116119

117120
/**
118-
* @deprecated Use {@link graphql.schema.GraphQLDirective.Builder#validLocations(DirectiveLocation...)}
121+
* @deprecated Use {@code graphql.schema.GraphQLDirective.Builder#validLocations(DirectiveLocation...)}
122+
* @param onOperation onOperation
123+
* @return this builder
119124
*/
120125
@Deprecated
121126
public Builder onOperation(boolean onOperation) {
@@ -124,7 +129,9 @@ public Builder onOperation(boolean onOperation) {
124129
}
125130

126131
/**
127-
* @deprecated Use {@link graphql.schema.GraphQLDirective.Builder#validLocations(DirectiveLocation...)}
132+
* @deprecated Use {@code graphql.schema.GraphQLDirective.Builder#validLocations(DirectiveLocation...)}
133+
* @param onFragment onFragment
134+
* @return this builder
128135
*/
129136
@Deprecated
130137
public Builder onFragment(boolean onFragment) {
@@ -133,7 +140,9 @@ public Builder onFragment(boolean onFragment) {
133140
}
134141

135142
/**
136-
* @deprecated Use {@link graphql.schema.GraphQLDirective.Builder#validLocations(DirectiveLocation...)}
143+
* @deprecated Use {@code graphql.schema.GraphQLDirective.Builder#validLocations(DirectiveLocation...)}
144+
* @param onField onField
145+
* @return this builder
137146
*/
138147
@Deprecated
139148
public Builder onField(boolean onField) {

src/main/java/graphql/schema/GraphQLFieldDefinition.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -117,9 +117,9 @@ public Object get(DataFetchingEnvironment environment) {
117117
}
118118

119119
/**
120-
* Get the data from a field.
120+
* Get the data from a field, rather than a property.
121121
*
122-
* @return
122+
* @return this builder
123123
*/
124124
public Builder fetchField() {
125125
this.isField = true;

0 commit comments

Comments
 (0)