1 | |
|
2 | |
|
3 | |
|
4 | |
|
5 | |
|
6 | |
|
7 | |
|
8 | |
|
9 | |
|
10 | |
|
11 | |
|
12 | |
|
13 | |
|
14 | |
|
15 | |
|
16 | |
|
17 | |
|
18 | |
|
19 | |
package javax.faces.component.html; |
20 | |
|
21 | |
import javax.faces.el.ValueBinding; |
22 | |
import javax.el.ValueExpression; |
23 | |
import javax.faces.context.FacesContext; |
24 | |
import javax.faces.component.UIComponent; |
25 | |
import javax.faces.convert.Converter; |
26 | |
|
27 | |
|
28 | |
|
29 | |
|
30 | |
|
31 | |
|
32 | |
public class HtmlOutputLink extends javax.faces.component.UIOutput |
33 | |
implements javax.faces.component.behavior.ClientBehaviorHolder |
34 | |
{ |
35 | |
|
36 | |
static public final String COMPONENT_FAMILY = |
37 | |
"javax.faces.Output"; |
38 | |
static public final String COMPONENT_TYPE = |
39 | |
"javax.faces.HtmlOutputLink"; |
40 | |
|
41 | |
|
42 | |
public HtmlOutputLink() |
43 | 2 | { |
44 | 2 | setRendererType("javax.faces.Link"); |
45 | 2 | } |
46 | |
|
47 | |
@Override |
48 | |
public String getFamily() |
49 | |
{ |
50 | 0 | return COMPONENT_FAMILY; |
51 | |
} |
52 | |
|
53 | |
|
54 | 2 | static private final java.util.Collection<String> CLIENT_EVENTS_LIST = |
55 | |
java.util.Collections.unmodifiableCollection( |
56 | |
java.util.Arrays.asList( |
57 | |
"blur" |
58 | |
, "focus" |
59 | |
, "click" |
60 | |
, "dblclick" |
61 | |
, "keydown" |
62 | |
, "keypress" |
63 | |
, "keyup" |
64 | |
, "mousedown" |
65 | |
, "mousemove" |
66 | |
, "mouseout" |
67 | |
, "mouseover" |
68 | |
, "mouseup" |
69 | |
)); |
70 | |
|
71 | |
public java.util.Collection<String> getEventNames() |
72 | |
{ |
73 | 0 | return CLIENT_EVENTS_LIST; |
74 | |
} |
75 | |
|
76 | |
@Override |
77 | |
public void addClientBehavior(String eventName, javax.faces.component.behavior.ClientBehavior behavior) |
78 | |
{ |
79 | 0 | super.addClientBehavior(eventName, behavior); |
80 | 0 | _CommonEventConstants.markEvent(this, eventName); |
81 | 0 | } |
82 | |
|
83 | |
|
84 | |
|
85 | |
|
86 | |
public String getFragment() |
87 | |
{ |
88 | 0 | return (String) getStateHelper().eval(PropertyKeys.fragment); |
89 | |
} |
90 | |
|
91 | |
public void setFragment(String fragment) |
92 | |
{ |
93 | 0 | getStateHelper().put(PropertyKeys.fragment, fragment ); |
94 | 0 | } |
95 | |
|
96 | |
|
97 | |
public String getStyle() |
98 | |
{ |
99 | 0 | return (String) getStateHelper().eval(PropertyKeys.style); |
100 | |
} |
101 | |
|
102 | |
public void setStyle(String style) |
103 | |
{ |
104 | 0 | getStateHelper().put(PropertyKeys.style, style ); |
105 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.STYLE_PROP); |
106 | 0 | } |
107 | |
|
108 | |
|
109 | |
public String getStyleClass() |
110 | |
{ |
111 | 0 | return (String) getStateHelper().eval(PropertyKeys.styleClass); |
112 | |
} |
113 | |
|
114 | |
public void setStyleClass(String styleClass) |
115 | |
{ |
116 | 0 | getStateHelper().put(PropertyKeys.styleClass, styleClass ); |
117 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.STYLECLASS_PROP); |
118 | 0 | } |
119 | |
|
120 | |
|
121 | |
public String getTabindex() |
122 | |
{ |
123 | 0 | return (String) getStateHelper().eval(PropertyKeys.tabindex); |
124 | |
} |
125 | |
|
126 | |
public void setTabindex(String tabindex) |
127 | |
{ |
128 | 0 | getStateHelper().put(PropertyKeys.tabindex, tabindex ); |
129 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.TABINDEX_PROP); |
130 | 0 | } |
131 | |
|
132 | |
|
133 | |
public String getOnblur() |
134 | |
{ |
135 | 0 | return (String) getStateHelper().eval(PropertyKeys.onblur); |
136 | |
} |
137 | |
|
138 | |
public void setOnblur(String onblur) |
139 | |
{ |
140 | 0 | getStateHelper().put(PropertyKeys.onblur, onblur ); |
141 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.ONBLUR_PROP); |
142 | 0 | } |
143 | |
|
144 | |
|
145 | |
public String getOnfocus() |
146 | |
{ |
147 | 0 | return (String) getStateHelper().eval(PropertyKeys.onfocus); |
148 | |
} |
149 | |
|
150 | |
public void setOnfocus(String onfocus) |
151 | |
{ |
152 | 0 | getStateHelper().put(PropertyKeys.onfocus, onfocus ); |
153 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.ONFOCUS_PROP); |
154 | 0 | } |
155 | |
|
156 | |
|
157 | |
public String getAccesskey() |
158 | |
{ |
159 | 0 | return (String) getStateHelper().eval(PropertyKeys.accesskey); |
160 | |
} |
161 | |
|
162 | |
public void setAccesskey(String accesskey) |
163 | |
{ |
164 | 0 | getStateHelper().put(PropertyKeys.accesskey, accesskey ); |
165 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.ACCESSKEY_PROP); |
166 | 0 | } |
167 | |
|
168 | |
|
169 | |
public String getRole() |
170 | |
{ |
171 | 0 | return (String) getStateHelper().eval(PropertyKeys.role); |
172 | |
} |
173 | |
|
174 | |
public void setRole(String role) |
175 | |
{ |
176 | 0 | getStateHelper().put(PropertyKeys.role, role ); |
177 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.ROLE_PROP); |
178 | 0 | } |
179 | |
|
180 | |
|
181 | |
public String getOnclick() |
182 | |
{ |
183 | 0 | return (String) getStateHelper().eval(PropertyKeys.onclick); |
184 | |
} |
185 | |
|
186 | |
public void setOnclick(String onclick) |
187 | |
{ |
188 | 0 | getStateHelper().put(PropertyKeys.onclick, onclick ); |
189 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.ONCLICK_PROP); |
190 | 0 | } |
191 | |
|
192 | |
|
193 | |
public String getOndblclick() |
194 | |
{ |
195 | 0 | return (String) getStateHelper().eval(PropertyKeys.ondblclick); |
196 | |
} |
197 | |
|
198 | |
public void setOndblclick(String ondblclick) |
199 | |
{ |
200 | 0 | getStateHelper().put(PropertyKeys.ondblclick, ondblclick ); |
201 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.ONDBLCLICK_PROP); |
202 | 0 | } |
203 | |
|
204 | |
|
205 | |
public String getOnkeydown() |
206 | |
{ |
207 | 0 | return (String) getStateHelper().eval(PropertyKeys.onkeydown); |
208 | |
} |
209 | |
|
210 | |
public void setOnkeydown(String onkeydown) |
211 | |
{ |
212 | 0 | getStateHelper().put(PropertyKeys.onkeydown, onkeydown ); |
213 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.ONKEYDOWN_PROP); |
214 | 0 | } |
215 | |
|
216 | |
|
217 | |
public String getOnkeypress() |
218 | |
{ |
219 | 0 | return (String) getStateHelper().eval(PropertyKeys.onkeypress); |
220 | |
} |
221 | |
|
222 | |
public void setOnkeypress(String onkeypress) |
223 | |
{ |
224 | 0 | getStateHelper().put(PropertyKeys.onkeypress, onkeypress ); |
225 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.ONKEYPRESS_PROP); |
226 | 0 | } |
227 | |
|
228 | |
|
229 | |
public String getOnkeyup() |
230 | |
{ |
231 | 0 | return (String) getStateHelper().eval(PropertyKeys.onkeyup); |
232 | |
} |
233 | |
|
234 | |
public void setOnkeyup(String onkeyup) |
235 | |
{ |
236 | 0 | getStateHelper().put(PropertyKeys.onkeyup, onkeyup ); |
237 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.ONKEYUP_PROP); |
238 | 0 | } |
239 | |
|
240 | |
|
241 | |
public String getOnmousedown() |
242 | |
{ |
243 | 0 | return (String) getStateHelper().eval(PropertyKeys.onmousedown); |
244 | |
} |
245 | |
|
246 | |
public void setOnmousedown(String onmousedown) |
247 | |
{ |
248 | 0 | getStateHelper().put(PropertyKeys.onmousedown, onmousedown ); |
249 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.ONMOUSEDOWN_PROP); |
250 | 0 | } |
251 | |
|
252 | |
|
253 | |
public String getOnmousemove() |
254 | |
{ |
255 | 0 | return (String) getStateHelper().eval(PropertyKeys.onmousemove); |
256 | |
} |
257 | |
|
258 | |
public void setOnmousemove(String onmousemove) |
259 | |
{ |
260 | 0 | getStateHelper().put(PropertyKeys.onmousemove, onmousemove ); |
261 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.ONMOUSEMOVE_PROP); |
262 | 0 | } |
263 | |
|
264 | |
|
265 | |
public String getOnmouseout() |
266 | |
{ |
267 | 0 | return (String) getStateHelper().eval(PropertyKeys.onmouseout); |
268 | |
} |
269 | |
|
270 | |
public void setOnmouseout(String onmouseout) |
271 | |
{ |
272 | 0 | getStateHelper().put(PropertyKeys.onmouseout, onmouseout ); |
273 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.ONMOUSEOUT_PROP); |
274 | 0 | } |
275 | |
|
276 | |
|
277 | |
public String getOnmouseover() |
278 | |
{ |
279 | 0 | return (String) getStateHelper().eval(PropertyKeys.onmouseover); |
280 | |
} |
281 | |
|
282 | |
public void setOnmouseover(String onmouseover) |
283 | |
{ |
284 | 0 | getStateHelper().put(PropertyKeys.onmouseover, onmouseover ); |
285 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.ONMOUSEOVER_PROP); |
286 | 0 | } |
287 | |
|
288 | |
|
289 | |
public String getOnmouseup() |
290 | |
{ |
291 | 0 | return (String) getStateHelper().eval(PropertyKeys.onmouseup); |
292 | |
} |
293 | |
|
294 | |
public void setOnmouseup(String onmouseup) |
295 | |
{ |
296 | 0 | getStateHelper().put(PropertyKeys.onmouseup, onmouseup ); |
297 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.ONMOUSEUP_PROP); |
298 | 0 | } |
299 | |
|
300 | |
|
301 | |
public String getDir() |
302 | |
{ |
303 | 0 | return (String) getStateHelper().eval(PropertyKeys.dir); |
304 | |
} |
305 | |
|
306 | |
public void setDir(String dir) |
307 | |
{ |
308 | 0 | getStateHelper().put(PropertyKeys.dir, dir ); |
309 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.DIR_PROP); |
310 | 0 | } |
311 | |
|
312 | |
|
313 | |
public String getLang() |
314 | |
{ |
315 | 0 | return (String) getStateHelper().eval(PropertyKeys.lang); |
316 | |
} |
317 | |
|
318 | |
public void setLang(String lang) |
319 | |
{ |
320 | 0 | getStateHelper().put(PropertyKeys.lang, lang ); |
321 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.LANG_PROP); |
322 | 0 | } |
323 | |
|
324 | |
|
325 | |
public String getTitle() |
326 | |
{ |
327 | 0 | return (String) getStateHelper().eval(PropertyKeys.title); |
328 | |
} |
329 | |
|
330 | |
public void setTitle(String title) |
331 | |
{ |
332 | 0 | getStateHelper().put(PropertyKeys.title, title ); |
333 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.TITLE_PROP); |
334 | 0 | } |
335 | |
|
336 | |
|
337 | |
public String getCharset() |
338 | |
{ |
339 | 0 | return (String) getStateHelper().eval(PropertyKeys.charset); |
340 | |
} |
341 | |
|
342 | |
public void setCharset(String charset) |
343 | |
{ |
344 | 0 | getStateHelper().put(PropertyKeys.charset, charset ); |
345 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.CHARSET_PROP); |
346 | 0 | } |
347 | |
|
348 | |
|
349 | |
public String getCoords() |
350 | |
{ |
351 | 0 | return (String) getStateHelper().eval(PropertyKeys.coords); |
352 | |
} |
353 | |
|
354 | |
public void setCoords(String coords) |
355 | |
{ |
356 | 0 | getStateHelper().put(PropertyKeys.coords, coords ); |
357 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.COORDS_PROP); |
358 | 0 | } |
359 | |
|
360 | |
|
361 | |
public String getHreflang() |
362 | |
{ |
363 | 0 | return (String) getStateHelper().eval(PropertyKeys.hreflang); |
364 | |
} |
365 | |
|
366 | |
public void setHreflang(String hreflang) |
367 | |
{ |
368 | 0 | getStateHelper().put(PropertyKeys.hreflang, hreflang ); |
369 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.HREFLANG_PROP); |
370 | 0 | } |
371 | |
|
372 | |
|
373 | |
public String getRel() |
374 | |
{ |
375 | 0 | return (String) getStateHelper().eval(PropertyKeys.rel); |
376 | |
} |
377 | |
|
378 | |
public void setRel(String rel) |
379 | |
{ |
380 | 0 | getStateHelper().put(PropertyKeys.rel, rel ); |
381 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.REL_PROP); |
382 | 0 | } |
383 | |
|
384 | |
|
385 | |
public String getRev() |
386 | |
{ |
387 | 0 | return (String) getStateHelper().eval(PropertyKeys.rev); |
388 | |
} |
389 | |
|
390 | |
public void setRev(String rev) |
391 | |
{ |
392 | 0 | getStateHelper().put(PropertyKeys.rev, rev ); |
393 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.REV_PROP); |
394 | 0 | } |
395 | |
|
396 | |
|
397 | |
public String getShape() |
398 | |
{ |
399 | 0 | return (String) getStateHelper().eval(PropertyKeys.shape); |
400 | |
} |
401 | |
|
402 | |
public void setShape(String shape) |
403 | |
{ |
404 | 0 | getStateHelper().put(PropertyKeys.shape, shape ); |
405 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.SHAPE_PROP); |
406 | 0 | } |
407 | |
|
408 | |
|
409 | |
public String getTarget() |
410 | |
{ |
411 | 0 | return (String) getStateHelper().eval(PropertyKeys.target); |
412 | |
} |
413 | |
|
414 | |
public void setTarget(String target) |
415 | |
{ |
416 | 0 | getStateHelper().put(PropertyKeys.target, target ); |
417 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.TARGET_PROP); |
418 | 0 | } |
419 | |
|
420 | |
|
421 | |
public String getType() |
422 | |
{ |
423 | 0 | return (String) getStateHelper().eval(PropertyKeys.type); |
424 | |
} |
425 | |
|
426 | |
public void setType(String type) |
427 | |
{ |
428 | 0 | getStateHelper().put(PropertyKeys.type, type ); |
429 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.TYPE_PROP); |
430 | 0 | } |
431 | |
|
432 | |
|
433 | |
public boolean isDisabled() |
434 | |
{ |
435 | 0 | return (Boolean) getStateHelper().eval(PropertyKeys.disabled, false); |
436 | |
} |
437 | |
|
438 | |
public void setDisabled(boolean disabled) |
439 | |
{ |
440 | 0 | getStateHelper().put(PropertyKeys.disabled, disabled ); |
441 | 0 | _CommonPropertyConstants.markProperty(this, _CommonPropertyConstants.DISABLED_PROP); |
442 | 0 | } |
443 | |
|
444 | |
public void setValueBinding(String name, ValueBinding binding) |
445 | |
{ |
446 | 0 | super.setValueBinding(name, binding); |
447 | 0 | _CommonPropertyConstants.markProperty(this, name); |
448 | 0 | } |
449 | |
|
450 | |
public void setValueExpression(String name, ValueExpression expression) |
451 | |
{ |
452 | 0 | super.setValueExpression(name, expression); |
453 | 0 | _CommonPropertyConstants.markProperty(this, name); |
454 | 0 | } |
455 | |
|
456 | 0 | protected enum PropertyKeys |
457 | |
{ |
458 | 0 | fragment |
459 | 0 | , style |
460 | 0 | , styleClass |
461 | 0 | , tabindex |
462 | 0 | , onblur |
463 | 0 | , onfocus |
464 | 0 | , accesskey |
465 | 0 | , role |
466 | 0 | , onclick |
467 | 0 | , ondblclick |
468 | 0 | , onkeydown |
469 | 0 | , onkeypress |
470 | 0 | , onkeyup |
471 | 0 | , onmousedown |
472 | 0 | , onmousemove |
473 | 0 | , onmouseout |
474 | 0 | , onmouseover |
475 | 0 | , onmouseup |
476 | 0 | , dir |
477 | 0 | , lang |
478 | 0 | , title |
479 | 0 | , charset |
480 | 0 | , coords |
481 | 0 | , hreflang |
482 | 0 | , rel |
483 | 0 | , rev |
484 | 0 | , shape |
485 | 0 | , target |
486 | 0 | , type |
487 | 0 | , disabled |
488 | |
} |
489 | |
|
490 | |
} |