You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@lucene.apache.org by GitBox <gi...@apache.org> on 2022/05/05 01:17:39 UTC

[GitHub] [lucene] mocobeta commented on a diff in pull request #867: LUCENE-10558: expose stream-based Kuromoji resource constructors

mocobeta commented on code in PR #867:
URL: https://github.com/apache/lucene/pull/867#discussion_r865500952


##########
lucene/analysis/kuromoji/src/java/org/apache/lucene/analysis/ja/dict/UnknownDictionary.java:
##########
@@ -52,18 +52,26 @@ private UnknownDictionary() throws IOException {
         () -> getClassResource(DICT_FILENAME_SUFFIX));
   }
 
-  private UnknownDictionary(
-      IOSupplier<InputStream> targetMapResource,
-      IOSupplier<InputStream> posResource,
-      IOSupplier<InputStream> dictResource)
+  /**
+   * Create a {@link UnknownDictionary} from an external resource path.
+   *
+   * @param targetMap supplier for stream containing target map
+   * @param posDict supplier for stream containing POS dictionary
+   * @param dict supplier for stream containing dictionary entries
+   * @throws IOException if a stream could not be read
+   */
+  public UnknownDictionary(
+      IOSupplier<InputStream> targetMap,
+      IOSupplier<InputStream> posDict,
+      IOSupplier<InputStream> dict)

Review Comment:
   Could you explain why the parameter names should be changed? It's now inconsistent with other constructors (e.g. TokenInfoDictionary).



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For additional commands, e-mail: issues-help@lucene.apache.org