Class GreaterThanOrEqualFilter
java.lang.Object
com.invirgance.convirgance.transform.filter.ComparatorFilter
com.invirgance.convirgance.transform.filter.GreaterThanOrEqualFilter
- All Implemented Interfaces:
Filter,Transformer,Predicate<JSONObject>
Filters JSONObjects where the value of a specified key is greater than or
equal to a comparison value. Supports
ValueGenerator as a value.- Author:
- jbanes
-
Constructor Summary
ConstructorsConstructorDescriptionCreates a new unset ComparatorFilter.GreaterThanOrEqualFilter(String key, Object value) Creates a new ComparatorFilter for the expected key, with the provided value to use for comparison. -
Method Summary
Modifier and TypeMethodDescriptionbooleantest(JSONObject record) Returns true when the JSONObject has the expected key and its value is greater than or equal to the comparison.Methods inherited from class com.invirgance.convirgance.transform.filter.ComparatorFilter
getComparator, getKey, getValue, setKey, setValueMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.invirgance.convirgance.transform.Transformer
transform
-
Constructor Details
-
GreaterThanOrEqualFilter
public GreaterThanOrEqualFilter()Creates a new unset ComparatorFilter. -
GreaterThanOrEqualFilter
Creates a new ComparatorFilter for the expected key, with the provided value to use for comparison.- Parameters:
key- The key.value- The comparison value.
-
-
Method Details
-
test
Returns true when the JSONObject has the expected key and its value is greater than or equal to the comparison.- Parameters:
record- The record the compare.- Returns:
- True if the record's key has a value greater than or equal to the comparison value.
-