@PublicApi public class GraphQLEnumValueDefinition extends Object implements GraphQLDirectiveContainer
GraphQLEnumType
Modifier and Type | Class and Description |
---|---|
static class |
GraphQLEnumValueDefinition.Builder |
Constructor and Description |
---|
GraphQLEnumValueDefinition(String name,
String description,
Object value)
Deprecated.
use the
newEnumValueDefinition() builder pattern instead, as this constructor will be made private in a future version. |
GraphQLEnumValueDefinition(String name,
String description,
Object value,
String deprecationReason)
Deprecated.
use the
newEnumValueDefinition() builder pattern instead, as this constructor will be made private in a future version. |
GraphQLEnumValueDefinition(String name,
String description,
Object value,
String deprecationReason,
List<GraphQLDirective> directives)
Deprecated.
use the
newEnumValueDefinition() builder pattern instead, as this constructor will be made private in a future version. |
@Deprecated public GraphQLEnumValueDefinition(String name, String description, Object value)
newEnumValueDefinition()
builder pattern instead, as this constructor will be made private in a future version.name
- the namedescription
- the descriptionvalue
- the value@Deprecated public GraphQLEnumValueDefinition(String name, String description, Object value, String deprecationReason)
newEnumValueDefinition()
builder pattern instead, as this constructor will be made private in a future version.name
- the namedescription
- the descriptionvalue
- the valuedeprecationReason
- the deprecation reasons@Deprecated public GraphQLEnumValueDefinition(String name, String description, Object value, String deprecationReason, List<GraphQLDirective> directives)
newEnumValueDefinition()
builder pattern instead, as this constructor will be made private in a future version.name
- the namedescription
- the descriptionvalue
- the valuedeprecationReason
- the deprecation reasonsdirectives
- the directives on this type elementpublic String getName()
getName
in interface GraphQLType
[_A-Za-z][_0-9A-Za-z]*
public String getDescription()
public Object getValue()
public boolean isDeprecated()
public String getDeprecationReason()
public List<GraphQLDirective> getDirectives()
getDirectives
in interface GraphQLDirectiveContainer
public Map<String,GraphQLDirective> getDirectivesByName()
getDirectivesByName
in interface GraphQLDirectiveContainer
public GraphQLDirective getDirective(String directiveName)
GraphQLDirectiveContainer
getDirective
in interface GraphQLDirectiveContainer
directiveName
- the name of the directive to retrievepublic EnumValueDefinition getDefinition()
public GraphQLEnumValueDefinition transform(Consumer<GraphQLEnumValueDefinition.Builder> builderConsumer)
builderConsumer
- the consumer code that will be given a builder to transformpublic TraversalControl accept(TraverserContext<GraphQLType> context, GraphQLTypeVisitor visitor)
GraphQLType
Node
, see accept(...) for more details about the pattern.accept
in interface GraphQLType
context
- TraverserContext bound to this graphQL type objectvisitor
- Visitor instance that performs actual processing on the types(s)public List<GraphQLType> getChildren()
getChildren
in interface GraphQLType
public static GraphQLEnumValueDefinition.Builder newEnumValueDefinition()
public static GraphQLEnumValueDefinition.Builder newEnumValueDefinition(GraphQLEnumValueDefinition existing)
Copyright © 2019. All rights reserved.