ant stub-factories: PersianNormalizationFilterFactory, signature cleanup of TrieTokenizerFactory, exclusion rule for SnowballFilter

git-svn-id: https://svn.apache.org/repos/asf/lucene/solr/trunk@812768 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Chris M. Hostetter 2009-09-09 04:41:33 +00:00
parent a9ac376937
commit 042f7c0ba9
3 changed files with 38 additions and 2 deletions

View File

@ -300,6 +300,10 @@
<!-- solr and lucene both have one? ? ? ? -->
<regexp pattern="LengthFilter"/>
</linecontainsregexp>
<linecontainsregexp negate="true">
<!-- solr provides it's own SnowballPorterFilter variant -->
<regexp pattern="SnowballFilter"/>
</linecontainsregexp>
</inputfilterchain>
</redirector>
<arg line="${stub.src.dirs}"/>

View File

@ -0,0 +1,32 @@
/**
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.solr.analysis;
import org.apache.lucene.analysis.fa.*;
import java.io.IOException;
import org.apache.lucene.analysis.TokenFilter;
import org.apache.lucene.analysis.TokenStream;
import org.apache.lucene.analysis.tokenattributes.TermAttribute;
import java.util.Map;
public class PersianNormalizationFilterFactory extends BaseTokenFilterFactory {
public PersianNormalizationFilter create(TokenStream input) {
return new PersianNormalizationFilter(input);
}
}

View File

@ -47,7 +47,7 @@ public class TrieTokenizerFactory extends BaseTokenizerFactory {
this.precisionStep = precisionStep;
}
public Tokenizer create(Reader input) {
public TrieTokenizer create(Reader input) {
return new TrieTokenizer(input, type, precisionStep, TrieTokenizer.getNumericTokenStream(precisionStep));
}
}
@ -115,4 +115,4 @@ class TrieTokenizer extends Tokenizer {
public boolean incrementToken() throws IOException {
return ts.incrementToken();
}
}
}