Package org.teavm.classlib.java.text
Interface TAttributedCharacterIterator
- All Superinterfaces:
Cloneable
,TCharacterIterator
-
Nested Class Summary
Nested Classes -
Field Summary
Fields inherited from interface org.teavm.classlib.java.text.TCharacterIterator
DONE
-
Method Summary
Modifier and TypeMethodDescriptionReturns a set of attributes present in theAttributedCharacterIterator
.getAttribute(TAttributedCharacterIterator.Attribute attribute)
Returns the value stored in the attribute for the current character.Returns a map of all attributes of the current character.int
Returns the index of the last character in the run having the same attributes as the current character.int
getRunLimit(TAttributedCharacterIterator.Attribute attribute)
Returns the index of the last character in the run that has the same attribute value for the given attribute as the current character.int
getRunLimit(TSet<? extends TAttributedCharacterIterator.Attribute> attributes)
Returns the index of the last character in the run that has the same attribute values for the attributes in the set as the current character.int
Returns the index of the first character in the run that has the same attributes as the current character.int
getRunStart(TAttributedCharacterIterator.Attribute attribute)
Returns the index of the first character in the run that has the same attribute value for the given attribute as the current character.int
getRunStart(TSet<? extends TAttributedCharacterIterator.Attribute> attributes)
Returns the index of the first character in the run that has the same attribute values for the attributes in the set as the current character.Methods inherited from interface org.teavm.classlib.java.text.TCharacterIterator
clone, current, first, getBeginIndex, getEndIndex, getIndex, last, next, previous, setIndex
-
Method Details
-
getAllAttributeKeys
TSet<TAttributedCharacterIterator.Attribute> getAllAttributeKeys()Returns a set of attributes present in theAttributedCharacterIterator
. An empty set is returned if no attributes were defined.- Returns:
- a set of attribute keys; may be empty.
-
getAttribute
Returns the value stored in the attribute for the current character. If the attribute was not defined thennull
is returned.- Parameters:
attribute
- the attribute for which the value should be returned.- Returns:
- the value of the requested attribute for the current character or
null
if it was not defined.
-
getAttributes
TMap<TAttributedCharacterIterator.Attribute,Object> getAttributes()Returns a map of all attributes of the current character. If no attributes were defined for the current character then an empty map is returned.- Returns:
- a map of all attributes for the current character or an empty map.
-
getRunLimit
int getRunLimit()Returns the index of the last character in the run having the same attributes as the current character.- Returns:
- the index of the last character of the current run.
-
getRunLimit
Returns the index of the last character in the run that has the same attribute value for the given attribute as the current character.- Parameters:
attribute
- the attribute which the run is based on.- Returns:
- the index of the last character of the current run.
-
getRunLimit
Returns the index of the last character in the run that has the same attribute values for the attributes in the set as the current character.- Parameters:
attributes
- the set of attributes which the run is based on.- Returns:
- the index of the last character of the current run.
-
getRunStart
int getRunStart()Returns the index of the first character in the run that has the same attributes as the current character.- Returns:
- the index of the last character of the current run.
-
getRunStart
Returns the index of the first character in the run that has the same attribute value for the given attribute as the current character.- Parameters:
attribute
- the attribute which the run is based on.- Returns:
- the index of the last character of the current run.
-
getRunStart
Returns the index of the first character in the run that has the same attribute values for the attributes in the set as the current character.- Parameters:
attributes
- the set of attributes which the run is based on.- Returns:
- the index of the last character of the current run.
-