Package graphql

Class DirectivesUtil


  • public class DirectivesUtil
    extends java.lang.Object
    • Constructor Detail

      • DirectivesUtil

        public DirectivesUtil()
    • Method Detail

      • nonRepeatableDirectivesByName

        @Deprecated
        public static java.util.Map<java.lang.String,​GraphQLDirective> nonRepeatableDirectivesByName​(java.util.List<GraphQLDirective> directives)
        Deprecated.
      • allDirectivesByName

        @Deprecated
        public static java.util.Map<java.lang.String,​com.google.common.collect.ImmutableList<GraphQLDirective>> allDirectivesByName​(java.util.List<GraphQLDirective> directives)
        Deprecated.
      • directiveWithArg

        @Deprecated
        public static java.util.Optional<GraphQLArgument> directiveWithArg​(java.util.List<GraphQLDirective> directives,
                                                                           java.lang.String directiveName,
                                                                           java.lang.String argumentName)
        Deprecated.
      • isAllNonRepeatable

        @Deprecated
        public static boolean isAllNonRepeatable​(java.util.List<GraphQLDirective> directives)
        Deprecated.
      • getFirstDirective

        @Deprecated
        public static GraphQLDirective getFirstDirective​(java.lang.String name,
                                                         java.util.Map<java.lang.String,​java.util.List<GraphQLDirective>> allDirectivesByName)
        Deprecated.
      • toAppliedDirectives

        public static java.util.List<GraphQLAppliedDirective> toAppliedDirectives​(GraphQLDirectiveContainer directiveContainer)
        This can take a collection of legacy directives and turn them applied directives, and combine them with any applied directives. The applied directives collection takes precedence.
        Parameters:
        directiveContainer - the schema element holding applied directives
        Returns:
        a combined list unique by name
      • toAppliedDirectives

        public static java.util.List<GraphQLAppliedDirective> toAppliedDirectives​(java.util.Collection<GraphQLAppliedDirective> appliedDirectives,
                                                                                  java.util.Collection<GraphQLDirective> directives)
        This can take a collection of legacy directives and turn them applied directives, and combine them with any applied directives. The applied directives collection takes precedence.
        Parameters:
        appliedDirectives - the applied directives to use
        directives - the legacy directives to use
        Returns:
        a combined list unique by name