Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MakeAll ¶
Make a searcher for each repo in the Config. This function kind of has a notion of partial errors. First, if the error returned is non-nil then a fatal error has occurred and no other return values are valid. If an error occurs that is specific to a particular searcher, that searcher will not be present in the searcher map and will have an error entry in the error map.
Types ¶
type Searcher ¶
func New ¶
Creates a new Searcher that is available for searches as soon as this returns. This will pull or clone the target repo and start watching the repo for changes.
func (*Searcher) GetExcludedFiles ¶
Get the excluded files as a JSON string. This is only used for returning the data directly to clients (thus JSON).
func (*Searcher) Search ¶
func (s *Searcher) Search(pat string, opt *index.SearchOptions) (*index.SearchResponse, error)
Perform a basic search on the current index using the supplied pattern and the options.
TODO(knorton): pat should really just be a part of SearchOptions
func (*Searcher) Stop ¶
func (s *Searcher) Stop()
Shut down the searcher cleanly, waiting for any indexing operations to complete.