庖丁解牛 lucene3.0.2兼容问题

 

http://code.google.com/p/paoding/issues/detail?id=49

 

 

 

 

Reported by project member reno.gan, Dec 03, 2009
lucene 3.0 去掉了一些废弃的方法,如tokenStream.next()方法。为了让Paoding能
够在lucene 3.0环境运行,我改动了附件中的三个文件,主要是为了兼容新的
tokenStream.incrementToken()接口。
PaodingTokenizer.java
5.7 KB   View   Download
TokenCollector.java
1004 bytes   View   Download
Estimate.java
5.1 KB   View   Download
Comment 1 by [email protected], Jul 08, 2010
请问能标明你改动了哪些地方吗?
Comment 2 by [email protected], Jul 08, 2010
我现在的版本是lucene3.0.2,加入这三个文件依然报:
Exception in thread "main" java.lang.NullPointerException
	at net.paoding.analysis.analyzer.PaodingTokenizer.close(PaodingTokenizer.java:164)
	at org.apache.lucene.queryParser.QueryParser.getFieldQuery(QueryParser.java:571)
	at org.apache.lucene.queryParser.QueryParser.Term(QueryParser.java:1362)
	at org.apache.lucene.queryParser.QueryParser.Clause(QueryParser.java:1250)
	at org.apache.lucene.queryParser.QueryParser.Query(QueryParser.java:1178)
	at org.apache.lucene.queryParser.QueryParser.TopLevelQuery(QueryParser.java:1167)
	at org.apache.lucene.queryParser.QueryParser.parse(QueryParser.java:182)
	at test.TestBoBo.main(TestBoBo.java:44)
Comment 3 by hjbin333, Jul 13, 2010
把paoding的PaodingTokenizer类的164行注释掉,就不会报错,已经在lucene3.0.2试过
		super.close();
//		input.close();//这句导致报错

 

-

 

 

http://code.google.com/p/paoding/issues/detail?id=49

你可能感兴趣的:(java,apache,.net,Google,Lucene)