uschindler commented on a change in pull request #482:
URL: https://github.com/apache/lucene/pull/482#discussion_r757797871
##########
File path:
lucene/luke/src/java/org/apache/lucene/luke/models/analysis/AnalysisImpl.java
##########
@@ -154,7 +158,12 @@ public Analyzer createAnalyzerFromClassName(String
analyzerType) {
private Analyzer defaultAnalyzer() {
try {
- return CustomAnalyzer.builder().withTokenizer("standard").build();
+ Map<String, String> params = new HashMap<>();
+ params.put("maxTokenLength",
Integer.toString(StandardAnalyzer.DEFAULT_MAX_TOKEN_LENGTH));
+ return CustomAnalyzer.builder()
+ .withTokenizer(StandardTokenizerFactory.NAME, params)
Review comment:
Here's a quite complex example by Robert. Please also note the recommend
formatting:
https://github.com/uschindler/german-decompounder#lucene-api-example
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]