package com.wanyue.main.bean;

import com.chad.library.adapter.base.entity.MultiItemEntity;
import com.chad.library.adapter.base.entity.SectionEntity;
import com.wanyue.inside.bean.LecturerBean;
import com.wanyue.inside.bean.ProjectBean;

public class SearchSectionBean extends SectionEntity<Object> implements MultiItemEntity {
    public static final int TYPE_LECTURE=100;

    public boolean isNeedMore;

    public SearchSectionBean(boolean isHeader,boolean isNeedMore, String header) {
        super(isHeader, header);
        this.isNeedMore=isNeedMore;
    }

    public SearchSectionBean(Object o) {
        super(o);
    }

    @Override
    public int getItemType() {
        if(isHeader){
           return SectionProjectBean.TYPE_HEAD;
        }else if(t instanceof LecturerBean){
            return TYPE_LECTURE;
        }else if(t instanceof ProjectBean){
            ProjectBean projectBean= (ProjectBean) t;
            return projectBean.getItemType();
        }
        return SectionProjectBean.TYPE_HEAD;
    }



}
