package tech.starwin.mvp.ui.adapter;

import android.content.Context;
import android.widget.TextView;

import java.util.List;

import tech.starwin.R;
import tech.starwin.base.BaseRecyclerAdapter;
import tech.starwin.base.RecyclerViewHolder;
import tech.starwin.mvp.beans.RegionBean;

/**
 * Created by SiKang on 2018/10/15.
 */
public class RegionAdapter extends BaseRecyclerAdapter<RegionBean.RegionsBean> {
    public RegionAdapter(Context ctx, List<RegionBean.RegionsBean> list) {
        super(ctx, list);
    }

    @Override
    public Object bindItemLayout() {
        return R.layout.item_of_regions;
    }

    @Override
    public void bindData(RecyclerViewHolder holder, int position, RegionBean.RegionsBean item) {
        holder.getTextView(R.id.item_of_regions_regionName_tv).setText(item.getName());
    }
}
