public static class AnnotationsSchemaCreator.Builder
extends java.lang.Object
| Constructor and Description |
|---|
Builder() |
| Modifier and Type | Method and Description |
|---|---|
AnnotationsSchemaCreator.Builder |
additionalType(java.lang.Class<?> additionalTypeClass)
Add an additional type to the additional type list
|
AnnotationsSchemaCreator.Builder |
additionalTypes(java.util.Set<java.lang.Class<?>> additionalTypes)
Add a set of additional types to the additional type lise
|
graphql.schema.GraphQLSchema |
build()
Build a graphql schema according to the properties provided
The method generates the GraphQL objects, directives, additional types, etc using the graphql annotations processor and sets them into the GraphQL Schema
|
AnnotationsSchemaCreator.Builder |
directive(java.lang.Class<?> directiveClass)
Add a directive to the graphql schema
This method will generate a GraphQL Directive type out of your java class using the annotations processor
|
AnnotationsSchemaCreator.Builder |
directives(java.util.Set<java.lang.Class<?>> directiveClasses)
Set the directives of the graphql schema
This method will generate a GraphQL Directive type out of your java classes using the annotations processor
|
GraphQLAnnotations |
getGraphQLAnnotations() |
AnnotationsSchemaCreator.Builder |
mutation(java.lang.Class<?> mutationClass)
Set the Mutation of the graphql schema
This method will generate a GraphQL Mutation type out of your java class using the annotations processor
|
AnnotationsSchemaCreator.Builder |
query(java.lang.Class<?> queryClass)
Set the Query of the graphql schema
This method will generate a GraphQL Query type out of your java class using the annotations processor
|
AnnotationsSchemaCreator.Builder |
setAlwaysPrettify(java.lang.Boolean shouldAlwaysPrettify)
Set the always prettify property of the graphql annotations processor (whether or not to prettify the graphql names)
|
AnnotationsSchemaCreator.Builder |
setAnnotationsProcessor(GraphQLAnnotations annotationsProcessor)
You can set your own annotations processor
|
AnnotationsSchemaCreator.Builder |
setGraphQLSchemaBuilder(graphql.schema.GraphQLSchema.Builder schemaBuilder)
You can set your own schema builder, but its optional
|
AnnotationsSchemaCreator.Builder |
setRelay(graphql.relay.Relay relay)
Set the relay object in the graphql annotations processor
|
AnnotationsSchemaCreator.Builder |
subscription(java.lang.Class<?> subscriptionClass)
Set the Subscription of the graphql schema
This method will generate a GraphQL Subscription type out of your java class using the annotations processor
|
AnnotationsSchemaCreator.Builder |
typeExtension(java.lang.Class<?> typeExtension)
Register a type extensions to the graphql processor
|
AnnotationsSchemaCreator.Builder |
typeFunction(TypeFunction typeFunction)
Register a type function to the graphql processor
|
public AnnotationsSchemaCreator.Builder setGraphQLSchemaBuilder(graphql.schema.GraphQLSchema.Builder schemaBuilder)
schemaBuilder - a graphql schema builderpublic AnnotationsSchemaCreator.Builder setAnnotationsProcessor(GraphQLAnnotations annotationsProcessor)
annotationsProcessor - the annotations processor which creates the GraphQLTypespublic AnnotationsSchemaCreator.Builder query(java.lang.Class<?> queryClass)
queryClass - the Query java classpublic AnnotationsSchemaCreator.Builder mutation(java.lang.Class<?> mutationClass)
mutationClass - the Mutation java classpublic AnnotationsSchemaCreator.Builder subscription(java.lang.Class<?> subscriptionClass)
subscriptionClass - the Subscription java classpublic AnnotationsSchemaCreator.Builder directives(java.util.Set<java.lang.Class<?>> directiveClasses)
directiveClasses - a set of directive classespublic AnnotationsSchemaCreator.Builder directive(java.lang.Class<?> directiveClass)
directiveClass - a Directive java classpublic AnnotationsSchemaCreator.Builder additionalType(java.lang.Class<?> additionalTypeClass)
additionalTypeClass - an additional type classpublic AnnotationsSchemaCreator.Builder additionalTypes(java.util.Set<java.lang.Class<?>> additionalTypes)
additionalTypes - a set of additional type classespublic AnnotationsSchemaCreator.Builder typeExtension(java.lang.Class<?> typeExtension)
typeExtension - a type extension classpublic AnnotationsSchemaCreator.Builder typeFunction(TypeFunction typeFunction)
typeFunction - a type functionpublic AnnotationsSchemaCreator.Builder setAlwaysPrettify(java.lang.Boolean shouldAlwaysPrettify)
shouldAlwaysPrettify - a boolean flagpublic AnnotationsSchemaCreator.Builder setRelay(graphql.relay.Relay relay)
relay - a relay objectpublic GraphQLAnnotations getGraphQLAnnotations()
public graphql.schema.GraphQLSchema build()