MCPcopy Index your code
hub / github.com/django-haystack/django-haystack / highlight

Method highlight

haystack/query.py:360–364  ·  view source on GitHub ↗

Adds highlighting to the results.

(self, **kwargs)

Source from the content-addressed store, hash-verified

358 return clone
359
360 def highlight(self, **kwargs):
361 """Adds highlighting to the results."""
362 clone = self._clone()
363 clone.query.add_highlight(**kwargs)
364 return clone
365
366 def models(self, *models):
367 """Accepts an arbitrary number of Model classes to include in the search."""

Callers 6

searchMethod · 0.45
searchMethod · 0.45
test_highlightMethod · 0.45
test_highlightMethod · 0.45
test_highlightMethod · 0.45

Calls 2

_cloneMethod · 0.95
add_highlightMethod · 0.80

Tested by 4

test_highlightMethod · 0.36
test_highlightMethod · 0.36
test_highlightMethod · 0.36