search

package
v1.72.0 Latest Latest
Warning

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

Go to latest
Published: Oct 23, 2018 License: AGPL-3.0 Imports: 14 Imported by: 29

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FilterCategoryProtected added in v1.65.4

func FilterCategoryProtected(results []sm.QueryResult, cats []category.Category, members []category.Member) (filtered []sm.QueryResult)

FilterCategoryProtected removes search results that cannot be seen by user due to document cateogory viewing permissions.

Types

type Indexer

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

Indexer documents!

func NewIndexer

func NewIndexer(rt *env.Runtime, s *store.Store) (i Indexer)

NewIndexer provides background search indexer

func (*Indexer) DeleteContent added in v1.52.0

func (m *Indexer) DeleteContent(ctx domain.RequestContext, pageID string)

DeleteContent removes all search entries for specific document content.

func (*Indexer) DeleteDocument

func (m *Indexer) DeleteDocument(ctx domain.RequestContext, ID string)

DeleteDocument removes all search entries for document.

func (*Indexer) IndexContent added in v1.52.0

func (m *Indexer) IndexContent(ctx domain.RequestContext, p page.Page)

IndexContent adds search index entry for document context. Any existing document entries are removed.

func (*Indexer) IndexDocument added in v1.52.0

func (m *Indexer) IndexDocument(ctx domain.RequestContext, d doc.Document, a []attachment.Attachment)

IndexDocument adds search indesd entries for document inserting title, tags and attachments as searchable items. Any existing document entries are removed.

type Store added in v1.71.0

type Store struct {
	store.Context
	store.SearchStorer
}

Store provides data access to space information.

func (Store) DeleteContent added in v1.71.0

func (s Store) DeleteContent(ctx domain.RequestContext, pageID string) (err error)

DeleteContent removes all search entries for specific document content.

func (Store) DeleteDocument added in v1.71.0

func (s Store) DeleteDocument(ctx domain.RequestContext, ID string) (err error)

DeleteDocument removes all search entries for document.

func (Store) Documents added in v1.71.0

func (s Store) Documents(ctx domain.RequestContext, q search.QueryOptions) (results []search.QueryResult, err error)

Documents searches the documents that the client is allowed to see, using the keywords search string, then audits that search. Visible documents include both those in the client's own organization and those that are public, or whose visibility includes the client.

func (Store) IndexContent added in v1.71.0

func (s Store) IndexContent(ctx domain.RequestContext, p page.Page) (err error)

IndexContent adds search index entry for document context. Any existing document entries are removed.

func (Store) IndexDocument added in v1.71.0

func (s Store) IndexDocument(ctx domain.RequestContext, doc doc.Document, a []attachment.Attachment) (err error)

IndexDocument adds search index entries for document inserting title, tags and attachments as searchable items. Any existing document entries are removed.

Jump to

Keyboard shortcuts

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