range

fun range(lowerTerm: BytesRef?, upperTerm: BytesRef?, includeLower: Boolean, includeUpper: Boolean): IntervalsSource

Return an IntervalsSource over the disjunction of all terms that fall within the given range

Parameters

lowerTerm

The term text at the lower end of the range; can be null to indicate an open-ended range at this end

upperTerm

The term text at the upper end of the range; can be null to indicate an open-ended range at this end

includeLower

If true, the lowerTerm is included in the range

includeUpper

If true, the upperTerm is included in the range

Throws

if the range expands to more than DEFAULT_MAX_EXPANSIONS terms


fun range(lowerTerm: BytesRef?, upperTerm: BytesRef?, includeLower: Boolean, includeUpper: Boolean, maxExpansions: Int): IntervalsSource

Expert: Return an IntervalsSource over the disjunction of all terms that fall within the given range

WARNING: Setting `maxExpansions` to higher than the default value of [DEFAULT_MAX_EXPANSIONS] can be both slow and memory-intensive

Parameters

lowerTerm

The term text at the lower end of the range; can be null to indicate an open-ended range at this end

upperTerm

The term text at the upper end of the range; can be null to indicate an open-ended range at this end

includeLower

If true, the lowerTerm is included in the range

includeUpper

If true, the upperTerm is included in the range

maxExpansions

the maximum number of terms to expand to

Throws

if the wildcard glob expands to more than maxExpansions terms