Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Factory ¶
type Factory interface { // New creates a new query matcher. New(doc interface{}) (Matcher, error) // Map maps a document for the matcher. Map(doc interface{}) (interface{}, error) }
Factory represents a matcher factory
func NewIndexMatcherFactory ¶
func NewIndexMatcherFactory(m mapping.IndexMapping) Factory
NewIndexMatcherFactory creates a new IndexMatcherFactory.
func NewParallelMatcherFactory ¶
NewParallelMatcherFactory creates a new ParallelMatcherFactory.
type IndexMatcher ¶
type IndexMatcher struct {
// contains filtered or unexported fields
}
IndexMatcher represents a bleve index matcher.
func (*IndexMatcher) Finish ¶
func (m *IndexMatcher) Finish() (ids []string, errs []error)
Finish closes the matcher and returns the match results.
type IndexMatcherFactory ¶
type IndexMatcherFactory struct {
// contains filtered or unexported fields
}
IndexMatcherFactory represents a factory for IndexMatcher.
func (IndexMatcherFactory) Map ¶
func (f IndexMatcherFactory) Map(doc interface{}) (interface{}, error)
Map maps a document for the matcher.
func (IndexMatcherFactory) New ¶
func (f IndexMatcherFactory) New(doc interface{}) (Matcher, error)
New creates a new query matcher.
type Matcher ¶
type Matcher interface { // Match matches a query with the matcher. Match(id string, q query.Query) // Finish closes the matcher and returns the match results. Finish() (ids []string, errs []error) }
Matcher represents a query matcher
type ParallelMatcher ¶
type ParallelMatcher struct {
// contains filtered or unexported fields
}
ParallelMatcher represents a threaded matcher.
func (*ParallelMatcher) Finish ¶
func (m *ParallelMatcher) Finish() (ids []string, errs []error)
Finish closes the matcher and returns the match results.
type ParallelMatcherFactory ¶
type ParallelMatcherFactory struct {
// contains filtered or unexported fields
}
ParallelMatcherFactory represents a factory for ParallelMatcher.
func (ParallelMatcherFactory) Map ¶
func (f ParallelMatcherFactory) Map(doc interface{}) (interface{}, error)
Map maps a document for the matcher.
func (ParallelMatcherFactory) New ¶
func (f ParallelMatcherFactory) New(doc interface{}) (Matcher, error)
New creates a new query matcher.