diff options
| author | mark <mark@138bc75d-0d04-0410-961f-82ee72b054a4> | 2005-11-15 23:20:01 +0000 |
|---|---|---|
| committer | mark <mark@138bc75d-0d04-0410-961f-82ee72b054a4> | 2005-11-15 23:20:01 +0000 |
| commit | 3b3101d8b5ae4f08a16c0b7111da6cad41bbd282 (patch) | |
| tree | a5eb7cf42a51869cc8aa1fad7ad6a90cca47fdd8 /libjava/classpath/java/lang/reflect | |
| parent | 7e55c49d7d91ef9f09e93c1100119b1ab3652446 (diff) | |
| download | ppe42-gcc-3b3101d8b5ae4f08a16c0b7111da6cad41bbd282.tar.gz ppe42-gcc-3b3101d8b5ae4f08a16c0b7111da6cad41bbd282.zip | |
Imported GNU Classpath 0.19 + gcj-import-20051115.
* sources.am: Regenerated.
* Makefile.in: Likewise.
* scripts/makemake.tcl: Use glob -nocomplain.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@107049 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libjava/classpath/java/lang/reflect')
| -rw-r--r-- | libjava/classpath/java/lang/reflect/Member.java | 4 | ||||
| -rw-r--r-- | libjava/classpath/java/lang/reflect/Proxy.java | 19 | ||||
| -rw-r--r-- | libjava/classpath/java/lang/reflect/UndeclaredThrowableException.java | 2 |
3 files changed, 11 insertions, 14 deletions
diff --git a/libjava/classpath/java/lang/reflect/Member.java b/libjava/classpath/java/lang/reflect/Member.java index 9983b275a94..c39731f8487 100644 --- a/libjava/classpath/java/lang/reflect/Member.java +++ b/libjava/classpath/java/lang/reflect/Member.java @@ -60,7 +60,7 @@ public interface Member * package-protected, but only which are declared in this class. * Used in SecurityManager.checkMemberAccess() to determine the * type of members to access. - * @see SecurityManager#checkMemberAccess() + * @see SecurityManager#checkMemberAccess(Class, int) */ int DECLARED = 1; @@ -68,7 +68,7 @@ public interface Member * Represents public members only, but includes all inherited members. * Used in SecurityManager.checkMemberAccess() to determine the type of * members to access. - * @see SecurityManager#checkMemberAccess() + * @see SecurityManager#checkMemberAccess(Class, int) */ int PUBLIC = 0; diff --git a/libjava/classpath/java/lang/reflect/Proxy.java b/libjava/classpath/java/lang/reflect/Proxy.java index 7a5fd30de16..137cb5a48a6 100644 --- a/libjava/classpath/java/lang/reflect/Proxy.java +++ b/libjava/classpath/java/lang/reflect/Proxy.java @@ -100,7 +100,7 @@ import java.util.Set; * belongs to the classloader you designated.</li> * <li>Reflection works as expected: {@link Class#getInterfaces()} and * {@link Class#getMethods()} work as they do on normal classes.</li> - * <li>The method {@link #isProxyClass()} will distinguish between + * <li>The method {@link #isProxyClass(Class)} will distinguish between * true proxy classes and user extensions of this class. It only * returns true for classes created by {@link #getProxyClass}.</li> * <li>The {@link ProtectionDomain} of a proxy class is the same as for @@ -111,8 +111,8 @@ import java.util.Set; * the only way to create an instance of the proxy class.</li> * <li>The proxy class contains a single constructor, which takes as * its only argument an {@link InvocationHandler}. The method - * {@link #newInstance} is shorthand to do the necessary - * reflection.</li> + * {@link #newProxyInstance(ClassLoader, Class[], InvocationHandler)} + * is shorthand to do the necessary reflection.</li> * </ul> * * <h3>Proxy Instances</h3> @@ -126,7 +126,7 @@ import java.util.Set; * a {@link ClassCastException}.</li> * <li>Each proxy instance has an invocation handler, which can be * accessed by {@link #getInvocationHandler(Object)}. Any call - * to an interface method, including {@link Object#hashcode()}, + * to an interface method, including {@link Object#hashCode()}, * {@link Object#equals(Object)}, or {@link Object#toString()}, * but excluding the public final methods of Object, will be * encoded and passed to the {@link InvocationHandler#invoke} @@ -413,8 +413,6 @@ public class Proxy implements Serializable */ ProxyType(ClassLoader loader, Class[] interfaces) { - if (loader == null) - loader = ClassLoader.getSystemClassLoader(); this.loader = loader; this.interfaces = interfaces; } @@ -426,8 +424,7 @@ public class Proxy implements Serializable */ public int hashCode() { - //loader is always not null - int hash = loader.hashCode(); + int hash = loader == null ? 0 : loader.hashCode(); for (int i = 0; i < interfaces.length; i++) hash = hash * 31 + interfaces[i].hashCode(); return hash; @@ -436,7 +433,7 @@ public class Proxy implements Serializable /** * Calculates equality. * - * @param the object to compare to + * @param other object to compare to * @return true if it is a ProxyType with same data */ public boolean equals(Object other) @@ -586,7 +583,7 @@ public class Proxy implements Serializable /** * Calculates equality. * - * @param the object to compare to + * @param other object to compare to * @return true if it is a ProxySignature with same data */ public boolean equals(Object other) @@ -617,7 +614,7 @@ public class Proxy implements Serializable * The package this class is in <b>including the trailing dot</b> * or an empty string for the unnamed (aka default) package. */ - String pack; + String pack = ""; /** * The interfaces this class implements. Non-null, but possibly empty. diff --git a/libjava/classpath/java/lang/reflect/UndeclaredThrowableException.java b/libjava/classpath/java/lang/reflect/UndeclaredThrowableException.java index 6d5a8008459..ea574ad7c61 100644 --- a/libjava/classpath/java/lang/reflect/UndeclaredThrowableException.java +++ b/libjava/classpath/java/lang/reflect/UndeclaredThrowableException.java @@ -65,7 +65,7 @@ public class UndeclaredThrowableException extends RuntimeException /** * The immutable exception that this wraps. This field is redundant - * with {@link Throwable#cause}, but is necessary for serial compatibility. + * with {@link Throwable#getCause()}, but is necessary for serial compatibility. * * @serial the chained exception */ |

