I have a FirebaseRecyclerAdapter
which I do not want to keep updating the RecyclerView
. This is because I have it so it populates the view with items based on how many 'views' they have in the database. The problem is, if other people view the items, the list you see in the app will keep changing order.
Is there a way to stop the recycler adapter from constantly listening for data changes or will I have to go about this another way?
Any help is greatly appreciated, thanks.
The adapters in FirebaseUI are live-bound to the data at the Query/DatabaseReference that you construct them with. There is no way to turn this behavior off in the adapter.
But you can easily create a ValueEventListener
that populates a static List<T>
and feeds that into an ArrayAdapter
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With