package com.android.jingdong.adaptor;

import com.android.jingdong.model.JD;
import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.viewholder.BaseViewHolder;
import com.android.jingdong.R;

import org.jetbrains.annotations.NotNull;

import java.util.List;

public class HomeAdapter extends BaseQuickAdapter<JD, BaseViewHolder> {

    public HomeAdapter(List<JD> JDS) {
        super(R.layout.item_home_snack, JDS);
    }

    @Override
    protected void convert(@NotNull BaseViewHolder baseViewHolder, JD JD) {
        baseViewHolder.setImageResource(R.id.homeSnackImage, JD.getImage());
    }
}
