【文件属性】:
文件名称:learn-lucene:lucene学习
文件大小:36KB
文件格式:ZIP
更新时间:2021-07-03 06:54:31
Java
lucene_learn
lucene学习
day_01:
索引创建的步骤:
创建directory
创建IndexWriter
创建Document
为Document添加Field
通过IdexUriter添加文档到索引中
搜索的步骤:
创建directory
创建IndexReader
根据IndexReader创建IndexSearcher
创建Query
根据searcher搜索并返回对象TopDocs
根据TopDocs获取ScoreDoc
根据searcher和ScoreDoc获取具体的document
根据document获取需要的值
day_02:
索引创建的一些特性
Field.Store.* [存储域选项]
YES,表示会把这个域中的内容完全存储在索引文件中,方便进行文本的还原
NO,表示这个域的内容不存储在索引文件中,但是可以被索引,此时内容无法进行还原(doc.
【文件预览】:
learn-lucene-master
----pom.xml(816B)
----.settings()
--------org.eclipse.m2e.core.prefs(86B)
--------org.eclipse.wst.jsdt.ui.superType.name(6B)
--------org.eclipse.wst.common.project.facet.core.xml(245B)
--------org.eclipse.wst.common.component(667B)
--------org.eclipse.wst.jsdt.ui.superType.container(49B)
--------org.eclipse.wst.validation.prefs(48B)
--------.jsdtscope(496B)
--------org.eclipse.jdt.core.prefs(422B)
----src()
--------test()
--------main()
----.project(1KB)
----.classpath(1KB)
----.gitignore(8B)
----home()
--------anduo()
----indexes()
--------_0.tis(7KB)
--------segments.gen(20B)
--------_0.fdt(176B)
--------_0.nrm(13B)
--------_0.fnm(31B)
--------_0.tii(121B)
--------segments_1(248B)
--------_0.prx(3KB)
--------_0.fdx(28B)
--------_0.frq(1KB)
----README.md(2KB)
----files()
--------README.txt(2KB)
--------NOTICE(182B)
--------LICENSE(18KB)