Java tutorial
//package com.java2s; //License from project: Open Source License import android.content.Context; import android.widget.ArrayAdapter; import android.widget.ListView; import java.util.List; public class Main { public static void fillList(Context context, ListView lv, List<String> ls) { ArrayAdapter<String> adapter = new ArrayAdapter<>(context, android.R.layout.simple_list_item_1, ls); lv.setAdapter(adapter); } }