Skip to content

Commit 6f79541

Browse files
committed
j2sClazz.js adding constructors for Throwable
1 parent b816360 commit 6f79541

File tree

1 file changed

+5
-18
lines changed

1 file changed

+5
-18
lines changed

sources/net.sf.j2s.java.core/srcjs/js/j2sClazz.js

Lines changed: 5 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -5314,6 +5314,10 @@ var setEx = function(C$) {
53145314
C$.$clinit$ = function() {Clazz.load(C$, 1);}
53155315
m$(C$, "c$", function() { C$.superclazz.c$.apply(this, []);}, 1);
53165316
m$(C$, "c$$S", function(detailMessage){C$.superclazz.c$$S.apply(this,[detailMessage]);},1);
5317+
m$(C$, "c$$Throwable", function(exception){C$.superclazz.c$$Throwable.apply(this, arguments);}, 1);
5318+
m$(C$, "c$$S$Throwable", function(detailMessage,exception){C$.superclazz.c$$S$Throwable.apply(this, arguments);
5319+
}, 1);
5320+
53175321
return C$;
53185322
}
53195323

@@ -5322,31 +5326,14 @@ var C$ = Clazz.newClass(java.lang, "Error", function (){
53225326
var err = Clazz._Error();
53235327
return err;
53245328
}, Throwable);
5325-
5326-
//setSuperclass(java.lang.Error, Throwable);
5327-
//setSuperclass(Clazz._Error, Throwable);
5328-
53295329
setEx(C$);
5330-
53315330
})();
53325331

53335332
var newEx = function(prefix, name, clazzSuper) {
53345333
return setEx(declareType(prefix, name, clazzSuper));
53355334
}
53365335

5337-
;(function() {
5338-
var C$ = newEx(java.lang,"Exception",Throwable);
5339-
m$(C$, "c$", function(){}, 1);
5340-
m$(C$, "c$$S", function(detailMessage){
5341-
C$.superclazz.c$$S.apply(this, arguments);
5342-
}, 1);
5343-
m$(C$, "c$$Throwable", function(exception){
5344-
C$.superclazz.c$$Throwable.apply(this, arguments);
5345-
}, 1);
5346-
m$(C$, "c$$S$Throwable", function(detailMessage,exception){
5347-
C$.superclazz.c$$S$Throwable.apply(this, arguments);
5348-
}, 1);
5349-
})();
5336+
newEx(java.lang,"Exception",Throwable);
53505337

53515338
newEx(java.lang,"RuntimeException",Exception);
53525339
newEx(java.lang,"IllegalArgumentException",RuntimeException);

0 commit comments

Comments
 (0)