Skip to content

Commit a48900c

Browse files
hansonrhansonr
authored andcommitted
Class.java removing native references for now; not implementing
getDeclaringClass, setSigners, and getSigners
1 parent bbefa98 commit a48900c

File tree

1 file changed

+15
-6
lines changed
  • sources/net.sf.j2s.java.core/src/java/lang

1 file changed

+15
-6
lines changed

sources/net.sf.j2s.java.core/src/java/lang/Class.java

Lines changed: 15 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,6 @@
2929
import java.lang.reflect.Constructor;
3030
import java.lang.reflect.Field;
3131
import java.lang.reflect.GenericSignatureFormatError;
32-
//import java.lang.reflect.GenericSignatureFormatError;
33-
import java.lang.reflect.InvocationTargetException;
3432
import java.lang.reflect.Member;
3533
import java.lang.reflect.Method;
3634
import java.lang.reflect.Modifier;
@@ -901,7 +899,10 @@ public Class<? super T> getSuperclass() {
901899
*
902900
* @return an array of interfaces implemented by this class.
903901
*/
904-
public native Class<?>[] getInterfaces();
902+
public Class<?>[] getInterfaces() {
903+
JSUtil.notImplemented(null);
904+
return new Class<?>[0];
905+
}
905906

906907
// /**
907908
// * Returns the {@code Type}s representing the interfaces directly
@@ -1012,12 +1013,17 @@ public int getModifiers() {
10121013
* primitive type or void.
10131014
* @since JDK1.1
10141015
*/
1015-
public native Object[] getSigners();
1016+
public Object[] getSigners() {
1017+
JSUtil.notImplemented(null);
1018+
return new Object[0];
1019+
}
10161020

10171021
/**
10181022
* Set the signers of this class.
10191023
*/
1020-
native void setSigners(Object[] signers);
1024+
void setSigners(Object[] signers) {
1025+
JSUtil.notImplemented(null);
1026+
};
10211027

10221028
// /**
10231029
// * If this {@code Class} object represents a local or anonymous class within
@@ -1220,7 +1226,10 @@ public int getModifiers() {
12201226
* @return the declaring class for this class
12211227
* @since JDK1.1
12221228
*/
1223-
public native Class<?> getDeclaringClass();
1229+
public Class<?> getDeclaringClass() {
1230+
JSUtil.notImplemented(null);
1231+
return null;
1232+
};
12241233

12251234
// /**
12261235
// * Returns the immediately enclosing class of the underlying class. If the

0 commit comments

Comments
 (0)