1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43 package org.melati.util;
44
45 import org.melati.poem.Treeable;
46
47
48
49
50 public class JSStaticTree extends Tree {
51
52 private String backgroundColour = "FFFFFF";
53 private Integer depthPerDownload = new Integer(-1);
54 private String verticalLinkImage;
55 private String spacerImage;
56 private String openedFolderImage;
57 private String closedFolderImage;
58 private String openedTImage;
59 private String closedTImage;
60 private String openedLImage;
61 private String closedLImage;
62 private String leafTImage;
63 private String leafLImage;
64 private String leafImage;
65 private String imageBaseRef;
66
67
68
69
70
71
72
73
74
75 public JSStaticTree(Tree tree, String staticURL) {
76 super(tree.getTreeableRoots(), tree.getDepth());
77 verticalLinkImage = staticURL + "/vertline.gif";
78 spacerImage = staticURL + "/spacer.gif";
79 openedFolderImage = staticURL + "/openfolder.gif";
80 closedFolderImage = staticURL + "/closedfolder.gif";
81 openedTImage = staticURL + "/node_minus.gif";
82 closedTImage = staticURL + "/node_plus.gif";
83 openedLImage = staticURL + "/lastnode_minus.gif";
84 closedLImage = staticURL + "/lastnode_plus.gif";
85 leafTImage = staticURL + "/node.gif";
86 leafLImage = staticURL + "/last_node.gif";
87 leafImage = staticURL + "/file.gif";
88 imageBaseRef = staticURL;
89 }
90
91
92
93
94
95
96
97 public JSStaticTree(Treeable[] nodes, String staticURL) {
98 super(nodes);
99 verticalLinkImage = staticURL + "/vertline.gif";
100 spacerImage = staticURL + "/spacer.gif";
101 openedFolderImage = staticURL + "/openfolder.gif";
102 closedFolderImage = staticURL + "/closedfolder.gif";
103 openedTImage = staticURL + "/node_minus.gif";
104 closedTImage = staticURL + "/node_plus.gif";
105 openedLImage = staticURL + "/lastnode_minus.gif";
106 closedLImage = staticURL + "/lastnode_plus.gif";
107 leafTImage = staticURL + "/node.gif";
108 leafLImage = staticURL + "/last_node.gif";
109 leafImage = staticURL + "/file.gif";
110 imageBaseRef = staticURL;
111 }
112
113
114
115
116 public String getBackgroundColour() {
117 return backgroundColour;
118 }
119
120
121
122
123
124
125 public void setBackgroundColour(String bg) {
126 backgroundColour = bg;
127 }
128
129
130
131
132 public String getVerticalLinkImage() {
133 return verticalLinkImage;
134 }
135
136
137
138
139
140 public void setVerticalLinkImage(String vli) {
141 verticalLinkImage = vli;
142 }
143
144
145
146
147 public String getSpacerImage() {
148 return spacerImage;
149 }
150
151
152
153
154
155 public void setSpacerImage(String si) {
156 spacerImage = si;
157 }
158
159
160
161
162 public String getOpenedFolderImage() {
163 return openedFolderImage;
164 }
165
166
167
168
169
170 public void setOpenedFolderImage(String ofi) {
171 openedFolderImage = ofi;
172 }
173
174
175
176
177 public String getClosedFolderImage() {
178 return closedFolderImage;
179 }
180
181
182
183
184
185 public void setClosedFolderImage(String cfi) {
186 closedFolderImage = cfi;
187 }
188
189
190
191
192 public String getOpenedTImage() {
193 return openedTImage;
194 }
195
196
197
198
199
200 public void setOpenedTImage(String oti) {
201 openedTImage = oti;
202 }
203
204
205
206
207 public String getOpenedLImage() {
208 return openedLImage;
209 }
210
211
212
213
214
215 public void setOpenedLImage(String oli) {
216 openedLImage = oli;
217 }
218
219
220
221
222 public String getClosedTImage() {
223 return closedTImage;
224 }
225
226
227
228
229
230 public void setClosedTImage(String cti) {
231 closedTImage = cti;
232 }
233
234
235
236
237 public String getClosedLImage() {
238 return closedLImage;
239 }
240
241
242
243
244
245 public void setClosedLImage(String cli) {
246 closedLImage = cli;
247 }
248
249
250
251
252 public String getLeafTImage() {
253 return leafTImage;
254 }
255
256
257
258
259
260 public void setLeafTImage(String lti) {
261 leafTImage = lti;
262 }
263
264
265
266
267 public String getLeafLImage() {
268 return leafLImage;
269 }
270
271
272
273
274
275 public void setLeafLImage(String lli) {
276 leafLImage = lli;
277 }
278
279
280
281
282 public String getLeafImage() {
283 return leafImage;
284 }
285
286
287
288
289
290 public void setLeafImage(String li) {
291 leafImage = li;
292 }
293
294
295
296
297 public String getImageBaseRef() {
298 return imageBaseRef;
299 }
300
301
302
303
304
305 public void setImageBaseRef(String ibr) {
306 imageBaseRef = ibr;
307 }
308
309
310
311
312 public Integer getDepthPerDownload() {
313 return depthPerDownload;
314 }
315
316
317
318
319
320 public void setDepthPerDownload(Integer dpd) {
321 depthPerDownload = dpd;
322 }
323
324 }