index

package
v1.8.1 Latest Latest
Warning

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

Go to latest
Published: Nov 2, 2024 License: AGPL-3.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddInIndex

func AddInIndex(gist *Gist) error

func Close

func Close()

func Enabled

func Enabled() bool

func Init added in v1.7.4

func Init(indexFilename string)

func RemoveFromIndex

func RemoveFromIndex(gistID uint) error

func SearchGists

func SearchGists(queryStr string, queryMetadata SearchGistMetadata, gistsIds []uint, page int) ([]uint, uint64, map[string]int, error)

Types

type Gist

type Gist struct {
	GistID     uint
	Username   string
	Title      string
	Content    string
	Filenames  []string
	Extensions []string
	Languages  []string
	CreatedAt  int64
	UpdatedAt  int64
}

type Indexer added in v1.7.4

type Indexer struct {
	Index bleve.Index
}

type SearchGistMetadata

type SearchGistMetadata struct {
	Username  string
	Title     string
	Filename  string
	Extension string
	Language  string
}

Jump to

Keyboard shortcuts

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