Class PredicateQuery


  • @Beta
    public class PredicateQuery
    extends java.lang.Object
    Represents a query in the form of a set of boolean variables that are considered true.
    Author:
    Magnar Nedland, bjorncs
    • Constructor Detail

      • PredicateQuery

        public PredicateQuery()
    • Method Detail

      • addFeature

        public void addFeature​(java.lang.String key,
                               java.lang.String value)
        Adds a feature to the query
        Parameters:
        key - a feature key
        value - a feature value
      • addFeature

        public void addFeature​(java.lang.String key,
                               java.lang.String value,
                               long subqueryBitMap)
        Adds a feature to the query, e.g. gender = male.
        Parameters:
        key - Feature key
        value - Feature value
        subqueryBitMap - The subquery bitmap for which this term is true
      • addRangeFeature

        public void addRangeFeature​(java.lang.String key,
                                    long value)
      • addRangeFeature

        public void addRangeFeature​(java.lang.String key,
                                    long value,
                                    long subqueryBitMap)
        Adds a range feature to the query, e.g. age = 25.
        Parameters:
        key - a feature key
        value - a feature value
        subqueryBitMap - the subquery bitmap for which this term is true