Clover Coverage Report - Main Coverage Report
Coverage timestamp: ven dic 19 2014 16:47:52 EST
../../../../../img/srcFileCovDistChart0.png 84% of files have more coverage
16   50   9   3,2
8   41   0,56   5
5     1,8  
1    
This report was generated with an evaluation server license. Purchase Clover or configure your license.
 
  SettingListAdapter       Line # 11 16 9 0% 0.0
 
No Tests
 
1    package com.dreamcatcher.bicycle.view.settinglistview;
2   
3    import java.util.ArrayList;
4   
5    import android.view.View;
6    import android.view.ViewGroup;
7    import android.widget.BaseAdapter;
8   
9    import com.dreamcatcher.bicycle.R;
10   
 
11    public class SettingListAdapter extends BaseAdapter {
12    ArrayList<View> mArrayList = null;
13   
 
14  0 toggle public SettingListAdapter(ArrayList<View> arrayList){
15  0 mArrayList = arrayList;
16    }
17   
 
18  0 toggle public int getCount() {
19  0 return mArrayList.size();
20    }
21   
 
22  0 toggle public Object getItem(int position) {
23  0 return mArrayList.get(position);
24    }
25   
 
26  0 toggle public long getItemId(int position) {
27  0 return 0;
28    }
29   
 
30  0 toggle public View getView(int position, View convertView, ViewGroup parent) {
31  0 View view = null;
32  0 if(convertView == null){
33  0 view = mArrayList.get(position);
34  0 if(mArrayList.size() > 1){
35  0 if(position == 0){
36  0 view.setBackgroundResource(R.drawable.setting_listitem_bg_top);
37  0 }else if(position < mArrayList.size() -1){
38  0 view.setBackgroundResource(R.drawable.setting_listitem_bg_middle);
39    }else {
40  0 view.setBackgroundResource(R.drawable.setting_listitem_bg_bottom);
41    }
42    }else {
43  0 view.setBackgroundResource(R.drawable.setting_listitem_bg_whole);
44    }
45    }else {
46  0 view = convertView;
47    }
48  0 return view;
49    }
50    }