diff options
author | Andrew John Hughes <gnu_andrew@member.fsf.org> | 2005-10-16 17:12:04 +0000 |
---|---|---|
committer | Andrew John Hughes <gnu_andrew@member.fsf.org> | 2005-10-16 17:12:04 +0000 |
commit | 27dc71e0dc65d7cf5ffd3961d3e8345272dc4808 (patch) | |
tree | 9ba7cb6f417be11370dee631b0a5accf859ba1ff /javax/swing/text | |
parent | 837db4d5cfec5e5f9a55312cfd28dc2ad5c8531b (diff) | |
download | classpath-27dc71e0dc65d7cf5ffd3961d3e8345272dc4808.tar.gz |
2005-10-16 Andrew John Hughes <gnu_andrew@member.fsf.org>
* java/awt/image/BufferedImage.java:
(getSources()): Genericized.
* java/awt/image/ImageFilter.java:
(setProperties(Hashtable<?,?>)): Likewise.
* java/awt/image/MemoryImageSource.java:
(MemoryImageSource(int,int,int[],int,int,Hashtable<?,?>)): Likewise.
* java/awt/image/PixelGrabber.java:
(setProperties(Hashtable<?,?>)): Likewise.
* java/awt/image/renderable/RenderableImageOp.java:
(getSources()): Likewise.
* java/beans/Beans.java:
(getInstanceOf(Object,Class<?>)): Likewise.
(isInstanceOf(Object,Class<?>)): Likewise.
* java/beans/EventSetDescriptor.java:
(EventSetDescriptor(Class<?>,String,Class<?>,String)): Likewise.
(EventSetDescriptor(Class<?>,String,Class<?>,String[],String,String)):
Likewise.
(EventSetDescriptor(Class<?>,Method[],Method,Method)): Likewise.
(EventSetDescriptor(String,Class<?>,MethodDescriptor,Method,Method)):
Likewise.
(getListenerType()): Likewise.
* java/beans/FeatureDescriptor.java:
(FeatureDescriptor()): Likewise.
(attributeNames()): Likewise.
* java/beans/IndexedPropertyDescriptor.java:
(IndexedPropertyDescriptor(String,Class<?>)): Likewise.
(IndexedPropertyDescriptor(String,Class<?>,String,String,String,String)):
Likewise.
(getIndexedPropertyType()): Likewise.
* java/beans/Introspector.java:
(getBeanInfo(Class<?>)): Likewise.
(flushFromCaches(Class<?>)): Likewise.
(getBeanInfo(Class<?>,Class<?>)): Likewise.
* java/beans/PropertyDescriptor.java:
(PropertyDescriptor(String,Class<?>)): Likewise.
(getPropertyType()): Likewise.
(getPropertyEditorClass()): Likewise.
(setPropertyEditorClass(Class<?>)): Likewise.
(checkMethods(Method,Method)): Likewise.
* java/beans/PropertyEditorManager.java:
(registerEditor(Class<?>,Class<?>)): Likewise.
(getEditor(Class<?>)): Likewise.
* java/io/ObjectInputStream.java:
(resolveClass(ObjectStreamClass)): Likewise.
* java/io/ObjectOutputStream.java:
(annotateClass(Class<?>)): Likewise.
(annotateProxyClass(Class<?>)): Likewise.
* java/io/ObjectStreamClass.java:
(lookup(Class<?>)): Likewise.
(forClass()): Likewise.
* java/io/ObjectStreamField.java:
(ObjectStreamField(String,Class<?>)): Likewise.
(ObjectStreamField(String,Class<?>,boolean)): Likewise.
* java/net/NetworkInterface.java:
(getInetAddresses()): Likewise.
(getNetworkInterfaces()): Likewise.
* java/net/URLClassLoader.java:
(findClass(String)): Likewise.
(findResources(String)): Likewise.
* java/net/URLConnection.java:
(getHeaderFields()): Likewise.
(getRequestProperties()): Likewise.
* javax/swing/text/TextAction.java:
(augmentList(Action[],Action[])): Likewise.
* javax/swing/text/html/HTML.java:
(attrMap): Likewise.
(tagMap): Likewise.
* javax/swing/text/html/parser/DTD.java:
(dtdHash): Likewise.
(elementHash): Likewise.
(entityHash): Likewise.
(defineAttributes(String,AttributeList)): Likewise.
(newElement(String)): Likewise.
Diffstat (limited to 'javax/swing/text')
-rw-r--r-- | javax/swing/text/TextAction.java | 6 | ||||
-rw-r--r-- | javax/swing/text/html/HTML.java | 12 | ||||
-rw-r--r-- | javax/swing/text/html/parser/DTD.java | 17 |
3 files changed, 18 insertions, 17 deletions
diff --git a/javax/swing/text/TextAction.java b/javax/swing/text/TextAction.java index 8588e3cd2..3ba5100c5 100644 --- a/javax/swing/text/TextAction.java +++ b/javax/swing/text/TextAction.java @@ -87,7 +87,7 @@ public abstract class TextAction extends AbstractAction */ public static final Action[] augmentList(Action[] list1, Action[] list2) { - HashSet actionSet = new HashSet(); + HashSet<Action> actionSet = new HashSet<Action>(); for (int i = 0; i < list1.length; ++i) actionSet.add(list1[i]); @@ -95,8 +95,8 @@ public abstract class TextAction extends AbstractAction for (int i = 0; i < list2.length; ++i) actionSet.add(list2[i]); - ArrayList list = new ArrayList(actionSet); - return (Action[]) list.toArray(new Action[actionSet.size()]); + ArrayList<Action> list = new ArrayList<Action>(actionSet); + return list.toArray(new Action[actionSet.size()]); } /** diff --git a/javax/swing/text/html/HTML.java b/javax/swing/text/html/HTML.java index 3c03a63a4..fa458ef45 100644 --- a/javax/swing/text/html/HTML.java +++ b/javax/swing/text/html/HTML.java @@ -1186,8 +1186,8 @@ public class HTML static final int BLOCK = 2; static final int PREFORMATTED = 4; static final int SYNTETIC = 8; - private static Map tagMap; - private static Map attrMap; + private static Map<String,Tag> tagMap; + private static Map<String,Attribute> attrMap; /** * The public constructor (does nothing). It it seldom required to have @@ -1225,7 +1225,7 @@ public class HTML if (attrMap == null) { // Create the map on demand. - attrMap = new TreeMap(); + attrMap = new TreeMap<String,Attribute>(); Attribute[] attrs = getAllAttributeKeys(); @@ -1235,7 +1235,7 @@ public class HTML } } - return (Attribute) attrMap.get(attName.toLowerCase()); + return attrMap.get(attName.toLowerCase()); } /** @@ -1294,7 +1294,7 @@ public class HTML if (tagMap == null) { // Create the mao on demand. - tagMap = new TreeMap(); + tagMap = new TreeMap<String,Tag>(); Tag[] tags = getAllTags(); @@ -1304,6 +1304,6 @@ public class HTML } } - return (Tag) tagMap.get(tagName.toLowerCase()); + return tagMap.get(tagName.toLowerCase()); } } diff --git a/javax/swing/text/html/parser/DTD.java b/javax/swing/text/html/parser/DTD.java index 1ede342de..42bf2e570 100644 --- a/javax/swing/text/html/parser/DTD.java +++ b/javax/swing/text/html/parser/DTD.java @@ -88,7 +88,7 @@ public class DTD /** * The table of existing available DTDs. */ - static Hashtable dtdHash = new Hashtable(); + static Hashtable<String,DTD> dtdHash = new Hashtable<String,DTD>(); /** * The applet element for this DTD. @@ -148,12 +148,13 @@ public class DTD /** * The element for accessing all DTD elements by name. */ - public Hashtable elementHash = new Hashtable(); + public Hashtable<String,Element> elementHash = + new Hashtable<String,Element>(); /** * The entity table for accessing all DTD entities by name. */ - public Hashtable entityHash = new Hashtable(); + public Hashtable<String,Entity> entityHash = new Hashtable<String,Entity>(); /** * The name of this DTD. @@ -165,7 +166,7 @@ public class DTD * javax.swing.text.html.parser.Element#index field of all elements * in this vector is set to the element position in this vector. */ - public Vector elements = new Vector(); + public Vector<Element> elements = new Vector<Element>(); /** Create a new DTD with the specified name. */ protected DTD(String a_name) @@ -224,7 +225,7 @@ public class DTD String name = Entity.mapper.get(id); if (name != null) - return (Entity) entityHash.get(name); + return entityHash.get(name); else return null; } @@ -269,7 +270,7 @@ public class DTD */ public void defineAttributes(String forElement, AttributeList attributes) { - Element e = (Element) elementHash.get(forElement.toLowerCase()); + Element e = elementHash.get(forElement.toLowerCase()); if (e == null) e = newElement(forElement); @@ -420,7 +421,7 @@ public class DTD if (allowed_values != null) { StringTokenizer st = new StringTokenizer(allowed_values, " \t|"); - Vector v = new Vector(st.countTokens()); + Vector<String> v = new Vector<String>(st.countTokens()); while (st.hasMoreTokens()) v.add(st.nextToken()); @@ -571,7 +572,7 @@ public class DTD */ private Element newElement(String name) { - Element e = (Element) elementHash.get(name.toLowerCase()); + Element e = elementHash.get(name.toLowerCase()); if (e == null) { |