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 and Description
    `Builder()` Creates a new `StemmerOverrideFilter.Builder` with ignoreCase set to `false`
    `Builder(boolean ignoreCase)` Creates a new `StemmerOverrideFilter.Builder`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and 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 Detail

    - #### 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 Detail

    - #### 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;

Copyright © 2000-2019 Apache Software Foundation. All Rights Reserved.