PhraseMatcher

abstract class PhraseMatcher

Base class for exact and sloppy phrase matching

To find matches on a document, first advance .approximation to the relevant document, then call .reset. Clients can then call .nextMatch to iterate over the matches

Inheritors

Properties

Link copied to clipboard

An estimate of the average cost of finding all matches on a document

Functions

Link copied to clipboard

Approximation that only matches documents that have all terms.

Link copied to clipboard
abstract fun endOffset(): Int

The end offset of the current match

Link copied to clipboard
abstract fun endPosition(): Int

The end position of the current match

Link copied to clipboard

Approximation that is aware of impacts.

Link copied to clipboard
abstract fun maxFreq(): Float

An upper bound on the number of possible matches on this document

Link copied to clipboard
abstract fun nextMatch(): Boolean

Find the next match on the current document, returning false if there are none.

Link copied to clipboard
abstract fun reset()

Called after .approximation has been advanced

Link copied to clipboard
abstract fun sloppyWeight(): Float

The slop-adjusted weight of the current match

Link copied to clipboard
abstract fun startOffset(): Int

The start offset of the current match

Link copied to clipboard
abstract fun startPosition(): Int

The start position of the current match