e7ed0dda315e0aa0529338d8b8ac858d4bca1893
[jalviewjs.git] / site / swingjs / j2s / org / xml / sax / SAXException.js
1 Clazz.declarePackage ("org.xml.sax");
2 Clazz.load (["java.lang.Exception"], "org.xml.sax.SAXException", null, function () {
3 c$ = Clazz.decorateAsClass (function () {
4 this.exception = null;
5 Clazz.instantialize (this, arguments);
6 }, org.xml.sax, "SAXException", Exception);
7 Clazz.makeConstructor (c$, 
8 function () {
9 Clazz.superConstructor (this, org.xml.sax.SAXException);
10 this.exception = null;
11 });
12 Clazz.makeConstructor (c$, 
13 function (message) {
14 Clazz.superConstructor (this, org.xml.sax.SAXException, [message]);
15 this.exception = null;
16 }, "~S");
17 Clazz.makeConstructor (c$, 
18 function (e) {
19 Clazz.superConstructor (this, org.xml.sax.SAXException);
20 this.exception = e;
21 }, "Exception");
22 Clazz.makeConstructor (c$, 
23 function (message, e) {
24 Clazz.superConstructor (this, org.xml.sax.SAXException, [message]);
25 this.exception = e;
26 }, "~S,Exception");
27 Clazz.defineMethod (c$, "getMessage", 
28 function () {
29 var message = Clazz.superCall (this, org.xml.sax.SAXException, "getMessage", []);
30 if (message == null && this.exception != null) {
31 return this.exception.getMessage ();
32 } else {
33 return message;
34 }});
35 Clazz.defineMethod (c$, "getException", 
36 function () {
37 return this.exception;
38 });
39 Clazz.defineMethod (c$, "toString", 
40 function () {
41 if (this.exception != null) {
42 return this.exception.toString ();
43 } else {
44 return Clazz.superCall (this, org.xml.sax.SAXException, "toString", []);
45 }});
46 });