public interface

FlagsAttribute

implements Attribute
org.apache.lucene.analysis.tokenattributes.FlagsAttribute
Known Indirect Subclasses

Class Overview

This attribute can be used to pass different flags down the Tokenizer chain, eg from one TokenFilter to another one.

Summary

Public Methods
abstract int getFlags()
EXPERIMENTAL: While we think this is here to stay, we may want to change it to be a long.
abstract void setFlags(int flags)

Public Methods

public abstract int getFlags ()

EXPERIMENTAL: While we think this is here to stay, we may want to change it to be a long.

Get the bitset for any bits that have been set. This is completely distinct from type(), although they do share similar purposes. The flags can be used to encode information about the token for use by other TokenFilters.

Returns
  • The bits

public abstract void setFlags (int flags)

See Also