@PublicApi public class QueryAppliedDirective extends java.lang.Object
Originally graphql-java re-used the GraphQLDirective and GraphQLArgument
classes to do both purposes. This was a modelling mistake. New QueryAppliedDirective and QueryAppliedDirectiveArgument
classes have been introduced to better model when a directive is applied to a query element,
as opposed to its schema definition itself.
See http://graphql.org/learn/queries/#directives for more details on the concept.
| Modifier and Type | Class and Description |
|---|---|
static class |
QueryAppliedDirective.Builder |
| Modifier and Type | Method and Description |
|---|---|
QueryAppliedDirectiveArgument |
getArgument(java.lang.String name) |
java.util.List<QueryAppliedDirectiveArgument> |
getArguments() |
Directive |
getDefinition() |
java.lang.String |
getDescription() |
java.lang.String |
getName() |
static QueryAppliedDirective.Builder |
newDirective() |
static QueryAppliedDirective.Builder |
newDirective(QueryAppliedDirective existing) |
java.lang.String |
toString() |
QueryAppliedDirective |
transform(java.util.function.Consumer<QueryAppliedDirective.Builder> builderConsumer)
This helps you transform the current GraphQLDirective into another one by starting a builder with all
the current values and allows you to transform it how you want.
|
@Nonnull public java.lang.String getName()
@Nullable public java.lang.String getDescription()
public java.util.List<QueryAppliedDirectiveArgument> getArguments()
@Nullable public QueryAppliedDirectiveArgument getArgument(java.lang.String name)
@Nullable public Directive getDefinition()
public java.lang.String toString()
toString in class java.lang.Objectpublic QueryAppliedDirective transform(java.util.function.Consumer<QueryAppliedDirective.Builder> builderConsumer)
builderConsumer - the consumer code that will be given a builder to transformpublic static QueryAppliedDirective.Builder newDirective()
public static QueryAppliedDirective.Builder newDirective(QueryAppliedDirective existing)