Skip to content

Commit 36905f3

Browse files
authored
fix typos in javadoc, messages and comments (#2840)
1 parent 9b4ee64 commit 36905f3

30 files changed

+65
-65
lines changed

src/main/java/graphql/GraphQL.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@
5353
* and the {@link graphql.execution.ExecutionStrategy execution strategy}
5454
* <p>
5555
* Building this object is very cheap and can be done on each execution if necessary. Building the schema is often not
56-
* as cheap, especially if its parsed from graphql IDL schema format via {@link graphql.schema.idl.SchemaParser}.
56+
* as cheap, especially if it's parsed from graphql IDL schema format via {@link graphql.schema.idl.SchemaParser}.
5757
* <p>
5858
* The data for a query is returned via {@link ExecutionResult#getData()} and any errors encountered as placed in
5959
* {@link ExecutionResult#getErrors()}.
@@ -669,7 +669,7 @@ private static Instrumentation checkInstrumentationDefaultState(Instrumentation
669669

670670
//
671671
// if we don't have a DataLoaderDispatcherInstrumentation in play, we add one. We want DataLoader to be 1st class in graphql without requiring
672-
// people to remember to wire it in. Later we may decide to have more default instrumentations but for now its just the one
672+
// people to remember to wire it in. Later we may decide to have more default instrumentations but for now it's just the one
673673
//
674674
List<Instrumentation> instrumentationList = new ArrayList<>();
675675
if (instrumentation instanceof ChainedInstrumentation) {

src/main/java/graphql/GraphqlErrorHelper.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ public static Map<String, Object> toSpecification(GraphQLError error) {
3838
} else {
3939
extensions = new LinkedHashMap<>();
4040
}
41-
// put in the classification unless its already there
41+
// put in the classification unless it's already there
4242
if (!extensions.containsKey("classification")) {
4343
extensions.put("classification", errorClassification.toSpecification(error));
4444
}

src/main/java/graphql/ParseAndValidate.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
/**
1515
* This class allows you to parse and validate a graphql query without executing it. It will tell you
16-
* if its syntactically valid and also semantically valid according to the graphql specification
16+
* if it's syntactically valid and also semantically valid according to the graphql specification
1717
* and the provided schema.
1818
*/
1919
@PublicApi

src/main/java/graphql/ParseAndValidateResult.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -38,21 +38,21 @@ public boolean isFailure() {
3838
}
3939

4040
/**
41-
* @return the parsed document or null if its syntactically invalid.
41+
* @return the parsed document or null if it's syntactically invalid.
4242
*/
4343
public Document getDocument() {
4444
return document;
4545
}
4646

4747
/**
48-
* @return the document variables or null if its syntactically invalid.
48+
* @return the document variables or null if it's syntactically invalid.
4949
*/
5050
public Map<String, Object> getVariables() {
5151
return variables;
5252
}
5353

5454
/**
55-
* @return the parsed document and variables or null if its syntactically invalid.
55+
* @return the parsed document and variables or null if it's syntactically invalid.
5656
*/
5757
public DocumentAndVariables getDocumentAndVariables() {
5858
if (document != null) {
@@ -62,14 +62,14 @@ public DocumentAndVariables getDocumentAndVariables() {
6262
}
6363

6464
/**
65-
* @return the syntax exception or null if its syntactically valid.
65+
* @return the syntax exception or null if it's syntactically valid.
6666
*/
6767
public InvalidSyntaxException getSyntaxException() {
6868
return syntaxException;
6969
}
7070

7171
/**
72-
* @return a list of validation errors, which might be empty if its syntactically invalid.
72+
* @return a list of validation errors, which might be empty if it's syntactically invalid.
7373
*/
7474
public List<ValidationError> getValidationErrors() {
7575
return validationErrors;

src/main/java/graphql/execution/Async.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ private static <T, U> void eachSequentiallyImpl(Iterator<T> iterator, CFFactory<
9595

9696

9797
/**
98-
* Turns an object T into a CompletableFuture if its not already
98+
* Turns an object T into a CompletableFuture if it's not already
9999
*
100100
* @param t - the object to check
101101
* @param <T> for two

src/main/java/graphql/execution/ExecutionContext.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -183,8 +183,8 @@ public void addError(GraphQLError error, ResultPath fieldPath) {
183183
synchronized (this) {
184184
//
185185
// see http://facebook.github.io/graphql/#sec-Errors-and-Non-Nullability about how per
186-
// field errors should be handled - ie only once per field if its already there for nullability
187-
// but unclear if its not that error path
186+
// field errors should be handled - ie only once per field if it's already there for nullability
187+
// but unclear if it's not that error path
188188
//
189189
if (!errorPaths.add(fieldPath)) {
190190
return;

src/main/java/graphql/execution/ExecutionStepInfo.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ public Map<String, Object> getArguments() {
170170
* @param name the name of the argument
171171
* @param <T> you decide what type it is
172172
*
173-
* @return the named argument or null if its not present
173+
* @return the named argument or null if it's not present
174174
*/
175175
@SuppressWarnings("unchecked")
176176
public <T> T getArgument(String name) {

src/main/java/graphql/execution/ExecutionStrategy.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@
9797
* <p>
9898
* The execution of a field has two phases, first a raw object must be fetched for a field via a {@link DataFetcher} which
9999
* is defined on the {@link GraphQLFieldDefinition}. This object must then be 'completed' into a suitable value, either as a scalar/enum type via
100-
* coercion or if its a complex object type by recursively calling the execution strategy for the lower level fields.
100+
* coercion or if it's a complex object type by recursively calling the execution strategy for the lower level fields.
101101
* <p>
102102
* The first phase (data fetching) is handled by the method {@link #fetchField(ExecutionContext, ExecutionStrategyParameters)}
103103
* <p>
@@ -686,7 +686,7 @@ private Object handleCoercionProblem(ExecutionContext context, ExecutionStrategy
686686
*
687687
* @return an Iterable from that object
688688
*
689-
* @throws java.lang.ClassCastException if its not an Iterable
689+
* @throws java.lang.ClassCastException if it's not an Iterable
690690
*/
691691
protected Iterable<Object> toIterable(Object result) {
692692
return FpKit.toIterable(result);

src/main/java/graphql/execution/preparsed/PreparsedDocumentProvider.java

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,12 @@
1313
@PublicSpi
1414
public interface PreparsedDocumentProvider {
1515
/**
16-
* This is called to get a "cached" pre-parsed query and if its not present, then the "parseAndValidateFunction"
16+
* This is called to get a "cached" pre-parsed query and if it's not present, then the "parseAndValidateFunction"
1717
* can be called to parse and validate the query.
1818
* <p>
19-
* Note - the "parseAndValidateFunction" MUST be called if you dont have a per parsed version of the query because it not only parses
19+
* Note - the "parseAndValidateFunction" MUST be called if you don't have a per parsed version of the query because it not only parses
2020
* and validates the query, it invokes {@link graphql.execution.instrumentation.Instrumentation} calls as well for parsing and validation.
21-
* if you dont make a call back on this then these wont happen.
21+
* if you don't make a call back on this then these wont happen.
2222
*
2323
* @param executionInput The {@link graphql.ExecutionInput} containing the query
2424
* @param parseAndValidateFunction If the query has not be pre-parsed, this function MUST be called to parse and validate it
@@ -30,12 +30,12 @@ public interface PreparsedDocumentProvider {
3030
PreparsedDocumentEntry getDocument(ExecutionInput executionInput, Function<ExecutionInput, PreparsedDocumentEntry> parseAndValidateFunction);
3131

3232
/**
33-
* This is called to get a "cached" pre-parsed query and if its not present, then the "parseAndValidateFunction"
33+
* This is called to get a "cached" pre-parsed query and if it's not present, then the "parseAndValidateFunction"
3434
* can be called to parse and validate the query.
3535
* <p>
36-
* Note - the "parseAndValidateFunction" MUST be called if you dont have a per parsed version of the query because it not only parses
36+
* Note - the "parseAndValidateFunction" MUST be called if you don't have a per parsed version of the query because it not only parses
3737
* and validates the query, it invokes {@link graphql.execution.instrumentation.Instrumentation} calls as well for parsing and validation.
38-
* if you dont make a call back on this then these wont happen.
38+
* if you don't make a call back on this then these won't happen.
3939
*
4040
* @param executionInput The {@link graphql.ExecutionInput} containing the query
4141
* @param parseAndValidateFunction If the query has not be pre-parsed, this function MUST be called to parse and validate it

src/main/java/graphql/execution/reactive/CompletionStageMappingPublisher.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ private void offerToInFlightQ(CompletionStage<?> completionStage) {
159159
}
160160

161161
private boolean removeFromInFlightQAndCheckIfEmpty(CompletionStage<?> completionStage) {
162-
// uncontested locks in java are cheap - we dont expect much contention here
162+
// uncontested locks in java are cheap - we don't expect much contention here
163163
synchronized (inFlightDataQ) {
164164
inFlightDataQ.remove(completionStage);
165165
return inFlightDataQ.isEmpty();

0 commit comments

Comments
 (0)