Back to project page SQLite-Simple-Android.
The source code is released under:
Apache License
If you think the Android project SQLite-Simple-Android listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package garin.artemiy.sqlitesimple.example.adapters; //from ww w.j a v a 2s . c om import android.annotation.SuppressLint; import android.content.Context; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.ArrayAdapter; import android.widget.TextView; import garin.artemiy.sqlitesimple.R; import garin.artemiy.sqlitesimple.example.models.Record; /** * Author: Artemiy Garin * Date: 07.04.13 */ @SuppressWarnings("CanBeFinal") public class RecordAdapter extends ArrayAdapter<Record> { public RecordAdapter(Context context) { super(context, R.layout.item_record); } @SuppressLint("InflateParams") @Override public View getView(int position, View convertView, ViewGroup parent) { if (convertView == null) convertView = LayoutInflater.from(getContext()).inflate(R.layout.item_record, null); Record record = getItem(position); TextView recordText = (TextView) convertView.findViewById(R.id.recordTextView); recordText.setText(record.getRecordText()); return convertView; } }