Package org.apache.lucene.analysis.miscellaneous

# Class StemmerOverrideFilter.Builder

java.lang.Object
org.apache.lucene.analysis.miscellaneous.StemmerOverrideFilter.Builder

Enclosing class:
  `StemmerOverrideFilter`

public static class StemmerOverrideFilter.Builder extends Object
This builder builds an `FST` for the `StemmerOverrideFilter`

## Constructor Summary

Constructors
Constructor
Description
`Builder()`
Creates a new `StemmerOverrideFilter.Builder` with ignoreCase set to `false`
`Builder(boolean ignoreCase)`
Creates a new `StemmerOverrideFilter.Builder`

## Method Summary

Modifier and Type
Method
Description
`boolean`
`add(CharSequence input, CharSequence output)`
Adds an input string and its stemmer override output to this builder.
`StemmerOverrideFilter.StemmerOverrideMap`
`build()`
Returns an `StemmerOverrideFilter.StemmerOverrideMap` to be used with the `StemmerOverrideFilter`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Constructor Details

### Builder

public Builder()
Creates a new `StemmerOverrideFilter.Builder` with ignoreCase set to `false`

### Builder

public Builder(boolean ignoreCase)
Creates a new `StemmerOverrideFilter.Builder`

Parameters:
  `ignoreCase` - if the input case should be ignored.

## Method Details

### add

public boolean add(CharSequence input, CharSequence output)
Adds an input string and its stemmer override output to this builder.

Parameters:
  `input` - the input char sequence
  `output` - the stemmer override output char sequence
Returns:
  `false` iff the input has already been added to this builder otherwise `true`.

### build

public StemmerOverrideFilter.StemmerOverrideMap build() throws IOException
Returns an `StemmerOverrideFilter.StemmerOverrideMap` to be used with the `StemmerOverrideFilter`

Returns:
  an `StemmerOverrideFilter.StemmerOverrideMap` to be used with the `StemmerOverrideFilter`
Throws:
  `IOException` - if an `IOException` occurs;