|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface TextRange
A text range defines the offset into, length of, and line of a piece of text. Provisional API: This interface is part of an interim API that is still under development and expected to change significantly before reaching stability. It is available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken (repeatedly) as the API evolves. This interface is not intended to be implemented by clients.
Nested Class Summary | |
---|---|
static class |
TextRange.Empty
Empty implementation of text range. |
Method Summary | |
---|---|
boolean |
equals(java.lang.Object obj)
Return true if the offsets and lengths are the same. |
int |
getLength()
Return the length of the text. |
int |
getLineNumber()
Return the line number of the text. |
int |
getOffset()
Returns the offset of the text. |
int |
hashCode()
Return a hash code that corresponds to the #equals() contract. |
boolean |
includes(int index)
Return whether the range includes the character at the specified index. |
boolean |
touches(int index)
Return whether the range touches an insertion cursor at the specified index. |
Method Detail |
---|
int getOffset()
int getLength()
boolean includes(int index)
boolean touches(int index)
int getLineNumber()
boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
int hashCode()
hashCode
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |