KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > myfaces > taglib > html > HtmlOutputLinkTagBase


1 /*
2  * Copyright 2004 The Apache Software Foundation.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */

16 package org.apache.myfaces.taglib.html;
17
18 import org.apache.myfaces.renderkit.html.HTML;
19
20 import javax.faces.component.UIComponent;
21
22
23 /**
24  * @author Manfred Geiler (latest modification by $Author: matzew $)
25  * @author Martin Marinschek
26  * @version $Revision: 1.4 $ $Date: 2005/02/18 18:24:35 $
27  * $Log: HtmlOutputLinkTagBase.java,v $
28  * Revision 1.4 2005/02/18 18:24:35 matzew
29  * added release() to tag clazzes.
30  *
31  * Revision 1.3 2004/10/13 11:51:01 matze
32  * renamed packages to org.apache
33  *
34  * Revision 1.2 2004/07/01 22:01:11 mwessendorf
35  * ASF switch
36  *
37  * Revision 1.1 2004/04/01 12:57:44 manolito
38  * additional extended component classes for user role support
39  *
40  */

41 public abstract class HtmlOutputLinkTagBase
42     extends HtmlComponentTagBase
43 {
44     // UIComponent attributes --> already implemented in UIComponentTagBase
45

46     // user role attributes --> already implemented in UIComponentTagBase
47

48     // HTML universal attributes --> already implemented in HtmlComponentTagBase
49

50     // HTML event handler attributes --> already implemented in HtmlComponentTagBase
51

52     // HTML anchor attributes relevant for command link
53
private String JavaDoc _accesskey;
54     private String JavaDoc _charset;
55     private String JavaDoc _coords;
56     private String JavaDoc _hreflang;
57     private String JavaDoc _rel;
58     private String JavaDoc _rev;
59     private String JavaDoc _shape;
60     private String JavaDoc _tabindex;
61     private String JavaDoc _target;
62     private String JavaDoc _type;
63     //FIXME: is mentioned in JSF API, but is no official anchor-attribute of HTML 4.0... what to do?
64
private String JavaDoc _onblur;
65     //FIXME: is mentioned in JSF API, but is no official anchor-attribute of HTML 4.0... what to do?
66
private String JavaDoc _onfocus;
67
68     // UIOutput attributes
69
// value and converterId --> already implemented in UIComponentTagBase
70

71     //HtmlCommandLink Attributes
72

73     public void release() {
74         super.release();
75         _accesskey=null;
76         _charset=null;
77         _coords=null;
78         _hreflang=null;
79         _rel=null;
80         _rev=null;
81         _shape=null;
82         _tabindex=null;
83         _target=null;
84         _type=null;
85         _onblur=null;
86         _onfocus=null;
87     }
88
89     protected void setProperties(UIComponent component)
90     {
91         super.setProperties(component);
92
93         setStringProperty(component, HTML.ACCESSKEY_ATTR, _accesskey);
94         setStringProperty(component, HTML.CHARSET_ATTR, _charset);
95         setStringProperty(component, HTML.COORDS_ATTR, _coords);
96         setStringProperty(component, HTML.HREFLANG_ATTR, _hreflang);
97         setStringProperty(component, HTML.REL_ATTR, _rel);
98         setStringProperty(component, HTML.REV_ATTR, _rev);
99         setStringProperty(component, HTML.SHAPE_ATTR, _shape);
100         setStringProperty(component, HTML.TABINDEX_ATTR, _tabindex);
101         setStringProperty(component, HTML.TARGET_ATTR, _target);
102         setStringProperty(component, HTML.TYPE_ATTR, _type);
103         setStringProperty(component, HTML.ONBLUR_ATTR, _onblur);
104         setStringProperty(component, HTML.ONFOCUS_ATTR, _onfocus);
105    }
106
107     public void setAccesskey(String JavaDoc accesskey)
108     {
109         _accesskey = accesskey;
110     }
111
112     public void setCharset(String JavaDoc charset)
113     {
114         _charset = charset;
115     }
116
117     public void setCoords(String JavaDoc coords)
118     {
119         _coords = coords;
120     }
121
122     public void setHreflang(String JavaDoc hreflang)
123     {
124         _hreflang = hreflang;
125     }
126
127     public void setOnblur(String JavaDoc onblur)
128     {
129         _onblur = onblur;
130     }
131
132     public void setOnfocus(String JavaDoc onfocus)
133     {
134         _onfocus = onfocus;
135     }
136
137     public void setRel(String JavaDoc rel)
138     {
139         _rel = rel;
140     }
141
142     public void setRev(String JavaDoc rev)
143     {
144         _rev = rev;
145     }
146
147     public void setShape(String JavaDoc shape)
148     {
149         _shape = shape;
150     }
151
152     public void setTabindex(String JavaDoc tabindex)
153     {
154         _tabindex = tabindex;
155     }
156
157     public void setTarget(String JavaDoc target)
158     {
159         _target = target;
160     }
161
162     public void setType(String JavaDoc type)
163     {
164         _type = type;
165     }
166 }
167
Popular Tags