Interface FieldAndArguments


  • @PublicApi
    public interface FieldAndArguments
    This represents a field and its arguments that may be validated.
    • Method Detail

      • getField

        Field getField()
        Returns:
        the field in play
      • getFieldDefinition

        GraphQLFieldDefinition getFieldDefinition()
        Returns:
        the runtime type definition of the field
      • getParentFieldAndArguments

        FieldAndArguments getParentFieldAndArguments()
        Returns:
        the parent arguments or null if there is no parent
      • getPath

        ResultPath getPath()
        Returns:
        the path to this field
      • getArgumentValuesByName

        java.util.Map<java.lang.String,​java.lang.Object> getArgumentValuesByName()
        This will be a map of argument names to argument values. This will contain any variables transferred along with any default values ready for execution. This is what you use to do most of your validation against
        Returns:
        a map of argument names to values
      • getArgumentValue

        <T> T getArgumentValue​(java.lang.String argumentName)
        This will return the named field argument value and cast it to the desired type.
        Type Parameters:
        T - the type of the underlying value object
        Parameters:
        argumentName - the name of the argument
        Returns:
        a cast object of type T