Class SuperModelFilter<T extends SuperModelFilter<T,​R>,​R>

    • Field Detail

      • NULL

        public Set<String> NULL
        Names of properties to test with .isNull()
      • NOTNULL

        public Set<String> NOTNULL
        Names of properties to test with .isNotNull()
      • NOT

        public T extends SuperModelFilter<T,​R> NOT
        The negative filters, but don't de-/serialize it's own NOT-properties.
    • Constructor Detail

      • SuperModelFilter

        public SuperModelFilter()
    • Method Detail

      • isEmpty

        public final boolean isEmpty()
        Does the property filter specify any conditions?
        Specified by:
        isEmpty in interface Filter
        Returns:
        true if no conditions are specified.
      • collectPredicates

        public abstract List<com.querydsl.core.types.Predicate> collectPredicates()
      • boostedFields

        public String[] boostedFields()
        Return the fields boosted in ES search
        Returns:
        null -- no fields boosted
      • remappedProperties

        public Map<String,​String> remappedProperties()
        Return the map of remapped props
        Returns:
        null -- no props remapped
      • buildPredicate

        public com.querydsl.core.BooleanBuilder buildPredicate()
        Builds the DSL predicate.
        Returns:
        the predicate
      • collectPredicates

        protected List<com.querydsl.core.types.Predicate> collectPredicates​(com.querydsl.core.types.dsl.EntityPathBase<R> instance)
        Collects list of this filter predicates. Does not include NOT, OR and AND. Those are used in buildPredicate()!
        Parameters:
        instance - the instance of Q-type of R
        Returns:
        list of predicates
      • removeFromNullAndNotNull

        protected final void removeFromNullAndNotNull​(String jsonPath)
      • getSubClasses

        protected Set<Class<? extends com.querydsl.core.types.dsl.EntityPathBase<? extends R>>> getSubClasses()
      • copy

        public <X> X copy​(Class<X> targetType)
        Copy by serializing to JSON and de-serializing to specified type.
        Type Parameters:
        X - the generic type
        Parameters:
        targetType - the target type
        Returns:
        the x
      • normalize

        public static <Y extends SuperModelFilter<Y,​?>> Y normalize​(Y filter)
        Prepare filter for use. NULL and NOTNULLs will clear any actual values provided for those properties.
        Type Parameters:
        Y - any SuperModelFilter subtype
        Parameters:
        filter - the filter
        Returns:
        the normalized valid filter