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.botpress.business;
35
36 import org.hibernate.validator.constraints.NotEmpty;
37
38 import java.io.Serializable;
39
40 import javax.validation.constraints.Size;
41
42
43
44
45 public class BPBot implements Serializable
46 {
47 private static final String DEFAULT_AVATAR_URL = "images/skin/plugins/botpress/default_avatar.png";
48 private static final long serialVersionUID = 1L;
49
50
51 private int _nId;
52 @NotEmpty( message = "#i18n{botpress.validation.bpbot.BotKey.notEmpty}" )
53 @Size( max = 50, message = "#i18n{botpress.validation.bpbot.BotKey.size}" )
54 private String _strBotKey;
55 @NotEmpty( message = "#i18n{botpress.validation.bpbot.BotPressKey.notEmpty}" )
56 @Size( max = 50, message = "#i18n{botpress.validation.bpbot.BotPressKey.size}" )
57 private String _strBotPressKey;
58 @NotEmpty( message = "#i18n{botpress.validation.bpbot.Name.notEmpty}" )
59 @Size( max = 50, message = "#i18n{botpress.validation.bpbot.Name.size}" )
60 private String _strName;
61 @NotEmpty( message = "#i18n{botpress.validation.bpbot.Description.notEmpty}" )
62 @Size( max = 255, message = "#i18n{botpress.validation.bpbot.Description.size}" )
63 private String _strDescription;
64 @NotEmpty( message = "#i18n{botpress.validation.bpbot.AvatarUrl.notEmpty}" )
65 @Size( max = 255, message = "#i18n{botpress.validation.bpbot.AvatarUrl.size}" )
66 private String _strAvatarUrl = DEFAULT_AVATAR_URL;
67 @NotEmpty( message = "#i18n{botpress.validation.bpbot.Language.notEmpty}" )
68 @Size( max = 50, message = "#i18n{botpress.validation.bpbot.Language.size}" )
69 private String _strLanguage;
70 private int _nBotStatus;
71 private int _nIsStandalone;
72 @Size( max = 255, message = "#i18n{botpress.validation.bpbot.WelcomeMessage.size}" )
73 private String _strWelcomeMessage;
74 @Size( max = 255, message = "#i18n{botpress.validation.bpbot.ErrorMessage.size}" )
75 private String _strErrorMessage;
76 @NotEmpty( message = "#i18n{botpress.validation.bpbot.ServerUrl.notEmpty}" )
77 @Size( max = 255, message = "#i18n{botpress.validation.bpbot.ServerUrl.size}" )
78 private String _strServerUrl;
79 private int _nApiVersion;
80 private String _strAvatarRendererKey;
81
82
83
84
85
86
87 public int getId( )
88 {
89 return _nId;
90 }
91
92
93
94
95
96
97
98 public void setId( int nId )
99 {
100 _nId = nId;
101 }
102
103
104
105
106
107
108 public String getBotKey( )
109 {
110 return _strBotKey;
111 }
112
113
114
115
116
117
118
119 public void setBotKey( String strBotKey )
120 {
121 _strBotKey = strBotKey;
122 }
123
124
125
126
127
128
129 public String getBotPressKey( )
130 {
131 return _strBotPressKey;
132 }
133
134
135
136
137
138
139
140 public void setBotPressKey( String strBotPressKey )
141 {
142 _strBotPressKey = strBotPressKey;
143 }
144
145
146
147
148
149
150 public String getName( )
151 {
152 return _strName;
153 }
154
155
156
157
158
159
160
161 public void setName( String strName )
162 {
163 _strName = strName;
164 }
165
166
167
168
169
170
171 public String getDescription( )
172 {
173 return _strDescription;
174 }
175
176
177
178
179
180
181
182 public void setDescription( String strDescription )
183 {
184 _strDescription = strDescription;
185 }
186
187
188
189
190
191
192 public String getAvatarUrl( )
193 {
194 return _strAvatarUrl;
195 }
196
197
198
199
200
201
202
203 public void setAvatarUrl( String strAvatarUrl )
204 {
205 _strAvatarUrl = strAvatarUrl;
206 }
207
208
209
210
211
212
213 public String getLanguage( )
214 {
215 return _strLanguage;
216 }
217
218
219
220
221
222
223
224 public void setLanguage( String strLanguage )
225 {
226 _strLanguage = strLanguage;
227 }
228
229
230
231
232
233
234 public int getBotStatus( )
235 {
236 return _nBotStatus;
237 }
238
239
240
241
242
243
244
245 public void setBotStatus( int nBotStatus )
246 {
247 _nBotStatus = nBotStatus;
248 }
249
250
251
252
253
254
255 public int getIsStandalone( )
256 {
257 return _nIsStandalone;
258 }
259
260
261
262
263
264
265
266 public void setIsStandalone( int nIsStandalone )
267 {
268 _nIsStandalone = nIsStandalone;
269 }
270
271
272
273
274
275
276 public String getWelcomeMessage( )
277 {
278 return _strWelcomeMessage;
279 }
280
281
282
283
284
285
286
287 public void setWelcomeMessage( String strWelcomeMessage )
288 {
289 _strWelcomeMessage = strWelcomeMessage;
290 }
291
292
293
294
295
296
297 public String getErrorMessage( )
298 {
299 return _strErrorMessage;
300 }
301
302
303
304
305
306
307
308 public void setErrorMessage( String strErrorMessage )
309 {
310 _strErrorMessage = strErrorMessage;
311 }
312
313
314
315
316
317
318 public String getServerUrl( )
319 {
320 return _strServerUrl;
321 }
322
323
324
325
326
327
328
329 public void setServerUrl( String strServerUrl )
330 {
331 _strServerUrl = strServerUrl;
332 }
333
334
335
336
337
338
339 public int getApiVersion( )
340 {
341 return _nApiVersion;
342 }
343
344
345
346
347
348
349
350 public void setApiVersion( int nApiVersion )
351 {
352 _nApiVersion = nApiVersion;
353 }
354
355
356
357
358
359
360 public String getAvatarRendererKey( )
361 {
362 return _strAvatarRendererKey;
363 }
364
365
366
367
368
369
370
371 public void setAvatarRendererKey( String strAvatarRendererKey )
372 {
373 _strAvatarRendererKey = strAvatarRendererKey;
374 }
375 }