Reputation: 1010
I am reading this manual https://developer.android.com/topic/libraries/data-binding/index.html and it is not clear for me, how to fill the TableLayout with rows if my data is kept in ObservableArrayList? All examples assume there to show a single record, but I want to show all records in the table.
Or may be it is impossible and I should use RecyclerView instead?
Upvotes: 1
Views: 2141
Reputation: 20926
You might find this article helpful:
https://medium.com/google-developers/android-data-binding-list-tricks-ef3d5630555e#.c1vesyobm
It discusses how to turn lists in to Views in a ViewGroup. When you make it work for TableView, you might want to publish it here for people to use.
That said, if you have only a few Views, you can use data binding. If you're planning on having a scrolling list, you should use RecyclerView.
Upvotes: 2