summaryrefslogtreecommitdiff
path: root/libjava/java/lang/reflect/Method.java
diff options
context:
space:
mode:
authorAndrew Haley <aph@redhat.com>2007-03-05 16:06:27 +0000
committerAndrew Haley <aph@gcc.gnu.org>2007-03-05 16:06:27 +0000
commita29114a3bec5458073c39a324324868d4bac2d24 (patch)
treedb2cc96f747dfe385b80f218bee0aca23560701e /libjava/java/lang/reflect/Method.java
parentf4a2a1deec8e1c2c8f9ed80d166a37341fbafd19 (diff)
natVMProxy.cc (ncode_closure.meth): Delete.
2007-03-05 Andrew Haley <aph@redhat.com> * java/lang/reflect/natVMProxy.cc (ncode_closure.meth): Delete. (generateProxyClass): Don't pass method to ncode. (run_proxy): Call _Jv_GetReflectedMethod to find the proxy method. * java/lang/reflect/Method.h: Rebuild. * java/lang/reflect/Method.java (internalGetParameterTypes, internalGetExceptionTypes): New methods. * headers.txt (class java/lang/reflect/Method): Declare _Jv_GetReflectedMethod. Be its friend. * java/lang/natClass.cc (_Jv_GetReflectedMethod): New method. * java/lang/Class.h: Declare it. Be its friend. From-SVN: r122554
Diffstat (limited to 'libjava/java/lang/reflect/Method.java')
-rw-r--r--libjava/java/lang/reflect/Method.java18
1 files changed, 18 insertions, 0 deletions
diff --git a/libjava/java/lang/reflect/Method.java b/libjava/java/lang/reflect/Method.java
index 6fa2956e40e..878210abbd2 100644
--- a/libjava/java/lang/reflect/Method.java
+++ b/libjava/java/lang/reflect/Method.java
@@ -153,6 +153,15 @@ public final class Method
return (Class<?>[]) parameter_types.clone();
}
+ // Just like getParameterTypes, but don't clone the array.
+ // Package private for use by VMProxy.
+ final Class<?>[] internalGetParameterTypes ()
+ {
+ if (parameter_types == null)
+ getType();
+ return (Class<?>[]) parameter_types;
+ }
+
/**
* Get the exception types this method says it throws, in no particular
* order. If the method has no throws clause, returns a 0-length array
@@ -167,6 +176,15 @@ public final class Method
return (Class<?>[]) exception_types.clone();
}
+ // Just like getExceptionTypes, but don't clone the array.
+ // Package private for use by VMProxy.
+ final Class<?>[] internalGetExceptionTypes ()
+ {
+ if (exception_types == null)
+ getType();
+ return (Class<?>[]) exception_types;
+ }
+
/**
* Compare two objects to see if they are semantically equivalent.
* Two Methods are semantically equivalent if they have the same declaring