Class TypeTokenFilter

  • All Implemented Interfaces:
    java.io.Closeable, java.lang.AutoCloseable

    public final class TypeTokenFilter
    extends FilteringTokenFilter
    Removes tokens whose types appear in a set of blocked types from a token stream.
    • Constructor Detail

      • TypeTokenFilter

        @Deprecated
        public TypeTokenFilter​(Version version,
                               boolean enablePositionIncrements,
                               TokenStream input,
                               java.util.Set<java.lang.String> stopTypes,
                               boolean useWhiteList)
        Deprecated.
        enablePositionIncrements=false is not supported anymore as of Lucene 4.4.
      • TypeTokenFilter

        @Deprecated
        public TypeTokenFilter​(Version version,
                               boolean enablePositionIncrements,
                               TokenStream input,
                               java.util.Set<java.lang.String> stopTypes)
        Deprecated.
        enablePositionIncrements=false is not supported anymore as of Lucene 4.4.
      • TypeTokenFilter

        public TypeTokenFilter​(Version version,
                               TokenStream input,
                               java.util.Set<java.lang.String> stopTypes,
                               boolean useWhiteList)
        Create a new TypeTokenFilter.
        Parameters:
        version - the Lucene match version
        input - the TokenStream to consume
        stopTypes - the types to filter
        useWhiteList - if true, then tokens whose type is in stopTypes will be kept, otherwise they will be filtered out