diff options
Diffstat (limited to 'libjava/java/text/AttributedString.java')
-rw-r--r-- | libjava/java/text/AttributedString.java | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/libjava/java/text/AttributedString.java b/libjava/java/text/AttributedString.java index d689d87..a8eede8 100644 --- a/libjava/java/text/AttributedString.java +++ b/libjava/java/text/AttributedString.java @@ -1,5 +1,5 @@ /* AttributedString.java -- Models text with attributes - Copyright (C) 1998, 1999 Free Software Foundation, Inc. + Copyright (C) 1998, 1999, 2004 Free Software Foundation, Inc. This file is part of GNU Classpath. @@ -39,6 +39,7 @@ exception statement from your version. */ package java.text; import java.util.Iterator; +import java.util.HashMap; import java.util.Hashtable; import java.util.HashSet; import java.util.Map; @@ -329,7 +330,7 @@ addAttribute(AttributedCharacterIterator.Attribute attrib, Object value) * of the string. * * @param attrib The attribute to add. - * @param value The value of the attribute. + * @param value The value of the attribute, which may be null. * @param begin_index The beginning index of the subrange. * @param end_index The ending index of the subrange. * @@ -342,10 +343,10 @@ addAttribute(AttributedCharacterIterator.Attribute attrib, Object value, if (attrib == null) throw new IllegalArgumentException("null attribute"); - Hashtable ht = new Hashtable(); - ht.put(attrib, value); + HashMap hm = new HashMap(); + hm.put(attrib, value); - addAttributes(ht, begin_index, end_index); + addAttributes(hm, begin_index, end_index); } /*************************************************************************/ |