Class AbstractGraphQLQueryOptions

All Implemented Interfaces:
Options, Validatable
Direct Known Subclasses:
ListQueryOptions, SearchQueryOptions

public class AbstractGraphQLQueryOptions extends AbstractGraphQLOptions
Abstract base class for all GraphQL Options
  • Constructor Details

    • AbstractGraphQLQueryOptions

      public AbstractGraphQLQueryOptions()
  • Method Details

    • validate

      public Validation validate()
      Description copied from class: AbstractGeneratorSubOptions
      Checks if the current options are valid, return a list of errors if the options are not valid
      Specified by:
      validate in interface Validatable
      Overrides:
      validate in class AbstractGraphQLOptions
      Returns:
      a Validation object than can be used queried to find if the options are valid and any errors if the options are not valid
    • override

      public void override(AbstractGraphQLQueryOptions overrideOptions)
      Overrides the values in this Options Object from the provided Options Object if they are non-null
      Parameters:
      overrideOptions - the options which will be used to override this Options Object
    • getResponseTypeNameForType

      public final String getResponseTypeNameForType(@NonNull @NonNull String typeName)
      Gets the response type name for a specific primary model
      Parameters:
      typeName - the name of the query
      Returns:
      the response type name for a specific primary model
    • getResponseTypeNameForQuery

      public final String getResponseTypeNameForQuery(@NonNull @NonNull String queryName)
      Gets the response type name of the query for a specific primary model
      Parameters:
      queryName - the name of the query
      Returns:
      the response type name of the query for a specific primary model
    • hasInputFor

      public final boolean hasInputFor(@NonNull @NonNull String name)
      Determines if the Query accepts an input object for a specific primary model
      Parameters:
      name - the name of the primary model
      Returns:
      true if the Query accepts an input object for a specific primary model, false otherwise
    • hasInputFor

      public final boolean hasInputFor(@NonNull @NonNull BrAPIType type)
      Determines if the Query accepts an input object for a specific primary model
      Parameters:
      type - the primary model
      Returns:
      true if the Query accepts an input object for a specific primary model, false otherwise
    • setInputFor

      public AbstractGraphQLQueryOptions setInputFor(String name, boolean hasInput)
      Sets if the Query accepts an input object for a specific primary model
      Parameters:
      name - the name of the primary model
      hasInput - true if the Query accepts an input object for a specific primary model, false otherwise
      Returns:
      the options for chaining