Package graphql.language
Class AstSorter
- java.lang.Object
-
- graphql.language.AstSorter
-
@PublicApi public class AstSorter extends java.lang.Object
A class that helps you sort AST nodes
-
-
Constructor Summary
Constructors Constructor Description AstSorter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description <T extends Node>
Tsort(T nodeToBeSorted)
This will sort nodes in specific orders and then alphabetically.
-
-
-
Method Detail
-
sort
public <T extends Node> T sort(T nodeToBeSorted)
This will sort nodes in specific orders and then alphabetically. The order is :- Query operation definitions
- Mutation operation definitions
- Subscriptions operation definitions
- Fragment definitions
- Directive definitions
- Schema definitions
- Object Type definitions
- Interface Type definitions
- Union Type definitions
- Enum Type definitions
- Scalar Type definitions
- Input Object Type definitions
-
-