searcher

package
v0.0.0-...-98a29f8 Latest Latest
Warning

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

Go to latest
Published: Sep 19, 2024 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Container

type Container struct {
	Dir string           //文件夹
	Neg *negative.Engine //负向索引

	Debug     bool             //调试
	AllowDrop bool             //允许删除
	Tokenizer *words.Tokenizer //分词器
	Shard     int              //分片
	Timeout   int64            //超时关闭数据库
	BufferNum int              //分片缓冲数
	// contains filtered or unexported fields
}

func (*Container) CheckDataBase

func (c *Container) CheckDataBase(key string) bool

func (*Container) DropDataBase

func (c *Container) DropDataBase(name string) error

DropDataBase 删除数据库

func (*Container) GetDataBase

func (c *Container) GetDataBase(name string) *Engine

GetDataBase 获取或创建引擎

func (*Container) GetDataBaseNumber

func (c *Container) GetDataBaseNumber() int

func (*Container) GetDataBases

func (c *Container) GetDataBases() map[string]*Engine

GetDataBases 获取数据库列表

func (*Container) GetDocumentCount

func (c *Container) GetDocumentCount() int64

func (*Container) GetIndexCount

func (c *Container) GetIndexCount() int64

func (*Container) Init

func (c *Container) Init() error

func (*Container) NewEngine

func (c *Container) NewEngine(name string) *Engine

NewEngine 创建一个引擎

type Engine

type Engine struct {
	index.Engine
}

func (*Engine) MultiSearch

func (e *Engine) MultiSearch(request *model.SearchRequest) (any, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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