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.genericattributes.business;
35
36 import fr.paris.lutece.plugins.genericattributes.util.GenericAttributesUtils;
37
38 import org.apache.commons.lang3.StringUtils;
39
40
41
42
43
44
45 public class EntryFilter
46 {
47
48
49
50 public static final int FILTER_FALSE = 0;
51
52
53
54
55 public static final int FILTER_TRUE = 1;
56 private int _nIdResource = GenericAttributesUtils.CONSTANT_ID_NULL;
57 private String _strResourceType;
58 private int _nIdFieldDepend = GenericAttributesUtils.CONSTANT_ID_NULL;
59 private int _nIdEntryParent = GenericAttributesUtils.CONSTANT_ID_NULL;
60 private int _nEntryParentNull = GenericAttributesUtils.CONSTANT_ID_NULL;
61 private int _nFieldDependNull = GenericAttributesUtils.CONSTANT_ID_NULL;
62 private int _nIdIsGroup = GenericAttributesUtils.CONSTANT_ID_NULL;
63 private int _nIdIsComment = GenericAttributesUtils.CONSTANT_ID_NULL;
64 private int _nIdEntryType = GenericAttributesUtils.CONSTANT_ID_NULL;
65 private int _nIsOnlyDisplayInBack = GenericAttributesUtils.CONSTANT_ID_NULL;
66 private int _nIsIndexed = GenericAttributesUtils.CONSTANT_ID_NULL;
67
68
69
70
71
72
73 public int getIdResource( )
74 {
75 return _nIdResource;
76 }
77
78
79
80
81
82
83
84 public void setIdResource( int nIdResource )
85 {
86 _nIdResource = nIdResource;
87 }
88
89
90
91
92
93
94 public boolean containsIdResource( )
95 {
96 return ( _nIdResource != GenericAttributesUtils.CONSTANT_ID_NULL );
97 }
98
99
100
101
102
103 public int getIdFieldDepend( )
104 {
105 return _nIdFieldDepend;
106 }
107
108
109
110
111
112
113
114 public void setIdFieldDepend( int idField )
115 {
116 _nIdFieldDepend = idField;
117 }
118
119
120
121
122
123
124 public boolean containsIdField( )
125 {
126 return ( _nIdFieldDepend != GenericAttributesUtils.CONSTANT_ID_NULL );
127 }
128
129
130
131
132
133 public int getIdEntryParent( )
134 {
135 return _nIdEntryParent;
136 }
137
138
139
140
141
142
143
144 public void setIdEntryParent( int idEntryParent )
145 {
146 _nIdEntryParent = idEntryParent;
147 }
148
149
150
151
152
153 public boolean containsIdEntryParent( )
154 {
155 return ( _nIdEntryParent != GenericAttributesUtils.CONSTANT_ID_NULL );
156 }
157
158
159
160
161
162 public int getEntryParentNull( )
163 {
164 return _nEntryParentNull;
165 }
166
167
168
169
170
171
172
173 public void setEntryParentNull( int idEntryParentNull )
174 {
175 _nEntryParentNull = idEntryParentNull;
176 }
177
178
179
180
181
182 public boolean containsEntryParentNull( )
183 {
184 return ( _nEntryParentNull != GenericAttributesUtils.CONSTANT_ID_NULL );
185 }
186
187
188
189
190
191 public int getFieldDependNull( )
192 {
193 return _nFieldDependNull;
194 }
195
196
197
198
199
200
201
202 public void setFieldDependNull( int idFieldDependNull )
203 {
204 _nFieldDependNull = idFieldDependNull;
205 }
206
207
208
209
210
211 public boolean containsFieldDependNull( )
212 {
213 return ( _nFieldDependNull != GenericAttributesUtils.CONSTANT_ID_NULL );
214 }
215
216
217
218
219
220 public int getIdIsGroup( )
221 {
222 return _nIdIsGroup;
223 }
224
225
226
227
228
229
230
231 public void setIdIsGroup( int idIsGroup )
232 {
233 _nIdIsGroup = idIsGroup;
234 }
235
236
237
238
239
240 public boolean containsIdIsGroup( )
241 {
242 return ( _nIdIsGroup != GenericAttributesUtils.CONSTANT_ID_NULL );
243 }
244
245
246
247
248
249 public int getIdIsComment( )
250 {
251 return _nIdIsComment;
252 }
253
254
255
256
257
258
259
260 public void setIdIsComment( int idComment )
261 {
262 _nIdIsComment = idComment;
263 }
264
265
266
267
268
269 public boolean containsIdIsComment( )
270 {
271 return ( _nIdIsComment != GenericAttributesUtils.CONSTANT_ID_NULL );
272 }
273
274
275
276
277
278
279 public int getIdEntryType( )
280 {
281 return _nIdEntryType;
282 }
283
284
285
286
287
288
289
290 public void setIdEntryType( int nIdEntryType )
291 {
292 _nIdEntryType = nIdEntryType;
293 }
294
295
296
297
298
299
300 public boolean containsIdEntryType( )
301 {
302 return ( _nIdEntryType != GenericAttributesUtils.CONSTANT_ID_NULL );
303 }
304
305
306
307
308
309
310 public String getResourceType( )
311 {
312 return _strResourceType;
313 }
314
315
316
317
318
319
320
321 public void setResourceType( String strResourceType )
322 {
323 this._strResourceType = strResourceType;
324 }
325
326
327
328
329
330
331 public boolean containsResourceType( )
332 {
333 return StringUtils.isNotEmpty( _strResourceType );
334 }
335
336
337
338
339
340 public int getIsOnlyDisplayInBack( )
341 {
342 return _nIsOnlyDisplayInBack;
343 }
344
345
346
347
348
349 public void setIsOnlyDisplayInBack( int isOnlyDisplayInBack )
350 {
351 this._nIsOnlyDisplayInBack = isOnlyDisplayInBack;
352 }
353
354
355
356
357
358 public boolean containsIsOnlyDisplayInBack( )
359 {
360 return ( _nIsOnlyDisplayInBack != GenericAttributesUtils.CONSTANT_ID_NULL );
361 }
362
363 public int getIsIndexed( )
364 {
365 return _nIsIndexed;
366 }
367
368 public void setIsIndexed( int nIsIndexed )
369 {
370 _nIsIndexed = nIsIndexed;
371 }
372
373 public boolean containsIsIndexed( )
374 {
375 return ( _nIsIndexed != GenericAttributesUtils.CONSTANT_ID_NULL );
376 }
377 }