indexer

package
v0.0.0-...-5e73d17 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 24, 2016 License: GPL-2.0 Imports: 5 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type KeywordIndices

type KeywordIndices struct {
	// contains filtered or unexported fields
}

反向索引表的一行,收集了一个搜索键出现的所有文档, 按照DocId从小到大排序。

type WuKongIndexer

type WuKongIndexer struct {
	// contains filtered or unexported fields
}

悟空索引器

func NewWuKongIndexer

func NewWuKongIndexer() *WuKongIndexer

func (*WuKongIndexer) AddDocument

func (self *WuKongIndexer) AddDocument(document *search.DocumentIndex)

向反向索引表中加入一个文档

func (*WuKongIndexer) Init

func (self *WuKongIndexer) Init(options search.IndexerInitOptions)

初始化索引器

func (*WuKongIndexer) Lookup

func (self *WuKongIndexer) Lookup(
	tokens []string, labels []string, docIds []uint64) (docs []search.IndexedDocument)

查找包含全部搜索键(AND操作)的文档 当docIds不为nil时仅从docIds指定的文档中查找

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL