|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface AttributedCharacterIterator
This interface extends the CharacterIterator
interface
in order to support iteration over character attributes as well as
over the characters themselves.
In addition to attributes of specific characters, this interface supports the concept of the "attribute run", which is an attribute that is defined for a particular value across an entire range of characters or which is undefined over a range of characters.
Nested Class Summary | |
---|---|
static class |
AttributedCharacterIterator.Attribute
Defines attribute keys that are used as text attributes. |
Field Summary |
---|
Fields inherited from interface java.text.CharacterIterator |
---|
DONE |
Method Summary | |
---|---|
Set<AttributedCharacterIterator.Attribute> |
getAllAttributeKeys()
Returns a list of all keys that are defined for the text range. |
Object |
getAttribute(AttributedCharacterIterator.Attribute attrib)
Returns the value of the specified attribute for the current character. |
Map<AttributedCharacterIterator.Attribute,Object> |
getAttributes()
Returns a Map of the attributes defined for the current
character. |
int |
getRunLimit()
Returns the index of the character after the end of the run that contains all attributes defined for the current character. |
int |
getRunLimit(AttributedCharacterIterator.Attribute attrib)
Returns the index of the character after the end of the run that contains the specified attribute defined for the current character. |
int |
getRunLimit(Set<? extends AttributedCharacterIterator.Attribute> attribs)
Returns the index of the character after the end of the run that contains all attributes in the specified Set defined
for the current character. |
int |
getRunStart()
Returns the index of the first character in the run that contains all attributes defined for the current character. |
int |
getRunStart(AttributedCharacterIterator.Attribute attrib)
Returns the index of the first character in the run that contains the specified attribute defined for the current character. |
int |
getRunStart(Set<? extends AttributedCharacterIterator.Attribute> attribs)
Returns the index of the first character in the run that contains all attributes in the specified Set defined for
the current character. |
Methods inherited from interface java.text.CharacterIterator |
---|
clone, current, first, getBeginIndex, getEndIndex, getIndex, last, next, previous, setIndex |
Method Detail |
---|
Set<AttributedCharacterIterator.Attribute> getAllAttributeKeys()
Map<AttributedCharacterIterator.Attribute,Object> getAttributes()
Map
of the attributes defined for the current
character.
Map
of the attributes for the current character.Object getAttribute(AttributedCharacterIterator.Attribute attrib)
null
is returned.
attrib
- The attribute to retrieve the value of.
int getRunStart()
int getRunStart(Set<? extends AttributedCharacterIterator.Attribute> attribs)
Set
defined for
the current character.
attribs
- The Set
of attributes.
int getRunStart(AttributedCharacterIterator.Attribute attrib)
attrib
- The attribute.
int getRunLimit()
int getRunLimit(Set<? extends AttributedCharacterIterator.Attribute> attribs)
Set
defined
for the current character.
attribs
- The Set
of attributes.
int getRunLimit(AttributedCharacterIterator.Attribute attrib)
attrib
- The attribute.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |