package org.jeecg.modules.database.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import org.jeecg.modules.database.entity.Experiment;
import org.jeecg.modules.database.entity.SearchResult;

import java.util.List;

public interface IComponentSearchService extends IService<SearchResult> {

    IPage<SearchResult> queryPageList(Integer type, String content, Integer pageNo, Integer pageSize);
    List<SearchResult> search(Integer type, String content);
    void saveDataAfterSaveExperiment(Experiment experiment);

    boolean saveComponentSearch(SearchResult searchResult);

    /**
     * 根据类型保存搜索记录
     * @param type 数据类型
     * @param content 数据内容
     * @return 保存结果 是否保存成功
     */
    boolean saveComponentSearchByType(int type, String content);
}
