harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From telli...@apache.org
Subject svn commit: r405066 - in /incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io: FilePermission.java ObjectInputStream.java ObjectOutputStream.java ObjectStreamClass.java ObjectStreamField.java SequenceInputStream.java
Date Mon, 08 May 2006 15:03:32 GMT
Author: tellison
Date: Mon May  8 08:03:30 2006
New Revision: 405066

URL: http://svn.apache.org/viewcvs?rev=405066&view=rev
Log:
Generics uplift

Modified:
    incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/FilePermission.java
    incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/ObjectInputStream.java
    incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/ObjectOutputStream.java
    incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/ObjectStreamClass.java
    incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/ObjectStreamField.java
    incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/SequenceInputStream.java

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/FilePermission.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/FilePermission.java?rev=405066&r1=405065&r2=405066&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/FilePermission.java
(original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/FilePermission.java
Mon May  8 08:03:30 2006
@@ -78,9 +78,9 @@
 				if (path.equals("<<ALL FILES>>")) { //$NON-NLS-1$
 					includeAll = true;
 				} else {
-					canonPath = (String) AccessController
-							.doPrivileged(new PrivilegedAction() {
-								public Object run() {
+					canonPath = AccessController
+							.doPrivileged(new PrivilegedAction<String>() {
+								public String run() {
 									try {
 										return new File(path)
 												.getCanonicalPath();

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/ObjectInputStream.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/ObjectInputStream.java?rev=405066&r1=405065&r2=405066&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/ObjectInputStream.java
(original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/ObjectInputStream.java
Mon May  8 08:03:30 2006
@@ -263,9 +263,9 @@
 		final Class thisClass = ObjectInputStream.class;
 		SecurityManager sm = System.getSecurityManager();
 		if (sm != null && implementationClass != thisClass) {
-			boolean mustCheck = ((Boolean) AccessController
-					.doPrivileged(new PrivilegedAction() {
-						public Object run() {
+			boolean mustCheck = (AccessController
+					.doPrivileged(new PrivilegedAction<Boolean>() {
+						public Boolean run() {
 							try {
 								Method method = implementationClass
 										.getMethod(
@@ -1636,7 +1636,7 @@
 	 * @throws ClassNotFoundException
 	 *             If the proxy class cannot be created
 	 */
-	protected Class resolveProxyClass(String[] interfaceNames)
+	protected Class<?> resolveProxyClass(String[] interfaceNames)
 			throws IOException, ClassNotFoundException {
 		ClassLoader loader = org.apache.harmony.kernel.vm.VM.getNonBootstrapClassLoader();
 		Class[] interfaces = new Class[interfaceNames.length];
@@ -2223,7 +2223,7 @@
 	 * @throws ClassNotFoundException
 	 *             If the corresponding class cannot be found.
 	 */
-	protected Class resolveClass(ObjectStreamClass osClass) throws IOException,
+	protected Class<?> resolveClass(ObjectStreamClass osClass) throws IOException,
 			ClassNotFoundException {
 		// Use the first non-null ClassLoader on the stack. If null, use the
 		// system class loader

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/ObjectOutputStream.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/ObjectOutputStream.java?rev=405066&r1=405065&r2=405066&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/ObjectOutputStream.java
(original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/ObjectOutputStream.java
Mon May  8 08:03:30 2006
@@ -253,7 +253,7 @@
 	 * 
 	 * @see ObjectInputStream#resolveClass
 	 */
-	protected void annotateClass(Class aClass) throws IOException {
+	protected void annotateClass(Class<?> aClass) throws IOException {
 		// By default no extra info is saved. Subclasses can override
 	}
 
@@ -270,7 +270,7 @@
 	 * 
 	 * @see ObjectInputStream#resolveProxyClass
 	 */
-	protected void annotateProxyClass(Class aClass) throws IOException {
+	protected void annotateProxyClass(Class<?> aClass) throws IOException {
 		// By default no extra info is saved. Subclasses can override
 	}
 

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/ObjectStreamClass.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/ObjectStreamClass.java?rev=405066&r1=405065&r2=405066&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/ObjectStreamClass.java
(original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/ObjectStreamClass.java
Mon May  8 08:03:30 2006
@@ -559,7 +559,7 @@
 	 *         receiver <code>Class</code> The loaded class corresponding to
 	 *         the receiver
 	 */
-	public Class forClass() {
+	public Class<?> forClass() {
 		if (resolvedClass != null) {
 			return (Class) resolvedClass.get();
 		}
@@ -858,7 +858,7 @@
 	 *         <code>ObjectStreamClass</code> The corresponding descriptor if
 	 *         the class <code>cl</code> is Serializable or Externalizable
 	 */
-	public static ObjectStreamClass lookup(Class cl) {
+	public static ObjectStreamClass lookup(Class<?> cl) {
 		boolean serializable = isSerializable(cl);
 		boolean externalizable = isExternalizable(cl);
 

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/ObjectStreamField.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/ObjectStreamField.java?rev=405066&r1=405065&r2=405066&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/ObjectStreamField.java
(original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/ObjectStreamField.java
Mon May  8 08:03:30 2006
@@ -30,7 +30,7 @@
  * @see ObjectInputStream#readFields()
  * 
  */
-public class ObjectStreamField extends Object implements Comparable {
+public class ObjectStreamField extends Object implements Comparable<Object> {
 	private String name; // Declared name of the field
 
 	private Object type; // Declared type of the field
@@ -49,7 +49,7 @@
 	 * @param cl
 	 *            A Class object representing the type of the field
 	 */
-	public ObjectStreamField(String name, Class cl) {
+	public ObjectStreamField(String name, Class<?> cl) {
 		if (name != null && cl != null) {
 			this.name = name;
 			this.type = new WeakReference(cl);
@@ -67,7 +67,7 @@
 	 * @param unshared
 	 *            write and read the field unshared
 	 */
-	public ObjectStreamField(String name, Class cl, boolean unshared) {
+	public ObjectStreamField(String name, Class<?> cl, boolean unshared) {
 		if (name != null && cl != null) {
 			this.name = name;
 			if (cl.getClassLoader() == null) {
@@ -146,7 +146,7 @@
 	 * 
 	 * @return A Class object representing the type of the field
 	 */
-	public Class getType() {
+	public Class<?> getType() {
 		if (type instanceof WeakReference) {
 			return (Class) ((WeakReference) type).get();
 		}

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/SequenceInputStream.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/SequenceInputStream.java?rev=405066&r1=405065&r2=405066&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/SequenceInputStream.java
(original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/SequenceInputStream.java
Mon May  8 08:03:30 2006
@@ -15,6 +15,8 @@
 
 package java.io;
 
+import java.util.Enumeration;
+
 
 /**
  * SequenceInputStream is used for streaming over a sequence of streams
@@ -61,7 +63,7 @@
 	 * @param e
 	 *            the Enumeration of InputStreams to get bytes from
 	 */
-	public SequenceInputStream(java.util.Enumeration e) {
+	public SequenceInputStream(Enumeration<? extends InputStream> e) {
 		this.e = e;
 		if (e.hasMoreElements()) {
 			in = (InputStream) e.nextElement();



Mime
View raw message