UnescapedCharSequence (Lucene 10.5.1 queryparser API)
Description: declaration: package: org.apache.lucene.queryparser.flexible.core.util, class: UnescapedCharSequence

Package org.apache.lucene.queryparser.flexible.core.util

# Class UnescapedCharSequence

java.lang.Object
org.apache.lucene.queryparser.flexible.core.util.UnescapedCharSequence

All Implemented Interfaces:
  `CharSequence`

public final class UnescapedCharSequence extends Object implements CharSequence
CharsSequence with escaped chars information.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `UnescapedCharSequence(char[] chars, boolean[] wasEscaped, int offset, int length)`
  Create an escaped CharSequence
  `UnescapedCharSequence(CharSequence text)`
  Create a non-escaped CharSequence

- ## Method Summary

  Modifier and Type
  Method
  Description
  `char`
  `charAt(int index)`
  `int`
  `length()`
  `CharSequence`
  `subSequence(int start, int end)`
  `static CharSequence`
  `toLowerCase(CharSequence text, Locale locale)`
  `String`
  `toString()`
  `String`
  `toStringEscaped()`
  Return a escaped String
  `String`
  `toStringEscaped(char[] enabledChars)`
  Return a escaped String
  `boolean`
  `wasEscaped(int index)`
  `static boolean`
  `wasEscaped(CharSequence text, int index)`

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

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

  ### Methods inherited from interface java.lang.CharSequence

  `chars, codePoints, isEmpty`

- ## Constructor Details

  - ### UnescapedCharSequence

    public UnescapedCharSequence(char[] chars, boolean[] wasEscaped, int offset, int length)
    Create an escaped CharSequence

  - ### UnescapedCharSequence

    public UnescapedCharSequence(CharSequence text)
    Create a non-escaped CharSequence

- ## Method Details

  - ### charAt

    public char charAt(int index)
    Specified by:
      `charAt` in interface `CharSequence`

  - ### length

    public int length()
    Specified by:
      `length` in interface `CharSequence`

  - ### subSequence

    public CharSequence subSequence(int start, int end)
    Specified by:
      `subSequence` in interface `CharSequence`

  - ### toString

    public String toString()
    Specified by:
      `toString` in interface `CharSequence`
    Overrides:
      `toString` in class `Object`

  - ### toStringEscaped

    public String toStringEscaped()
    Return a escaped String
    Returns:
      a escaped String

  - ### toStringEscaped

    public String toStringEscaped(char[] enabledChars)
    Return a escaped String
    Parameters:
      `enabledChars` - - array of chars to be escaped
    Returns:
      a escaped String

  - ### wasEscaped

    public boolean wasEscaped(int index)

  - ### wasEscaped

    public static boolean wasEscaped(CharSequence text, int index)

  - ### toLowerCase

    public static CharSequence toLowerCase(CharSequence text, Locale locale)