What is the working of setTag and getTag in ViewHolder pattern?

后端 未结 3 1951
闹比i
闹比i 2020-12-13 16:13

I have a simple code snippet for implementing custom listview.

My code is as follows:

WeatherAdapter.java :

public class Wea         


        
3条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2020-12-13 16:35

    But, I do not understand why they are required here...because, we do not have multiple holder objects

    This is where you are wrong - there is one holder per view (aka visible or cached ListView entry).

提交回复
热议问题