Return-Path: Delivered-To: apmail-lucene-java-user-archive@www.apache.org Received: (qmail 27560 invoked from network); 11 Oct 2007 18:43:48 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 11 Oct 2007 18:43:48 -0000 Received: (qmail 67831 invoked by uid 500); 11 Oct 2007 18:43:29 -0000 Delivered-To: apmail-lucene-java-user-archive@lucene.apache.org Received: (qmail 67804 invoked by uid 500); 11 Oct 2007 18:43:29 -0000 Mailing-List: contact java-user-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: java-user@lucene.apache.org Delivered-To: mailing list java-user@lucene.apache.org Received: (qmail 67793 invoked by uid 99); 11 Oct 2007 18:43:29 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 11 Oct 2007 11:43:29 -0700 X-ASF-Spam-Status: No, hits=0.2 required=10.0 tests=RCVD_IN_DNSWL_LOW,SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (athena.apache.org: 80.76.149.213 is neither permitted nor denied by domain of karl.wettin@gmail.com) Received: from [80.76.149.213] (HELO ch-smtp02.sth.basefarm.net) (80.76.149.213) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 11 Oct 2007 18:43:32 +0000 Received: from c83-249-118-113.bredband.comhem.se ([83.249.118.113]:65088 helo=[192.168.1.101]) by ch-smtp02.sth.basefarm.net with esmtp (Exim 4.68) (envelope-from ) id 1Ig2wz-0000sJ-8m for java-user@lucene.apache.org; Thu, 11 Oct 2007 20:40:01 +0200 Mime-Version: 1.0 (Apple Message framework v752.3) In-Reply-To: <8E95A8CA-9187-4761-87AF-477725D75DAF@gmail.com> References: <8E95A8CA-9187-4761-87AF-477725D75DAF@gmail.com> Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: <50BD1C80-481D-468F-A785-247B32D26A7A@gmail.com> Content-Transfer-Encoding: 7bit From: Karl Wettin Subject: Re: QueryParser and NGrams Date: Thu, 11 Oct 2007 20:40:00 +0200 To: java-user@lucene.apache.org X-Mailer: Apple Mail (2.752.3) X-Originating-IP: 83.249.118.113 X-Scan-Result: No virus found in message 1Ig2wz-0000sJ-8m. X-Scan-Signature: ch-smtp02.sth.basefarm.net 1Ig2wz-0000sJ-8m 42668d46fa9181c8e51d1682a3106fbb X-Virus-Checked: Checked by ClamAV on apache.org I now realize that that phrase makes sense, and that it was another "feature" in my code that confused me. So, forget about it. Bada bing, bada bom. -- karl 11 okt 2007 kl. 19.47 skrev Karl Wettin: > 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: java-user-unsubscribe@lucene.apache.org > For additional commands, e-mail: java-user-help@lucene.apache.org > --------------------------------------------------------------------- To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org For additional commands, e-mail: java-user-help@lucene.apache.org