Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SameArrayPositions ¶
Types ¶
type Fragment ¶
type FragmentFormatter ¶
type FragmentFormatter interface {
Format(f *Fragment, orderedTermLocations TermLocations) string
}
type FragmentScorer ¶
type Fragmenter ¶
type Fragmenter interface {
Fragment([]byte, TermLocations) []*Fragment
}
type Highlighter ¶
type Highlighter interface { Fragmenter() Fragmenter SetFragmenter(Fragmenter) FragmentFormatter() FragmentFormatter SetFragmentFormatter(FragmentFormatter) Separator() string SetSeparator(string) BestFragmentInField(*search.DocumentMatch, *document.Document, string) string BestFragmentsInField(*search.DocumentMatch, *document.Document, string, int) []string }
type TermLocation ¶
func (*TermLocation) Overlaps ¶
func (tl *TermLocation) Overlaps(other *TermLocation) bool
type TermLocations ¶
type TermLocations []*TermLocation
func OrderTermLocations ¶
func OrderTermLocations(tlm search.TermLocationMap) TermLocations
func (TermLocations) Len ¶
func (t TermLocations) Len() int
func (TermLocations) Less ¶
func (t TermLocations) Less(i, j int) bool
func (TermLocations) MergeOverlapping ¶
func (t TermLocations) MergeOverlapping()
func (TermLocations) Swap ¶
func (t TermLocations) Swap(i, j int)
Click to show internal directories.
Click to hide internal directories.