Scenario
I needed to introduce a search
or filter
in my android application on the basis of some Tags
. I have a Json
response coming from some Retrofit
calls in a Staggered Grid
view.
Questions
- What would be good approach to do it? Instant Search? If yes, then How can i achieve it?
- I am fetching data in
Json
and saving it intoModel
class. Can I take help fromModel
class to implement Search? - How can retrofit help me in searching?
- Any other concerns?
Any help would be appreciable :)
Edit-1
Elaborating more:
- I do have a
Json
response coming fromRetrofit
request. Sample of
json
:{"Value":2,"tags":["workout","game"]} {"Value":2,"tags":["game","person"]}
There are a lot of data coming from the
Json
which I am not pasting here. I am loading aboveJson
inRecycler Staggered Grid View
.I do have a Search bar where user will put multiple
Tags
likegame, Person
.This search will fetch
Values
associated with givenTags
in search box.