else
{
// pattern matches will be non-case-sensitive
- pattern = compareTo.toUpperCase();
+ pattern = compareTo == null ? null : compareTo.toUpperCase();
}
// if we add regex conditions (e.g. matchesPattern), then
if (val == null)
{
return condition == Condition.NotContains
- || condition == Condition.NotMatches;
+ || condition == Condition.NotMatches
+ || condition == Condition.NotPresent;
}
String upper = val.toUpperCase().trim();
case NotContains:
matched = upper.indexOf(pattern) == -1;
break;
+ case Present:
+ matched = true;
+ break;
+ default:
+ break;
}
return matched;
}
case GE:
matched = f >= value;
break;
+ default:
+ break;
}
return matched;