Package es.situm.sdk.utils.filter
Class Filter
- java.lang.Object
-
- es.situm.sdk.utils.filter.Filter
-
public class Filter extends java.lang.Object
Deprecated.Use a for with an if to filter the collectionFilter a collection of Filterable objects, by name|value of their custom fields.The filter just stores
getFilterMode()
andgetKeyValueFilters()
. You can instance a filter, specifying how to filter, and reuse it to filter multiple collections.- See Also:
Filter.FilterMode
,Filter.KeyValueFilter
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
Filter.FilterMode
Deprecated.Use a for with an if to filter the collectionstatic class
Filter.KeyValueFilter
Deprecated.Use a for with an if to filter the collection
-
Constructor Summary
Constructors Constructor Description Filter(Filter.FilterMode filterMode, java.util.Collection<Filter.KeyValueFilter> keyValueFilters)
Deprecated.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description <T extends Filterable>
java.util.ArrayList<T>filter(java.util.Collection<T> toFilter)
Deprecated.Filter the passed list of items using the stored filters.Filter.FilterMode
getFilterMode()
Deprecated.java.util.Collection<Filter.KeyValueFilter>
getKeyValueFilters()
Deprecated.
-
-
-
Constructor Detail
-
Filter
public Filter(Filter.FilterMode filterMode, java.util.Collection<Filter.KeyValueFilter> keyValueFilters)
Deprecated.- Parameters:
filterMode
- can't be nullkeyValueFilters
- can't be null- Throws:
java.lang.NullPointerException
- if some parameter is null
-
-
Method Detail
-
getKeyValueFilters
public java.util.Collection<Filter.KeyValueFilter> getKeyValueFilters()
Deprecated.
-
getFilterMode
public Filter.FilterMode getFilterMode()
Deprecated.
-
filter
public <T extends Filterable> java.util.ArrayList<T> filter(java.util.Collection<T> toFilter)
Deprecated.Filter the passed list of items using the stored filters.- Parameters:
toFilter
- element to filter. Is not altered.- Returns:
- new list with the resulting filtered items. Provided list is not altered.
- Throws:
java.lang.NullPointerException
- if some parameter is null
-
-