Interface SelectedField


  • @ProviderType
    public interface SelectedField
    Interface to wrap information from GraphQL SelectedField.

    As described in SelectionSet, it is aimed to map the SelectedField to the minimum information required when processing the query.

    InlineFragment are mapped so that its isInline() is return true.

    • Method Detail

      • getName

        @Nullable
        @Nullable String getName()
        Returns:
        the name as defined in the selection set.
      • getSubSelectedFields

        @NotNull
        @NotNull List<SelectedField> getSubSelectedFields()
        Returns:
        the sub selected fields.
      • getSubSelectedField

        @Nullable
        @Nullable SelectedField getSubSelectedField​(String name)
        Parameters:
        name - the sub selected field name.
        Returns:
        the object or null if that doesn't exist.
      • hasSubSelectedFields

        boolean hasSubSelectedFields​(String... name)
        Parameters:
        name - the sub selected field name(s).
        Returns:
        true if any of the sub selected fields exists.
      • isInline

        @Deprecated
        boolean isInline()
        Deprecated.
        There are no more inlined fragments anymore so this is always false
        Returns:
        true if this field is an inline (i.e: ... on Something { }).
      • getObjectTypeNames

        @NotNull
        @NotNull List<String> getObjectTypeNames()
        The Object Type Name is taken from the Normalized Field from GraphQL Java and denotes any inlined fragment type that field can be part of
        Returns:
        List of Object Type Names which is always a List but might be empty