Index: PyJavaClass.java =================================================================== RCS file: /cvsroot/jython/jython/org/python/core/PyJavaClass.java,v retrieving revision 2.35 diff -u -r2.35 PyJavaClass.java --- PyJavaClass.java 2001/03/04 17:52:39 2.35 +++ PyJavaClass.java 2001/08/05 13:47:52 @@ -385,6 +385,16 @@ return declared; } + private boolean ignoreMethod(Method method) { + Class[] exceptions = method.getExceptionTypes(); + for (int j = 0; j < exceptions.length; j++) { + if (exceptions[j] == IgnoreMethodTag.class) { + return true; + } + } + return false; + } + /* Add all methods declared by this class */ private void setMethods(Class c, Method[] methods) { for (int i=0; i 0) { - __init__ = new PyReflectedConstructor(constructors[0]); - for (int i=1; i < constructors.length; i++) { + for (int i = 0; i < constructors.length; i++) { + if (ignoreConstructor(constructors[i])) { + continue; + } + if (__init__ == null) { + __init__ = new PyReflectedConstructor(constructors[i]); + } else { __init__.addConstructor(constructors[i]); } + } + if (__init__ != null) { __dict__.__setitem__("__init__", __init__); } } --- IgnoreMethodTag.java Sun Aug 05 14:40:53 2001 +++ IgnoreMethodTag.java Sun Aug 05 14:40:53 2001 @@ -0,0 +1,6 @@ + +package org.python.core; + +public class IgnoreMethodTag extends RuntimeException { +} +