52 |
* information via the <code>AttributedCharacterIterator</code> interface. |
* information via the <code>AttributedCharacterIterator</code> interface. |
53 |
* |
* |
54 |
* @author Aaron M. Renn (arenn@urbanophile.com) |
* @author Aaron M. Renn (arenn@urbanophile.com) |
55 |
|
* @since 1.2 |
56 |
*/ |
*/ |
57 |
public class AttributedString |
public class AttributedString |
58 |
{ |
{ |
117 |
* @param str The <code>String</code> to be attributed. |
* @param str The <code>String</code> to be attributed. |
118 |
* @param attributes The attribute list. |
* @param attributes The attribute list. |
119 |
*/ |
*/ |
120 |
public AttributedString(String str, Map attributes) |
public AttributedString(String str, |
121 |
|
Map<? extends AttributedCharacterIterator.Attribute, ?> attributes) |
122 |
{ |
{ |
123 |
this(str); |
this(str); |
124 |
|
|
302 |
* <code>null</code>. |
* <code>null</code>. |
303 |
* @throws IllegalArgumentException if the subrange is not valid. |
* @throws IllegalArgumentException if the subrange is not valid. |
304 |
*/ |
*/ |
305 |
public void addAttributes(Map attributes, int begin_index, int end_index) |
public void addAttributes(Map<? extends AttributedCharacterIterator.Attribute, ?> attributes, |
306 |
|
int begin_index, int end_index) |
307 |
{ |
{ |
308 |
if (attributes == null) |
if (attributes == null) |
309 |
throw new NullPointerException("null attribute"); |
throw new NullPointerException("null attribute"); |