| Package | Description |
|---|---|
| com.graphql_java_generator.client | |
| com.graphql_java_generator.client.request |
This package contains all the classes used to generate the requests toward the GraphQL server.
|
| com.graphql_java_generator.client.response |
All classes about the management of the response, coming from the GraphQL server
|
| Modifier and Type | Method and Description |
|---|---|
Class<?> |
GraphqlClientUtils.checkFieldOfGraphQLType(String name,
Boolean shouldBeScalar,
Class<?> owningClass)
Check if the given field is owned by the class of this
ObjectResponse. |
Class<?> |
GraphqlClientUtils.checkIsScalar(Field field,
Boolean shouldBeScalar)
This method checks whether the given field (as an attribute) of the given class is a GraphQL scalar, or not,
depending on shouldBeScalar.
|
Class<?> |
GraphqlClientUtils.checkIsScalar(String fieldName,
Method method,
Boolean shouldBeScalar)
This method checks whether the given field (as a method: getter, query...) of the given class is a GraphQL
scalar, or not, depending on shouldBeScalar.
|
void |
GraphqlClientUtils.checkName(String graphqlIdentifier)
Checks that the given GraphQL name is valid.
|
Class<?> |
GraphqlClientUtils.getGraphQLType(AccessibleObject fieldOrMethod)
Returns the Class indicated as the value for the graphqlType attribute of the GraphQLScalar or GraphQLNonScalar
annotation
|
boolean |
GraphqlClientUtils.isScalar(AccessibleObject fieldOrMethod)
Indicates whether the given class is a scalar or not
|
| Modifier and Type | Method and Description |
|---|---|
ObjectResponse |
Builder.build()
Returns the built
ObjectResponse. |
Builder |
Builder.withField(String fieldName)
Adds a scalar field with no alias, to the
ObjectResponse we are building |
Builder |
Builder.withField(String fieldName,
String alias)
Adds a scalar field with an alias, to the
ObjectResponse we are building |
Builder |
Builder.withQueryResponseDef(String queryResponseDef)
Builds a
ObjectResponse from a part of a GraphQL query. |
Builder |
Builder.withSubObject(ObjectResponse subobjetResponseDef)
Adds a non scalar field (a sub-object), to the
ObjectResponse we are building. |
| Constructor and Description |
|---|
Builder(Class<?> owningClass,
String fieldName)
Creates a Builder, for a field without alias
|
Builder(Class<?> owningClass,
String fieldName,
String fieldAlias)
Creates a Builder
|
| Modifier and Type | Class and Description |
|---|---|
class |
GraphQLInternalErrorException
Thrown when an internal error of the GraphQL generator occurs
|
Copyright © 2020. All rights reserved.