1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18 package org.apache.strutsel.taglib.html;
19
20 import java.beans.IntrospectionException;
21 import java.beans.PropertyDescriptor;
22 import java.beans.SimpleBeanInfo;
23
24 import java.util.ArrayList;
25
26 /***
27 * This is the <code>BeanInfo</code> descriptor for the
28 * <code>org.apache.strutsel.taglib.html.ELMultiboxTag</code> class. It is
29 * needed to override the default mapping of custom tag attribute names to
30 * class attribute names. <p> In particular, it provides for the mapping of
31 * the custom tag attribute <code>disabled</code> to the instance variable
32 * <code>disabledExpr</code>. <p> This is because the value of the unevaluated
33 * EL expression has to be kept separately from the evaluated value, which is
34 * stored in the base class. This is related to the fact that the JSP compiler
35 * can choose to reuse different tag instances if they received the same
36 * original attribute values, and the JSP compiler can choose to not re-call
37 * the setter methods, because it can assume the same values are already set.
38 */
39 public class ELMultiboxTagBeanInfo extends SimpleBeanInfo {
40 public PropertyDescriptor[] getPropertyDescriptors() {
41 ArrayList proplist = new ArrayList();
42
43 try {
44 proplist.add(new PropertyDescriptor("accesskey",
45 ELMultiboxTag.class, null, "setAccesskeyExpr"));
46 } catch (IntrospectionException ex) {
47 }
48
49 try {
50 proplist.add(new PropertyDescriptor("alt", ELMultiboxTag.class,
51 null, "setAltExpr"));
52 } catch (IntrospectionException ex) {
53 }
54
55 try {
56 proplist.add(new PropertyDescriptor("altKey", ELMultiboxTag.class,
57 null, "setAltKeyExpr"));
58 } catch (IntrospectionException ex) {
59 }
60
61 try {
62 proplist.add(new PropertyDescriptor("bundle", ELMultiboxTag.class,
63 null, "setBundleExpr"));
64 } catch (IntrospectionException ex) {
65 }
66
67 try {
68 proplist.add(new PropertyDescriptor("disabled",
69 ELMultiboxTag.class, null, "setDisabledExpr"));
70 } catch (IntrospectionException ex) {
71 }
72
73 try {
74 proplist.add(new PropertyDescriptor("errorKey",
75 ELMultiboxTag.class, null, "setErrorKeyExpr"));
76 } catch (IntrospectionException ex) {
77 }
78
79 try {
80 proplist.add(new PropertyDescriptor("errorStyle",
81 ELMultiboxTag.class, null, "setErrorStyleExpr"));
82 } catch (IntrospectionException ex) {
83 }
84
85 try {
86 proplist.add(new PropertyDescriptor("errorStyleClass",
87 ELMultiboxTag.class, null, "setErrorStyleClassExpr"));
88 } catch (IntrospectionException ex) {
89 }
90
91 try {
92 proplist.add(new PropertyDescriptor("errorStyleId",
93 ELMultiboxTag.class, null, "setErrorStyleIdExpr"));
94 } catch (IntrospectionException ex) {
95 }
96
97 try {
98 proplist.add(new PropertyDescriptor("name", ELMultiboxTag.class,
99 null, "setNameExpr"));
100 } catch (IntrospectionException ex) {
101 }
102
103 try {
104 proplist.add(new PropertyDescriptor("onblur", ELMultiboxTag.class,
105 null, "setOnblurExpr"));
106 } catch (IntrospectionException ex) {
107 }
108
109 try {
110 proplist.add(new PropertyDescriptor("onchange",
111 ELMultiboxTag.class, null, "setOnchangeExpr"));
112 } catch (IntrospectionException ex) {
113 }
114
115 try {
116 proplist.add(new PropertyDescriptor("onclick", ELMultiboxTag.class,
117 null, "setOnclickExpr"));
118 } catch (IntrospectionException ex) {
119 }
120
121 try {
122 proplist.add(new PropertyDescriptor("ondblclick",
123 ELMultiboxTag.class, null, "setOndblclickExpr"));
124 } catch (IntrospectionException ex) {
125 }
126
127 try {
128 proplist.add(new PropertyDescriptor("onfocus", ELMultiboxTag.class,
129 null, "setOnfocusExpr"));
130 } catch (IntrospectionException ex) {
131 }
132
133 try {
134 proplist.add(new PropertyDescriptor("onkeydown",
135 ELMultiboxTag.class, null, "setOnkeydownExpr"));
136 } catch (IntrospectionException ex) {
137 }
138
139 try {
140 proplist.add(new PropertyDescriptor("onkeypress",
141 ELMultiboxTag.class, null, "setOnkeypressExpr"));
142 } catch (IntrospectionException ex) {
143 }
144
145 try {
146 proplist.add(new PropertyDescriptor("onkeyup", ELMultiboxTag.class,
147 null, "setOnkeyupExpr"));
148 } catch (IntrospectionException ex) {
149 }
150
151 try {
152 proplist.add(new PropertyDescriptor("onmousedown",
153 ELMultiboxTag.class, null, "setOnmousedownExpr"));
154 } catch (IntrospectionException ex) {
155 }
156
157 try {
158 proplist.add(new PropertyDescriptor("onmousemove",
159 ELMultiboxTag.class, null, "setOnmousemoveExpr"));
160 } catch (IntrospectionException ex) {
161 }
162
163 try {
164 proplist.add(new PropertyDescriptor("onmouseout",
165 ELMultiboxTag.class, null, "setOnmouseoutExpr"));
166 } catch (IntrospectionException ex) {
167 }
168
169 try {
170 proplist.add(new PropertyDescriptor("onmouseover",
171 ELMultiboxTag.class, null, "setOnmouseoverExpr"));
172 } catch (IntrospectionException ex) {
173 }
174
175 try {
176 proplist.add(new PropertyDescriptor("onmouseup",
177 ELMultiboxTag.class, null, "setOnmouseupExpr"));
178 } catch (IntrospectionException ex) {
179 }
180
181 try {
182 proplist.add(new PropertyDescriptor("property",
183 ELMultiboxTag.class, null, "setPropertyExpr"));
184 } catch (IntrospectionException ex) {
185 }
186
187 try {
188 proplist.add(new PropertyDescriptor("style", ELMultiboxTag.class,
189 null, "setStyleExpr"));
190 } catch (IntrospectionException ex) {
191 }
192
193 try {
194 proplist.add(new PropertyDescriptor("styleClass",
195 ELMultiboxTag.class, null, "setStyleClassExpr"));
196 } catch (IntrospectionException ex) {
197 }
198
199 try {
200 proplist.add(new PropertyDescriptor("styleId", ELMultiboxTag.class,
201 null, "setStyleIdExpr"));
202 } catch (IntrospectionException ex) {
203 }
204
205 try {
206 proplist.add(new PropertyDescriptor("tabindex",
207 ELMultiboxTag.class, null, "setTabindexExpr"));
208 } catch (IntrospectionException ex) {
209 }
210
211 try {
212 proplist.add(new PropertyDescriptor("title", ELMultiboxTag.class,
213 null, "setTitleExpr"));
214 } catch (IntrospectionException ex) {
215 }
216
217 try {
218 proplist.add(new PropertyDescriptor("titleKey",
219 ELMultiboxTag.class, null, "setTitleKeyExpr"));
220 } catch (IntrospectionException ex) {
221 }
222
223 try {
224 proplist.add(new PropertyDescriptor("value", ELMultiboxTag.class,
225 null, "setValueExpr"));
226 } catch (IntrospectionException ex) {
227 }
228
229 PropertyDescriptor[] result = new PropertyDescriptor[proplist.size()];
230
231 return ((PropertyDescriptor[]) proplist.toArray(result));
232 }
233 }