Class SpringWebQueryPropertiesAutoConfig
java.lang.Object
in.co.akshitbansal.springwebquery.config.SpringWebQueryPropertiesAutoConfig
Publishes the validated global filtering configuration used by the starter's
specification resolver auto-configuration.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionin.co.akshitbansal.springwebquery.SpringWebQueryPropertiesspringWebQueryProperties(String globalFilterParamName, boolean globalAllowAndOperation, boolean globalAllowOrOperation, int globalMaxASTDepth, in.co.akshitbansal.springwebquery.validator.QueryParamNameValidator queryParamNameValidator) Creates the shared immutable container for global filtering defaults contributed through application configuration.
-
Constructor Details
-
SpringWebQueryPropertiesAutoConfig
public SpringWebQueryPropertiesAutoConfig()
-
-
Method Details
-
springWebQueryProperties
@Bean @ConditionalOnMissingBean public in.co.akshitbansal.springwebquery.SpringWebQueryProperties springWebQueryProperties(@Value("${spring-web-query.filtering.filter-param-name:filter}") String globalFilterParamName, @Value("${spring-web-query.filtering.allow-and-operation:true}") boolean globalAllowAndOperation, @Value("${spring-web-query.filtering.allow-or-operation:false}") boolean globalAllowOrOperation, @Value("${spring-web-query.filtering.max-ast-depth:1}") int globalMaxASTDepth, in.co.akshitbansal.springwebquery.validator.QueryParamNameValidator queryParamNameValidator) Creates the shared immutable container for global filtering defaults contributed through application configuration.- Parameters:
globalFilterParamName- configured request parameter name for filter expressionsglobalAllowAndOperation- whether logical AND nodes are allowed by defaultglobalAllowOrOperation- whether logical OR nodes are allowed by defaultglobalMaxASTDepth- configured maximum allowed depth for parsed RSQL ASTsqueryParamNameValidator- validator used for configured filter parameter names- Returns:
- validated global filtering properties
- Throws:
in.co.akshitbansal.springwebquery.exception.QueryConfigurationException- if the configured maximum AST depth is negative
-