You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by mi...@apache.org on 2020/06/10 16:38:02 UTC

[lucene-solr] branch master updated: LUCENE-9392: make FacetsConfig.DELIM_CHAR public

This is an automated email from the ASF dual-hosted git repository.

mikemccand pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/lucene-solr.git


The following commit(s) were added to refs/heads/master by this push:
     new 138cdd7  LUCENE-9392: make FacetsConfig.DELIM_CHAR public
138cdd7 is described below

commit 138cdd758a02522ec965e9323b30e0359b986508
Author: Mike McCandless <mi...@apache.org>
AuthorDate: Wed Jun 10 12:37:04 2020 -0400

    LUCENE-9392: make FacetsConfig.DELIM_CHAR public
---
 lucene/CHANGES.txt                                            |  2 ++
 .../facet/src/java/org/apache/lucene/facet/FacetsConfig.java  | 11 +++++++++--
 2 files changed, 11 insertions(+), 2 deletions(-)

diff --git a/lucene/CHANGES.txt b/lucene/CHANGES.txt
index baa1c33..4759341 100644
--- a/lucene/CHANGES.txt
+++ b/lucene/CHANGES.txt
@@ -204,6 +204,8 @@ Improvements
 * LUCENE-9393: Make FunctionScoreQuery use ScoreMode.COMPLETE for creating the inner query weight when
   ScoreMode.TOP_DOCS is requested. (Tomás Fernández Löbbe)
 
+* LUCENE-9392: Make FacetsConfig.DELIM_CHAR publicly accessible (Ankur Goel))
+
 Optimizations
 ---------------------
 
diff --git a/lucene/facet/src/java/org/apache/lucene/facet/FacetsConfig.java b/lucene/facet/src/java/org/apache/lucene/facet/FacetsConfig.java
index f958af1..84f69d7 100644
--- a/lucene/facet/src/java/org/apache/lucene/facet/FacetsConfig.java
+++ b/lucene/facet/src/java/org/apache/lucene/facet/FacetsConfig.java
@@ -496,8 +496,15 @@ public class FacetsConfig {
     }
   }
 
-  // Joins the path components together:
-  private static final char DELIM_CHAR = '\u001F';
+  /**
+   * Character used to join the category path components together into a single
+   * drill down term for indexing.  Applications and unit-tests can reference this for
+   * creating their own drill-down terms, or use existing APIs (for example,
+   * {@link #pathToString}).
+   *
+   * @lucene.internal
+   */
+  public static final char DELIM_CHAR = '\u001F';
 
   // Escapes any occurrence of the path component inside the label:
   private static final char ESCAPE_CHAR = '\u001E';