Skip to content

Make filter object of any type, not only String #540

@davideas

Description

@davideas

Reason of the improvement

Give the possibility to apply a multi filter simultaneously on more fields.

Impact

It will have an impact on IFilterable signature, so the filter() method can accept a custom type.
New methods will substitute the current when managing the filter:

Old methods New methods
setSearchText(String) => setFilter(Serializable)
String getSearchText() => Serializable getFilter()
boolean hasSearchText() => boolean hasFilter()
`boolean hasNewSearchText(String) => boolean hasNewFilter(Serializable)

If filter object is of type String, automatic trim and lowercase is maintained when setting it.
Must be of type Serializable in order to maintain save/restore instance state on configuration changes. String it is.

⚠️ Note: Old methods will be removed from next release.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions