class_docstr: Matches documents containing a given phrase.
code: def matcher(self, searcher, context=None):
      from whoosh.query import Term, SpanNear2
  
      fieldname = self.fieldname
      if fieldname not in searcher.schema:
          return matching.NullMatcher()
  
      field = searcher.schema[fieldname]
      if not field.format or not field.format.supports("positions"):
          raise qcore.QueryError(
              "Phrase search: %r field has no positions"
              % self.fieldname
          )
  
      terms = []
      # Build a list of Term queries from the words in the phrase
      reader = searcher.reader()
      for word in self.words:
          try:
              word = field.to_bytes(word)
          except ValueError:
              return matching.NullMatcher()
  
          if (fieldname, word) not in reader:
              # Shortcut the query if one of the words doesn't exist.
              return matching.NullMatcher()
          terms.append(Term(fieldname, word))
  
      # Create the equivalent SpanNear2 query from the terms
      q = SpanNear2(terms, slop=self.slop, ordered=True, mindist=1)
      # Get the matcher
      m = q.matcher(searcher, context)
  
      if self.boost != 1.0:
          m = matching.WrappingMatcher(m, boost=self.boost)
      return m
  
imports: from __future__ import division
  import copy
  from whoosh import matching
  from whoosh.analysis import Token
  from whoosh.compat import u
  from whoosh.query import qcore, terms, compound
label_desc: Use image node_id 14 for calling the Phrase obj's underlying member method code with example usage: obj.matcher(searcher, context) and returns: m, matching, matching, matching