shikeying
2024-01-11 3b67e947e36133e2a40eb2737b15ea375e157ea0
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
package com.walker.support.es;
 
import java.util.List;
 
/**
 * 描述:全文检索服务接口规范定义
 * @author 时克英
 * @date 2020年7月4日 上午11:11:21
 */
@Deprecated
public interface SearchService {
 
    Object createAttachmentProcessor(String description);
 
    /**
     * 创建一个索引(库),如果已存在则返回<code>false</code>
     * @param name 索引名字
     * @param type 类型,为空则系统默认为值:table。【该字段废弃】
     * @return
     */
    boolean createIndex(String name, String type, String json);
 
    boolean existIndex(String name, String type) throws Exception;
 
    String search(String index, String queryText, int dataSecurity, String securityInfo, int pageIndex, int pageSize) throws Exception;
 
    String searchDataById(String index, String _id) throws Exception;
 
    /**
     * 只加载一个文件数据
     * @param index
     * @param _id
     * @return
     * @throws Exception
     */
    @Deprecated
    String searchFileById(String index, String _id) throws Exception;
 
    /**
     * 查询最近搜索关联集合
     * @param index
     * @param keyWord
     * @return
     * @throws Exception
     */
    List<String> searchRecent(String index, String keyWord) throws Exception;
 
    void putContent(String index, List<SaveData> datas) throws Exception;
 
    void removeIndex(String index) throws Exception;
 
    List<String> getKeyWordList(String index, String _id, String field) throws Exception;
 
    /**
     * 设置分词方式:ik_max_word | ik_smart,默认ik_max_word</p>
     * <pre>
     * 1. Constants.TOKEN_TYPE_MAX
     * 2. Constants.TOKEN_TYPE_SMART
     * </pre>
     * @param tokenType
     */
    void setTokenType(String tokenType);
 
    /**
     * 自动检测附件pipeline,如果不存在则创建,一般名字定义为:attachment
     * @param pipeline
     * @return
     * @throws Exception
     * @author 时克英
     * @date 2020-08-25
     */
    boolean autoCreatePipelineAttachment(String pipeline) throws Exception;
}