@PublicApi
public class DirectiveConstraints
extends java.lang.Object
DirectiveConstraints and helps
run them against a specific field or argument
This ships with a set of standard constraints via STANDARD_CONSTRAINTS but you can
add your own implementations if you wish
| Modifier and Type | Class and Description |
|---|---|
static class |
DirectiveConstraints.Builder |
| Modifier and Type | Field and Description |
|---|---|
static java.util.List<DirectiveConstraint> |
STANDARD_CONSTRAINTS
These are the standard directive rules that come with the system
|
| Constructor and Description |
|---|
DirectiveConstraints(DirectiveConstraints.Builder builder) |
| Modifier and Type | Method and Description |
|---|---|
java.util.Map<java.lang.String,DirectiveConstraint> |
getConstraints() |
graphql.schema.idl.TypeDefinitionRegistry |
getDirectivesDeclaration() |
java.lang.String |
getDirectivesSDL() |
static DirectiveConstraints.Builder |
newDirectiveConstraints() |
java.util.List<DirectiveConstraint> |
whichApplyTo(graphql.schema.GraphQLArgument argument,
graphql.schema.GraphQLFieldDefinition fieldDefinition,
graphql.schema.GraphQLFieldsContainer fieldsContainer) |
java.util.List<DirectiveConstraint> |
whichApplyTo(graphql.schema.GraphQLFieldDefinition fieldDefinition,
graphql.schema.GraphQLFieldsContainer fieldsContainer) |
public static final java.util.List<DirectiveConstraint> STANDARD_CONSTRAINTS
public DirectiveConstraints(DirectiveConstraints.Builder builder)
public static DirectiveConstraints.Builder newDirectiveConstraints()
public java.util.Map<java.lang.String,DirectiveConstraint> getConstraints()
public java.lang.String getDirectivesSDL()
public graphql.schema.idl.TypeDefinitionRegistry getDirectivesDeclaration()
public java.util.List<DirectiveConstraint> whichApplyTo(graphql.schema.GraphQLFieldDefinition fieldDefinition, graphql.schema.GraphQLFieldsContainer fieldsContainer)
public java.util.List<DirectiveConstraint> whichApplyTo(graphql.schema.GraphQLArgument argument, graphql.schema.GraphQLFieldDefinition fieldDefinition, graphql.schema.GraphQLFieldsContainer fieldsContainer)