Class ListQueryOptions
java.lang.Object
org.brapi.schematools.core.options.AbstractGeneratorSubOptions
org.brapi.schematools.core.graphql.options.AbstractGraphQLOptions
org.brapi.schematools.core.graphql.options.AbstractGraphQLQueryOptions
org.brapi.schematools.core.graphql.options.ListQueryOptions
- All Implemented Interfaces:
Options,Validatable
Provides options for the generation of List Queries
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanDetermine if any list query has pagingfinal booleanisPagedFor(@NonNull String name) Determines if the Query is paged for a specific primary modelfinal booleanisPagedFor(@NonNull BrAPIType type) Determines if the Query is paged for a specific primary modelvoidoverride(ListQueryOptions overrideOptions) Overrides the values in this Options Object from the provided Options Object if they are non-nullfinal ListQueryOptionssetPagedFor(String name, boolean hasInput) Sets if the Query is paged for a specific primary modelvalidate()Checks if the current options are valid, return a list of errors if the options are not validMethods inherited from class org.brapi.schematools.core.graphql.options.AbstractGraphQLQueryOptions
getResponseTypeNameForQuery, getResponseTypeNameForType, hasInputFor, hasInputFor, override, setInputForMethods inherited from class org.brapi.schematools.core.graphql.options.AbstractGraphQLOptions
getNameFor, getNameFor, isPluralisingName, overrideMethods inherited from class org.brapi.schematools.core.options.AbstractGeneratorSubOptions
getDescriptionFor, getDescriptionFor, isGenerating, isGeneratingFor, isGeneratingFor, override, setGenerateFor, setGenerateFor
-
Constructor Details
-
ListQueryOptions
public ListQueryOptions()
-
-
Method Details
-
validate
Description copied from class:AbstractGeneratorSubOptionsChecks if the current options are valid, return a list of errors if the options are not valid- Specified by:
validatein interfaceValidatable- Overrides:
validatein classAbstractGraphQLQueryOptions- 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
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
-
hasPaging
public boolean hasPaging()Determine if any list query has paging- Returns:
trueif any list query has paging.falseotherwise
-
isPagedFor
Determines if the Query is paged for a specific primary model- Parameters:
name- the name of the primary model- Returns:
trueif the Query is paged for a specific primary model,falseotherwise
-
isPagedFor
Determines if the Query is paged for a specific primary model- Parameters:
type- the primary model- Returns:
trueif the Query is paged for a specific primary model,falseotherwise
-
setPagedFor
Sets if the Query is paged for a specific primary model- Parameters:
name- the name of the primary modelhasInput-trueif the Query is paged for a specific primary model,falseotherwise- Returns:
- the options for chaining
-