Package graphql.normalized
Class VariableAccumulator
java.lang.Object
graphql.normalized.VariableAccumulator
This accumulator class decides on whether to create a variable for a query argument and if so it tracks what variables were made.
The
ExecutableNormalizedOperationToAstCompiler
then uses all the variables when it compiles the final document.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaccumulateVariable
(NormalizedInputValue normalizedInputValue) int
boolean
shouldMakeVariable
(ExecutableNormalizedField executableNormalizedField, QueryAppliedDirective queryAppliedDirective, String argName, NormalizedInputValue normalizedInputValue)
-
Constructor Details
-
VariableAccumulator
-
-
Method Details
-
shouldMakeVariable
public boolean shouldMakeVariable(ExecutableNormalizedField executableNormalizedField, QueryAppliedDirective queryAppliedDirective, String argName, NormalizedInputValue normalizedInputValue) -
accumulateVariable
-
getAccumulatedSize
public int getAccumulatedSize() -
getVariableDefinitions
- Returns:
- the variable definitions that would go on the operation declaration
-
getVariablesMap
- Returns:
- the map of variable names to variable values
-