termdict

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Aug 11, 2022 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ReadPerFieldTermDict

func ReadPerFieldTermDict(termdictFile *directory.FileSlice) (map[schema.FieldID]TermDict, error)

Types

type Range

type Range struct {
	From int
	To   int
}

func (Range) Len

func (r Range) Len() int

type TermDict

type TermDict map[string]*TermInfo

type TermInfo

type TermInfo struct {
	Term          string
	DocFreq       int
	PostingsRange Range
}

type TermWriter

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

func NewTermWriter

func NewTermWriter(termDictFile directory.WriteCloseSyncer) *TermWriter

func (*TermWriter) AddTermInfo

func (t *TermWriter) AddTermInfo(fieldID schema.FieldID, termInfo *TermInfo)

func (*TermWriter) Close

func (t *TermWriter) Close() error

func (*TermWriter) Serialize

func (t *TermWriter) Serialize() error

Jump to

Keyboard shortcuts

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