org.apache.lucene.analysis.miscellaneous

Class LimitTokenOffsetFilterFactory



  • public class LimitTokenOffsetFilterFactory
    extends TokenFilterFactory
    Factory for LimitTokenOffsetFilter.
     <fieldType name="text_limit_pos" class="solr.TextField" positionIncrementGap="100">
       <analyzer>
         <tokenizer class="solr.WhitespaceTokenizerFactory"/>
         <filter class="solr.LimitTokenOffsetFilter" maxStartOffset="100000" consumeAllTokens="false" />
       </analyzer>
     </fieldType>

    The consumeAllTokens property is optional and defaults to false.