1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20 package org.apache.myfaces.tobago.component;
21
22 import javax.faces.component.behavior.ClientBehaviorHolder;
23 import javax.faces.context.FacesContext;
24 import org.apache.myfaces.tobago.internal.component.AbstractUIEvent;
25 import org.apache.myfaces.tobago.internal.util.ArrayUtils;
26 import org.apache.myfaces.tobago.internal.util.StringUtils;
27 import org.apache.myfaces.tobago.internal.util.Deprecation;
28 import org.apache.myfaces.tobago.component.Tags;
29 import javax.annotation.Generated;
30 import javax.el.ELException;
31 import javax.faces.FacesException;
32 import java.util.Arrays;
33 import java.util.ArrayList;
34 import java.util.Collection;
35 import java.util.List;
36 import javax.el.MethodExpression;
37 import javax.el.ValueExpression;
38
39
40
41
42
43
44
45 @Generated("component.stg")
46 public class UIEvent
47 extends AbstractUIEvent implements ClientBehaviorHolder {
48
49 public static final String COMPONENT_TYPE = Tags.event.componentType();
50
51 public static final String COMPONENT_FAMILY = "javax.faces.Command";
52
53 private static final Collection<String> EVENT_NAMES = Arrays.asList("change", "click", "dblclick", "focus", "blur", "mouseout", "mouseover", "complete", "load", "reload", "resize");
54
55 @Override
56 public Collection<String> getEventNames() {
57 return EVENT_NAMES;
58 }
59
60 @Override
61 public String getDefaultEventName() {
62 return "click";
63 }
64
65
66 enum PropertyKeys {
67 fragment,
68 link,
69 confirmation,
70 event,
71 omit,
72 outcome,
73 transition,
74 target,
75 }
76
77 public String getFamily() {
78 return COMPONENT_FAMILY;
79 }
80
81
82
83
84
85
86
87
88
89
90 public java.lang.String getFragment() {
91 return (java.lang.String) getStateHelper().eval(PropertyKeys.fragment);
92 }
93
94 public void setFragment(java.lang.String fragment) {
95 getStateHelper().put(PropertyKeys.fragment, fragment);
96 }
97
98
99
100
101
102
103
104
105
106
107
108
109
110 public java.lang.String getLink() {
111 return (java.lang.String) getStateHelper().eval(PropertyKeys.link);
112 }
113
114 public void setLink(java.lang.String link) {
115 getStateHelper().put(PropertyKeys.link, link);
116 }
117
118
119
120
121
122 public java.lang.String getConfirmation() {
123 return (java.lang.String) getStateHelper().eval(PropertyKeys.confirmation);
124 }
125
126 public void setConfirmation(java.lang.String confirmation) {
127 getStateHelper().put(PropertyKeys.confirmation, confirmation);
128 }
129
130
131
132
133
134 public org.apache.myfaces.tobago.component.ClientBehaviors getEvent() {
135 return (org.apache.myfaces.tobago.component.ClientBehaviors) getStateHelper().eval(PropertyKeys.event);
136 }
137
138 public void setEvent(org.apache.myfaces.tobago.component.ClientBehaviors event) {
139 getStateHelper().put(PropertyKeys.event, event);
140 }
141
142
143
144
145
146
147
148
149
150
151 public boolean isOmit() {
152 Boolean bool = (Boolean) getStateHelper().eval(PropertyKeys.omit);
153 if (bool != null) {
154 return bool;
155 }
156 return false;
157 }
158
159 public void setOmit(boolean omit) {
160 getStateHelper().put(PropertyKeys.omit, omit);
161 }
162
163
164
165
166
167
168
169 public java.lang.String getOutcome() {
170 return (java.lang.String) getStateHelper().eval(PropertyKeys.outcome);
171 }
172
173 public void setOutcome(java.lang.String outcome) {
174 getStateHelper().put(PropertyKeys.outcome, outcome);
175 }
176
177
178
179
180
181
182 public boolean isTransition() {
183 Boolean bool = (Boolean) getStateHelper().eval(PropertyKeys.transition);
184 if (bool != null) {
185 return bool;
186 }
187 return true;
188 }
189
190 public void setTransition(boolean transition) {
191 getStateHelper().put(PropertyKeys.transition, transition);
192 }
193
194
195
196
197
198
199 public java.lang.String getTarget() {
200 return (java.lang.String) getStateHelper().eval(PropertyKeys.target);
201 }
202
203 public void setTarget(java.lang.String target) {
204 getStateHelper().put(PropertyKeys.target, target);
205 }
206
207
208 @Override
209 public void restoreState(FacesContext context, Object state) {
210
211 pushComponentToEL(context, this);
212 super.restoreState(context, state);
213 popComponentFromEL(context);
214 }
215
216 }