I don't understand, why does the following code create 2 phrase queries instead of 20 term queries? I'm quite sure I've previously had QueryParser doing the latter.

System.out.println(new QueryParser("f", new Analyzer() {
  public TokenStream tokenStream(String string, Reader reader) {
    return new NGramTokenFilter(new StandardTokenizer(reader), 2, 5);
  }
}).parse("hello world"));


f:"he el ll lo hel ell llo hell ello hello" f:"wo or rl ld wor orl rld worl orld world"


--
karl

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to