Skip to content

Apache Lucene open-source search software

LUCENE-9212: Remove deprecated Intervals.multiterm() methods

Alan Woodward19fe1eee68d8
diff --git a/lucene/CHANGES.txt b/lucene/CHANGES.txt
index 6956eff7b43..8b85e4d9d38 100644
--- a/lucene/CHANGES.txt
+++ b/lucene/CHANGES.txt
@@ -41,6 +41,9 @@ API Changes
* LUCENE-9089: FST Builder renamed FSTCompiler with fluent-style Builder.
(Bruno Roustant)
+* LUCENE-9212: Deprecated Intervals.multiterm() methods that take a bare Automaton
+ have been removed (Alan Woodward)
+
Improvements
* LUCENE-8757: When provided with an ExecutorService to run queries across
diff --git a/lucene/queries/src/java/org/apache/lucene/queries/intervals/Intervals.java b/lucene/queries/src/java/org/apache/lucene/queries/intervals/Intervals.java
index 5d835bd0277..8ec9701298c 100644
--- a/lucene/queries/src/java/org/apache/lucene/queries/intervals/Intervals.java
+++ b/lucene/queries/src/java/org/apache/lucene/queries/intervals/Intervals.java
@@ -197,42 +197,7 @@ public final class Intervals {
}
/**
- * Expert: Return an {@link IntervalsSource} over the disjunction of all terms that's accepted by the given automaton
- *
- * @param automaton accepts terms for to expand to
- * @param pattern string representation of the given automaton, mostly used in exception messages
- *
- * @throws IllegalStateException if the automaton accepts more than 128 terms
- *
- * @deprecated use {@link #multiterm(CompiledAutomaton, String)}
- */
- @Deprecated
- public static IntervalsSource multiterm(Automaton automaton, String pattern) {
- return multiterm(automaton, 128, pattern);
- }
-
- /**
- * Expert: Return an {@link IntervalsSource} over the disjunction of all terms that's accepted by the given automaton
- *
- * WARNING: Setting {@code maxExpansions} to higher than the default value of 128
- * can be both slow and memory-intensive
- *
- * @param automaton accepts terms for to expand to
- * @param maxExpansions the maximum number of terms to expand to
- * @param pattern string representation of the given automaton, mostly used in exception messages
- *
- * @throws IllegalStateException if the automaton accepts more than {@code maxExpansions} terms
- *
- * @deprecated use {@link #multiterm(CompiledAutomaton, int, String)}
- */
- @Deprecated
- public static IntervalsSource multiterm(Automaton automaton, int maxExpansions, String pattern) {
- CompiledAutomaton ca = new CompiledAutomaton(automaton);
- return new MultiTermIntervalsSource(ca, maxExpansions, pattern);
- }
-
- /**
- * Expert: Return an {@link IntervalsSource} over the disjunction of all terms that's accepted by the given automaton
+ * Expert: Return an {@link IntervalsSource} over the disjunction of all terms that are accepted by the given automaton
*
* @param ca an automaton accepting matching terms
* @param pattern string representation of the given automaton, mostly used in exception messages
@@ -244,7 +209,7 @@ public final class Intervals {
}
/**
- * Expert: Return an {@link IntervalsSource} over the disjunction of all terms that's accepted by the given automaton
+ * Expert: Return an {@link IntervalsSource} over the disjunction of all terms that are accepted by the given automaton
*
* WARNING: Setting {@code maxExpansions} to higher than the default value of 128
* can be both slow and memory-intensive