Class FilterDefinition

    • Constructor Detail

      • FilterDefinition

        public FilterDefinition​(String name,
                                String defaultCondition,
                                @Nullable Map<String,​JdbcMapping> explicitParamJaMappings)
        Construct a new FilterDefinition instance.
        Parameters:
        name - The name of the filter for which this configuration is in effect.
    • Method Detail

      • getFilterName

        public String getFilterName()
        Get the name of the filter this configuration defines.
        Returns:
        The filter name for this configuration.
      • getParameterNames

        public Set<String> getParameterNames()
        Get a set of the parameters defined by this configuration.
        Returns:
        The parameters named by this configuration.
      • getParameterJdbcMapping

        public @Nullable JdbcMapping getParameterJdbcMapping​(String parameterName)
        Retrieve the type of the named parameter defined for this filter.
        Parameters:
        parameterName - The name of the filter parameter for which to return the type.
        Returns:
        The type of the named parameter.
      • getParameterResolver

        public @Nullable Supplier<?> getParameterResolver​(String parameterName)
      • getDefaultFilterCondition

        public String getDefaultFilterCondition()
      • isAppliedToLoadByKey

        public boolean isAppliedToLoadByKey()
        Get a flag that defines if the filter should be applied on direct fetches or not.
        Returns:
        The flag value.
      • processArgument

        public Object processArgument​(Object value)
        Called before binding a JDBC parameter
        Parameters:
        value - the argument to the parameter, as set via Filter.setParameter(String, Object)
        Returns:
        the argument that will actually be bound to the parameter
      • isAutoEnabled

        public boolean isAutoEnabled()
        Get a flag that defines if the filter should be enabled by default.
        Returns:
        The flag value.