|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.ibm.icu.text.BreakIterator
org.eclipse.xtext.ui.editor.model.CommonBreakIterator
public class CommonBreakIterator
This class was copied from org.eclipse.jdt.internal.ui.text.JavaBreakIterator.
| Nested Class Summary | |
|---|---|
protected static class |
CommonBreakIterator.CamelCaseIdentifier
|
protected static class |
CommonBreakIterator.Identifier
|
protected static class |
CommonBreakIterator.LineDelimiter
|
protected static class |
CommonBreakIterator.Other
|
protected static class |
CommonBreakIterator.Run
A run of common characters. |
protected class |
CommonBreakIterator.SequenceCharacterIterator
A CharSequence based implementation of CharacterIterator. |
protected static class |
CommonBreakIterator.Whitespace
|
| Field Summary | |
|---|---|
protected CommonBreakIterator.Run |
delimiter
|
protected com.ibm.icu.text.BreakIterator |
fIterator
The platform break iterator (word instance) used as a base. |
protected java.lang.CharSequence |
fText
The text we operate on. |
protected CommonBreakIterator.Run |
identifier
|
protected CommonBreakIterator.Run |
other
|
protected CommonBreakIterator.Run |
whitespace
|
| Fields inherited from class com.ibm.icu.text.BreakIterator |
|---|
DONE, KIND_CHARACTER, KIND_LINE, KIND_SENTENCE, KIND_TITLE, KIND_WORD |
| Constructor Summary | |
|---|---|
CommonBreakIterator(boolean camelCase)
Creates a new break iterator. |
|
| Method Summary | |
|---|---|
protected CommonBreakIterator.Run |
consumeRun(int offset)
Consumes a run of characters at the limits of which we introduce a break. |
int |
current()
Return the iterator's current position. |
int |
first()
Return the first boundary position. |
int |
following(int offset)
Sets the iterator's current iteration position to be the first boundary position following the specified position. |
protected CommonBreakIterator.Run |
getRun(char ch)
Returns a run based on a character. |
java.text.CharacterIterator |
getText()
Returns a CharacterIterator over the text being analyzed. |
boolean |
isBoundary(int offset)
Return true if the specfied position is a boundary position. |
int |
last()
Return the last boundary position. |
int |
next()
Advances the iterator forward one boundary. |
int |
next(int n)
Advances the specified number of steps forward in the text (a negative number, therefore, advances backwards). |
int |
preceding(int offset)
Sets the iterator's current iteration position to be the last boundary position preceding the specified position. |
int |
previous()
Advances the iterator backward one boundary. |
void |
setText(java.text.CharacterIterator newText)
Sets the iterator to analyze a new piece of text. |
void |
setText(java.lang.CharSequence newText)
Creates a break iterator given a char sequence. |
void |
setText(java.lang.String newText)
Sets the iterator to analyze a new piece of text. |
| Methods inherited from class com.ibm.icu.text.BreakIterator |
|---|
clone, getAvailableLocales, getAvailableULocales, getBreakInstance, getCharacterInstance, getCharacterInstance, getCharacterInstance, getLineInstance, getLineInstance, getLineInstance, getLocale, getSentenceInstance, getSentenceInstance, getSentenceInstance, getTitleInstance, getTitleInstance, getTitleInstance, getWordInstance, getWordInstance, getWordInstance, registerInstance, registerInstance, unregister |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected CommonBreakIterator.Run whitespace
protected CommonBreakIterator.Run delimiter
protected CommonBreakIterator.Run identifier
protected CommonBreakIterator.Run other
protected final com.ibm.icu.text.BreakIterator fIterator
protected java.lang.CharSequence fText
| Constructor Detail |
|---|
public CommonBreakIterator(boolean camelCase)
| Method Detail |
|---|
public int current()
com.ibm.icu.text.BreakIterator
current in class com.ibm.icu.text.BreakIteratorpublic int first()
com.ibm.icu.text.BreakIterator
first in class com.ibm.icu.text.BreakIteratorpublic int following(int offset)
com.ibm.icu.text.BreakIterator
following in class com.ibm.icu.text.BreakIteratoroffset - The character position to start searching from.
protected CommonBreakIterator.Run consumeRun(int offset)
offset - the offset to start at
protected CommonBreakIterator.Run getRun(char ch)
ch - the character to test
chpublic java.text.CharacterIterator getText()
com.ibm.icu.text.BreakIterator
getText in class com.ibm.icu.text.BreakIteratorpublic boolean isBoundary(int offset)
com.ibm.icu.text.BreakIterator
isBoundary in class com.ibm.icu.text.BreakIteratoroffset - the offset to check.
public int last()
com.ibm.icu.text.BreakIterator
last in class com.ibm.icu.text.BreakIteratorpublic int next()
com.ibm.icu.text.BreakIterator
next in class com.ibm.icu.text.BreakIteratorpublic int next(int n)
com.ibm.icu.text.BreakIterator
next in class com.ibm.icu.text.BreakIteratorn - The number of boundaries to advance over (if positive, moves
forward; if negative, moves backwards).
public int preceding(int offset)
com.ibm.icu.text.BreakIterator
preceding in class com.ibm.icu.text.BreakIteratoroffset - The character position to start searching from.
public int previous()
com.ibm.icu.text.BreakIterator
previous in class com.ibm.icu.text.BreakIteratorpublic void setText(java.lang.String newText)
com.ibm.icu.text.BreakIterator
setText in class com.ibm.icu.text.BreakIteratornewText - A String containing the text to analyze with
this BreakIterator.public void setText(java.lang.CharSequence newText)
newText - the new textpublic void setText(java.text.CharacterIterator newText)
com.ibm.icu.text.BreakIterator
setText in class com.ibm.icu.text.BreakIteratornewText - A CharacterIterator referring to the text
to analyze with this BreakIterator (the iterator's current
position is ignored, but its other state is significant).
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||