From 15e3a68ff0ac3e4388b6bbf956d5893558668f32 Mon Sep 17 00:00:00 2001 From: Greg Miller Date: Fri, 26 May 2023 10:03:22 -0700 Subject: [PATCH] fixup rebase --- .../lucene/util/automaton/StringsToAutomaton.java | 15 ++------------- .../util/automaton/TestStringsToAutomaton.java | 2 +- 2 files changed, 3 insertions(+), 14 deletions(-) diff --git a/lucene/core/src/java/org/apache/lucene/util/automaton/StringsToAutomaton.java b/lucene/core/src/java/org/apache/lucene/util/automaton/StringsToAutomaton.java index 4ab20328e2df..6c66dc6fd9ed 100644 --- a/lucene/core/src/java/org/apache/lucene/util/automaton/StringsToAutomaton.java +++ b/lucene/core/src/java/org/apache/lucene/util/automaton/StringsToAutomaton.java @@ -32,11 +32,9 @@ * algorithm described in Incremental Construction * of Minimal Acyclic Finite-State Automata by Daciuk, Mihov, Watson and Watson. This requires * sorted input data, but is very fast (nearly linear with the input size). Also offers the ability - * to directly build a binary {@link Automaton} representation. + * to directly build a binary {@link Automaton} representation. Users should access this + * functionality through {@link Automata} static methods. * - * @see #build(Collection) - * @see #build(Collection, boolean) - * @see #build(BytesRefIterator, boolean) * @see Automata#makeStringUnion(Collection) * @see Automata#makeBinaryStringUnion(Collection) * @see Automata#makeStringUnion(BytesRefIterator) @@ -234,15 +232,6 @@ private Automaton completeAndConvert() { return a.finish(); } - /** - * Build a minimal, deterministic automaton from a sorted list of {@link BytesRef} representing - * strings in UTF-8. These strings must be binary-sorted. Creates an {@link Automaton} with UTF-8 - * codepoints as transition labels. - */ - static Automaton build(Collection input) { - return build(input, false); - } - /** * Build a minimal, deterministic automaton from a sorted list of {@link BytesRef} representing * strings in UTF-8. These strings must be binary-sorted. Creates an {@link Automaton} with either diff --git a/lucene/core/src/test/org/apache/lucene/util/automaton/TestStringsToAutomaton.java b/lucene/core/src/test/org/apache/lucene/util/automaton/TestStringsToAutomaton.java index 09b3730c88fd..f093623c3702 100644 --- a/lucene/core/src/test/org/apache/lucene/util/automaton/TestStringsToAutomaton.java +++ b/lucene/core/src/test/org/apache/lucene/util/automaton/TestStringsToAutomaton.java @@ -102,7 +102,7 @@ public void testLargeTerms() throws Exception { e.getMessage() .startsWith( "This builder doesn't allow terms that are larger than " - + StringsToAutomaton.MAX_TERM_LENGTH + + Automata.MAX_STRING_UNION_TERM_LENGTH + " characters")); byte[] b1k = ArrayUtil.copyOfSubArray(b10k, 0, 1000);