@@ -0,0 +1,2260 @@
+%0Apackage com.thiner.adapter;%0A%0Aimport android.app.Activity;%0Aimport android.content.Context;%0Aimport android.view.LayoutInflater;%0Aimport android.view.View;%0Aimport android.view.ViewGroup;%0Aimport android.widget.ArrayAdapter;%0Aimport android.widget.TextView;%0A%0Aimport com.thiner.R;%0Aimport com.thiner.model.Contact;%0A%0Aimport java.util.ArrayList;%0A%0Apublic class ContactAdapter extends ArrayAdapter%3CContact%3E %7B%0A%0A    private final Context mContext;%0A    private final int mLayoutResourceId;%0A    private final ArrayList%3CContact%3E mList;%0A%0A    public ContactAdapter(final Context context, final int layoutResourceId,%0A            final ArrayList%3CContact%3E mListPersons) %7B%0A        super(context, layoutResourceId, mListPersons);%0A%0A        mContext = context;%0A        mLayoutResourceId = layoutResourceId;%0A        mList = mListPersons;%0A    %7D%0A%0A    @Override%0A    public View getView(final int position, final View convertView, final ViewGroup parent) %7B%0A%0A        View row = convertView;%0A%0A        ContactHolder holder = null;%0A%0A        if (row == null) %7B%0A%0A            final LayoutInflater inflater = ((Activity) mContext).getLayoutInflater();%0A            row = inflater.inflate(mLayoutResourceId, parent, false);%0A%0A            holder = new ContactnHolder();%0A%0A            View view = row.findViewById(R.id.txtDDD);%0A            if (view instanceof TextView) %7B%0A                holder.txtDDD = (TextView) view;%0A            %7D%0A%0A            view = row.findViewById(R.id.txtNumber);%0A            if (view instanceof TextView) %7B%0A                holder.txtNumber = (TextView) view;%0A            %7D%0A%0A            view = row.findViewById(R.id.txtOperadora);%0A            if (view instanceof TextView) %7B%0A                holder.txtOperadora = (TextView) view;%0A            %7D%0A%0A            row.setTag(holder);%0A        %7D else %7B%0A            holder = (ContactHolder) row.getTag();%0A        %7D%0A%0A        final Contact contact = mList.get(position);%0A%0A        holder.txtDDD.setText(contact.getDDD());%0A        holder.txtNumber.setText(contact.getNumber());%0A        holder.txtOperadora.setText(contact.getOperadora());%0A%0A        return row;%0A%0A    %7D%0A%0A    /**%0A     * The Class PlayerHolder.%0A     */%0A    static class ContactHolder %7B%0A%0A        TextView txtDDD;%0A%0A        TextView txtNumber;%0A%0A        TextView txtOperadora;%0A%0A    %7D%0A%7D%0A

Add ContactAdapter