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 package fr.paris.lutece.plugins.forms.business;
35
36 import java.util.Set;
37
38 import javax.validation.constraints.NotEmpty;
39
40 import fr.paris.lutece.portal.service.util.AppLogService;
41
42
43
44
45 public class Control implements Cloneable
46 {
47 private int _nId;
48
49 private String _strValue;
50
51 private String _strErrorMessage;
52
53
54 private Set<Integer> _listIdQuestion;
55
56 @NotEmpty( message = "#i18n{forms.validation.control.ValidatorName.notEmpty}" )
57 private String _strValidatorName;
58
59 @NotEmpty( message = "#i18n{forms.validation.control.ControlType.notEmpty}" )
60 private String _strControlType;
61
62 private int _nIdControlTarget;
63
64 private int _nIdControlGroup;
65
66
67
68
69 public int getId( )
70 {
71 return _nId;
72 }
73
74
75
76
77
78 public void setId( int nId )
79 {
80 this._nId = nId;
81 }
82
83
84
85
86 public String getValue( )
87 {
88 return _strValue;
89 }
90
91
92
93
94
95 public void setValue( String strValue )
96 {
97 this._strValue = strValue;
98 }
99
100
101
102
103 public String getErrorMessage( )
104 {
105 return _strErrorMessage;
106 }
107
108
109
110
111
112 public void setErrorMessage( String strErrorMessage )
113 {
114 this._strErrorMessage = strErrorMessage;
115 }
116
117
118
119
120 public Set<Integer> getListIdQuestion( )
121 {
122 return _listIdQuestion;
123 }
124
125
126
127
128
129 public void setListIdQuestion( Set<Integer> listIdQuestion )
130 {
131 this._listIdQuestion = listIdQuestion;
132 }
133
134
135
136
137 public String getValidatorName( )
138 {
139 return _strValidatorName;
140 }
141
142
143
144
145
146 public void setValidatorName( String strValidatorName )
147 {
148 this._strValidatorName = strValidatorName;
149 }
150
151
152
153
154 public String getControlType( )
155 {
156 return _strControlType;
157 }
158
159
160
161
162
163 public void setControlType( String strControlType )
164 {
165 this._strControlType = strControlType;
166 }
167
168
169
170
171
172 public int getIdControlTarget( )
173 {
174 return _nIdControlTarget;
175 }
176
177
178
179
180
181
182 public void setIdControlTarget( int nIdControlTarget )
183 {
184 this._nIdControlTarget = nIdControlTarget;
185 }
186
187 public int getIdControlGroup() {
188 return _nIdControlGroup;
189 }
190
191 public void setIdControlGroup(int nIdControlGroup) {
192 this._nIdControlGroup = nIdControlGroup;
193 }
194
195
196
197
198
199
200 @Override
201 public Control clone( )
202 {
203 Controlms/business/Control.html#Control">Control controlNew = new Control( );
204
205 try
206 {
207 controlNew = (Control) super.clone( );
208 }
209 catch( CloneNotSupportedException e )
210 {
211 AppLogService.error( e );
212 }
213
214 controlNew.setId( _nId );
215 controlNew.setListIdQuestion( _listIdQuestion );
216 controlNew.setControlType( _strControlType );
217 controlNew.setErrorMessage( _strErrorMessage );
218 controlNew.setIdControlTarget( _nIdControlTarget );
219 controlNew.setValidatorName( _strValidatorName );
220 controlNew.setValue( _strValue );
221 controlNew.setIdControlGroup(_nIdControlGroup);
222
223 return controlNew;
224 }
225 }