Question

I made a listview with 3 columns by overriding the getView() method. I extended the class Arrayadaper for my own class and than used that for setListAdapter(Myclass). But i don't really understand how this works.. There is no for or while here. How does this go through every item in the list? How does setlistadaper and arrayadapter works? Where is the for or while? Int Position is one of the argument in the getview(), bet there is no loop. Can someone explain me please?

Class contenthandler goes also through an xml list? How it is possible without loop?

Was it helpful?

Solution

As i know, there's no loop for you. ListView will check which item should be displayed and then getView by position. In getView you create the item view at position.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top