1 Clazz.declarePackage ("javax.swing.event");
\r
2 Clazz.load (["java.util.EventObject"], "javax.swing.event.TreeModelEvent", ["java.lang.StringBuffer", "javax.swing.tree.TreePath"], function () {
\r
3 c$ = Clazz.decorateAsClass (function () {
\r
5 this.childIndices = null;
\r
6 this.children = null;
\r
7 Clazz.instantialize (this, arguments);
\r
8 }, javax.swing.event, "TreeModelEvent", java.util.EventObject);
\r
9 Clazz.makeConstructor (c$,
\r
10 function (source, path, childIndices, children) {
\r
11 this.construct (source, new javax.swing.tree.TreePath (path), childIndices, children);
\r
13 Clazz.makeConstructor (c$,
\r
14 function (source, path, childIndices, children) {
\r
15 Clazz.superConstructor (this, javax.swing.event.TreeModelEvent, [source]);
\r
17 this.childIndices = childIndices;
\r
18 this.children = children;
\r
19 }, "~O,javax.swing.tree.TreePath,~A,~A");
\r
20 Clazz.makeConstructor (c$,
\r
21 function (source, path) {
\r
22 this.construct (source, new javax.swing.tree.TreePath (path));
\r
24 Clazz.makeConstructor (c$,
\r
25 function (source, path) {
\r
26 Clazz.superConstructor (this, javax.swing.event.TreeModelEvent, [source]);
\r
28 this.childIndices = Clazz.newIntArray (0, 0);
\r
29 }, "~O,javax.swing.tree.TreePath");
\r
30 Clazz.defineMethod (c$, "getTreePath",
\r
34 Clazz.defineMethod (c$, "getPath",
\r
36 if (this.path != null) return this.path.getPath ();
\r
39 Clazz.defineMethod (c$, "getChildren",
\r
41 if (this.children != null) {
\r
42 var cCount = this.children.length;
\r
43 var retChildren = new Array (cCount);
\r
44 System.arraycopy (this.children, 0, retChildren, 0, cCount);
\r
48 Clazz.defineMethod (c$, "getChildIndices",
\r
50 if (this.childIndices != null) {
\r
51 var cCount = this.childIndices.length;
\r
52 var retArray = Clazz.newIntArray (cCount, 0);
\r
53 System.arraycopy (this.childIndices, 0, retArray, 0, cCount);
\r
57 Clazz.overrideMethod (c$, "toString",
\r
59 var retBuffer = new StringBuffer ();
\r
60 retBuffer.append (this.getClass ().getName () + " " + Integer.toString (this.hashCode ()));
\r
61 if (this.path != null) retBuffer.append (" path " + this.path);
\r
62 if (this.childIndices != null) {
\r
63 retBuffer.append (" indices [ ");
\r
64 for (var counter = 0; counter < this.childIndices.length; counter++) retBuffer.append (Integer.toString (this.childIndices[counter]) + " ");
\r
66 retBuffer.append ("]");
\r
67 }if (this.children != null) {
\r
68 retBuffer.append (" children [ ");
\r
69 for (var counter = 0; counter < this.children.length; counter++) retBuffer.append (this.children[counter] + " ");
\r
71 retBuffer.append ("]");
\r
72 }return retBuffer.toString ();
\r