Class Quantifier

  • public class Quantifier
    extends EnumeratedAttribute
    EnumeratedAttribute for quantifier comparisons. Evaluates a boolean[] or raw true and false counts. Accepts the following values:
    none false
    none false
    none false
    at least one true
    at least one true
    exactly one true
    more true than false
    more true than false
    none true
    Ant 1.7
    • Field Detail

      • ALL

        public static final Quantifier ALL
        ALL instance
      • ANY

        public static final Quantifier ANY
        ANY instance
      • ONE

        public static final Quantifier ONE
        ONE instance
      • MAJORITY

        public static final Quantifier MAJORITY
        MAJORITY instance
      • NONE

        public static final Quantifier NONE
        NONE instance
    • Constructor Detail

      • Quantifier

        public Quantifier()
        Default constructor.
      • Quantifier

        public Quantifier​(java.lang.String value)
        Construct a new Quantifier with the specified value.
        value - the EnumeratedAttribute value.
    • Method Detail

      • getValues

        public java.lang.String[] getValues()
        Return the possible values.
        Specified by:
        getValues in class EnumeratedAttribute
        String[] of EnumeratedAttribute values.
      • evaluate

        public boolean evaluate​(boolean[] b)
        Evaluate a boolean array.
        b - the boolean[] to evaluate.
        true if the argument fell within the parameters of this Quantifier.
      • evaluate

        public boolean evaluate​(int t,
                                int f)
        Evaluate integer true vs. false counts.
        t - the number of true values.
        f - the number of false values.
        true if the arguments fell within the parameters of this Quantifier.