CharArrayIterator (Lucene 3.6.2 API)
Keywords: org.apache.lucene.analysis.util.CharArrayIterator class

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.lucene.analysis.util
Class CharArrayIterator

    java.lang.Object
      org.apache.lucene.analysis.util.CharArrayIterator

All Implemented Interfaces:
  Cloneable, CharacterIterator

    public abstract class CharArrayIterator

extends Object
implements CharacterIterator

A CharacterIterator used internally for use with `BreakIterator`

NOTE: This API is for internal purposes only and might change in incompatible ways in the next release.

Field Summary
`static boolean` | `HAS_BUGGY_BREAKITERATORS` True if this JRE has a buggy BreakIterator implementation

Fields inherited from interface java.text.CharacterIterator
`DONE`

Constructor Summary
`CharArrayIterator()`

Method Summary
`Object` | `clone()`
`char` | `current()`
`char` | `first()`
`int` | `getBeginIndex()`
`int` | `getEndIndex()`
`int` | `getIndex()`
`int` | `getLength()`
`int` | `getStart()`
`char[]` | `getText()`
`protected abstract char` | `jreBugWorkaround(char ch)`
`char` | `last()`
`static CharArrayIterator` | `newSentenceInstance()` Create a new CharArrayIterator that works around JRE bugs in a manner suitable for `BreakIterator.getSentenceInstance()`
`static CharArrayIterator` | `newWordInstance()` Create a new CharArrayIterator that works around JRE bugs in a manner suitable for `BreakIterator.getWordInstance()`
`char` | `next()`
`char` | `previous()`
`char` | `setIndex(int position)`
`void` | `setText(char[] array, int start, int length)` Set a new region of text to be examined by this iterator

Methods inherited from class java.lang.Object
`equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### HAS_BUGGY_BREAKITERATORS

    public static final boolean HAS_BUGGY_BREAKITERATORS

  True if this JRE has a buggy BreakIterator implementation

Constructor Detail

### CharArrayIterator

    public CharArrayIterator()

Method Detail

### getText

    public char[] getText()

### getStart

    public int getStart()

### getLength

    public int getLength()

### setText

    public void setText(char[] array,
                        int start,
                        int length)

  Set a new region of text to be examined by this iterator

  Parameters:
    `array` - text buffer to examine
    `start` - offset into buffer
    `length` - maximum length to examine

### current

    public char current()

  Specified by:
    `current` in interface `CharacterIterator`

### jreBugWorkaround

    protected abstract char jreBugWorkaround(char ch)

### first

    public char first()

  Specified by:
    `first` in interface `CharacterIterator`

### getBeginIndex

    public int getBeginIndex()

  Specified by:
    `getBeginIndex` in interface `CharacterIterator`

### getEndIndex

    public int getEndIndex()

  Specified by:
    `getEndIndex` in interface `CharacterIterator`

### getIndex

    public int getIndex()

  Specified by:
    `getIndex` in interface `CharacterIterator`

### last

    public char last()

  Specified by:
    `last` in interface `CharacterIterator`

### next

    public char next()

  Specified by:
    `next` in interface `CharacterIterator`

### previous

    public char previous()

  Specified by:
    `previous` in interface `CharacterIterator`

### setIndex

    public char setIndex(int position)

  Specified by:
    `setIndex` in interface `CharacterIterator`

### clone

    public Object clone()

  Specified by:
    `clone` in interface `CharacterIterator`
  Overrides:
    `clone` in class `Object`

### newSentenceInstance

    public static CharArrayIterator newSentenceInstance()

  Create a new CharArrayIterator that works around JRE bugs in a manner suitable for `BreakIterator.getSentenceInstance()`

### newWordInstance

    public static CharArrayIterator newWordInstance()

  Create a new CharArrayIterator that works around JRE bugs in a manner suitable for `BreakIterator.getWordInstance()`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD