package dk.thoerup.traininfo; import java.util.List; import android.content.Context; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.BaseAdapter; public class TimetableListAdapter extends BaseAdapter { private List timetable; LayoutInflater inflater; Context context; public TimetableListAdapter(Context context) { super(); this.context = context; inflater = (LayoutInflater)context.getSystemService(Context.LAYOUT_INFLATER_SERVICE); } public void setTimetable(List timetable) { this.timetable = timetable; notifyDataSetChanged(); } @Override public int getCount() { if (timetable != null) return timetable.size(); else return 0; } @Override public Object getItem(int position) { return null; } @Override public long getItemId(int position) { return position; } @Override public View getView(int position, View convertView, ViewGroup parent) { // TODO Auto-generated method stub return null; } }