KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > info > jtrac > domain > ItemSearch


1 /*
2  * Copyright 2002-2005 the original author or authors.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */

16
17 package info.jtrac.domain;
18
19 import static info.jtrac.Constants.*;
20
21 import java.io.Serializable JavaDoc;
22 import java.util.ArrayList JavaDoc;
23 import java.util.Collection JavaDoc;
24 import java.util.Collections JavaDoc;
25 import java.util.Date JavaDoc;
26 import java.util.HashMap JavaDoc;
27 import java.util.HashSet JavaDoc;
28 import java.util.List JavaDoc;
29 import java.util.Map JavaDoc;
30 import java.util.Set JavaDoc;
31 import org.hibernate.criterion.DetachedCriteria;
32 import org.hibernate.criterion.Order;
33 import org.hibernate.criterion.Restrictions;
34
35 /**
36  * Object that holds filter criteria when searching for Items
37  * and also creates a Hibernate Criteria query to pass to the DAO
38  * Spring MVC automagically binds most of the screen selections
39  * on to the large bunch of instance variables of this class
40  */

41 public class ItemSearch implements Serializable JavaDoc {
42     
43     private List JavaDoc<Field> fields; // columns in order
44
private Space space; // if null, means aggregate across all spaces
45
private User user; // this will be set in the case space is null
46

47     private int pageSize = 25;
48     private int currentPage;
49     private long resultCount;
50     private String JavaDoc sortFieldName = "id";
51     private boolean sortDescending;
52     private boolean showHistory;
53     private boolean showDetail;
54     
55     private String JavaDoc summary;
56     private Collection JavaDoc<Long JavaDoc> itemIds;
57     
58     private Date JavaDoc createdDateStart;
59     private Date JavaDoc createdDateEnd;
60     private Date JavaDoc modifiedDateStart;
61     private Date JavaDoc modifiedDateEnd;
62     
63     private Set JavaDoc<Long JavaDoc> spaceSet;
64     private Set JavaDoc<Integer JavaDoc> statusSet;
65     private Set JavaDoc<Integer JavaDoc> severitySet;
66     private Set JavaDoc<Integer JavaDoc> prioritySet;
67     private Set JavaDoc<Long JavaDoc> loggedBySet;
68     private Set JavaDoc<Long JavaDoc> assignedToSet;
69     
70     private Set JavaDoc<Integer JavaDoc> cusInt01Set;
71     private Set JavaDoc<Integer JavaDoc> cusInt02Set;
72     private Set JavaDoc<Integer JavaDoc> cusInt03Set;
73     private Set JavaDoc<Integer JavaDoc> cusInt04Set;
74     private Set JavaDoc<Integer JavaDoc> cusInt05Set;
75     private Set JavaDoc<Integer JavaDoc> cusInt06Set;
76     private Set JavaDoc<Integer JavaDoc> cusInt07Set;
77     private Set JavaDoc<Integer JavaDoc> cusInt08Set;
78     private Set JavaDoc<Integer JavaDoc> cusInt09Set;
79     private Set JavaDoc<Integer JavaDoc> cusInt10Set;
80     
81     private String JavaDoc cusStr01;
82     private String JavaDoc cusStr02;
83     private String JavaDoc cusStr03;
84     private String JavaDoc cusStr04;
85     private String JavaDoc cusStr05;
86     
87     private Date JavaDoc cusTim01Start;
88     private Date JavaDoc cusTim01End;
89     private Date JavaDoc cusTim02Start;
90     private Date JavaDoc cusTim02End;
91     private Date JavaDoc cusTim03Start;
92     private Date JavaDoc cusTim03End;
93     
94     // have to do this as "order by" clause conflicts with "count (*)" clause
95
// DAO has to use getCriteriaForCount() separately
96
public DetachedCriteria getCriteria() {
97         if (sortFieldName == null) { // can happen only for multi-space search
98
sortFieldName = "id"; // effectively is a sort on created date
99
}
100         DetachedCriteria criteria = getCriteriaForCount();
101         if (sortDescending) {
102             criteria.addOrder(Order.desc(sortFieldName));
103         } else {
104             criteria.addOrder(Order.asc(sortFieldName));
105         }
106         return criteria;
107     }
108     
109     public DetachedCriteria getCriteriaForCount() {
110         if (modifiedDateStart != null || modifiedDateEnd != null) {
111             showHistory = true;
112         }
113         DetachedCriteria criteria = null;
114         if (showHistory == true) {
115             criteria = DetachedCriteria.forClass(History.class);
116             // apply restrictions to parent, this is an inner join =============
117
criteria.createCriteria("parent").add(Restrictions.in("space.id", getSpaceIdSet()));
118             if (createdDateStart != null) {
119                 criteria.createCriteria("parent").add(Restrictions.ge("timeStamp", createdDateStart));
120             }
121             if (createdDateEnd != null) {
122                 criteria.createCriteria("parent").add(Restrictions.le("timeStamp", createdDateEnd));
123             }
124             //==================================================================
125
if (modifiedDateStart != null) {
126                 criteria.add(Restrictions.ge("timeStamp", modifiedDateStart));
127             }
128             if (modifiedDateEnd != null) {
129                 criteria.add(Restrictions.le("timeStamp", modifiedDateEnd));
130             }
131         } else {
132             criteria = DetachedCriteria.forClass(Item.class);
133             criteria.add(Restrictions.in("space.id", getSpaceIdSet()));
134             if (itemIds != null) {
135                 criteria.add(Restrictions.in("id", itemIds));
136             }
137             // see the difference above in the if clause
138
if (createdDateStart != null) {
139                 criteria.add(Restrictions.ge("timeStamp", createdDateStart));
140             }
141
142             if (createdDateEnd != null) {
143                 criteria.add(Restrictions.le("timeStamp", createdDateEnd));
144             }
145             
146         }
147         //======================================================================
148
if (statusSet != null) {
149             criteria.add(Restrictions.in("status", statusSet));
150         }
151         if (severitySet != null) {
152             criteria.add(Restrictions.in("severity", severitySet));
153         }
154         if (prioritySet != null) {
155             criteria.add(Restrictions.in("priority", prioritySet));
156         }
157         if (loggedBySet != null) {
158             criteria.add(Restrictions.in("loggedBy.id", loggedBySet));
159         }
160         if (assignedToSet != null) {
161             criteria.add(Restrictions.in("assignedTo.id", assignedToSet));
162         }
163         //======================================================================
164
if (cusInt01Set != null) {
165             criteria.add(Restrictions.in("cusInt01", cusInt01Set));
166         }
167         if (cusInt02Set != null) {
168             criteria.add(Restrictions.in("cusInt02", cusInt02Set));
169         }
170         if (cusInt03Set != null) {
171             criteria.add(Restrictions.in("cusInt03", cusInt03Set));
172         }
173         if (cusInt04Set != null) {
174             criteria.add(Restrictions.in("cusInt04", cusInt04Set));
175         }
176         if (cusInt05Set != null) {
177             criteria.add(Restrictions.in("cusInt05", cusInt05Set));
178         }
179         if (cusInt06Set != null) {
180             criteria.add(Restrictions.in("cusInt06", cusInt06Set));
181         }
182         if (cusInt07Set != null) {
183             criteria.add(Restrictions.in("cusInt07", cusInt07Set));
184         }
185         if (cusInt08Set != null) {
186             criteria.add(Restrictions.in("cusInt08", cusInt08Set));
187         }
188         if (cusInt09Set != null) {
189             criteria.add(Restrictions.in("cusInt09", cusInt09Set));
190         }
191         if (cusInt10Set != null) {
192             criteria.add(Restrictions.in("cusInt10", cusInt10Set));
193         }
194         //======================================================================
195
if (cusStr01 != null) {
196             criteria.add(Restrictions.like("cusStr01", "%" + cusStr01 + "%"));
197         }
198         if (cusStr02 != null) {
199             criteria.add(Restrictions.like("cusStr02", "%" + cusStr02 + "%"));
200         }
201         if (cusStr03 != null) {
202             criteria.add(Restrictions.like("cusStr03", "%" + cusStr03 + "%"));
203         }
204         if (cusStr04 != null) {
205             criteria.add(Restrictions.like("cusStr04", "%" + cusStr04 + "%"));
206         }
207         if (cusStr05 != null) {
208             criteria.add(Restrictions.like("cusStr05", "%" + cusStr05 + "%"));
209         }
210         //======================================================================
211
if (cusTim01Start != null) {
212             criteria.add(Restrictions.ge("cusTim01", cusTim01Start));
213         }
214         if (cusTim01End != null) {
215             criteria.add(Restrictions.le("cusTim01", cusTim01End));
216         }
217         if (cusTim02Start != null) {
218             criteria.add(Restrictions.ge("cusTim02", cusTim02Start));
219         }
220         if (cusTim02End != null) {
221             criteria.add(Restrictions.le("cusTim02", cusTim02End));
222         }
223         if (cusTim03Start != null) {
224             criteria.add(Restrictions.ge("cusTim03", cusTim03Start));
225         }
226         if (cusTim03End != null) {
227             criteria.add(Restrictions.le("cusTim03", cusTim03End));
228         }
229         //======================================================================
230
return criteria;
231     }
232     
233     // private routine to help with the space "in" clause
234
private Collection JavaDoc<Long JavaDoc> getSpaceIdSet() {
235         if (space == null) {
236             if (spaceSet != null) {
237                 return spaceSet;
238             }
239             Set JavaDoc<Long JavaDoc> spaceIdSet = new HashSet JavaDoc<Long JavaDoc>(user.getUserSpaceRoles().size());
240             for (UserSpaceRole usr : user.getUserSpaceRoles()) {
241                 if (usr.getSpace() != null) {
242                     spaceIdSet.add(usr.getSpace().getId());
243                 }
244             }
245             return spaceIdSet;
246         } else {
247             return Collections.singleton(space.getId());
248         }
249     }
250     
251     //=========================================================================
252

253     public ItemSearch() {
254         // zero arg constructor
255
}
256     
257     public ItemSearch(User user) {
258         this.user = user;
259         fields = new ArrayList JavaDoc<Field>();
260         Field severity = new Field(Field.Name.SEVERITY);
261         severity.initOptions();
262         fields.add(severity);
263         Field priority = new Field(Field.Name.PRIORITY);
264         priority.initOptions();
265         fields.add(priority);
266         this.sortDescending = true;
267     }
268     
269     public ItemSearch(Space space) {
270         this.fields = space.getMetadata().getFieldList();
271         this.space = space;
272         this.sortDescending = true;
273     }
274     
275     private Map JavaDoc setToMap(Set JavaDoc s) {
276         if (s == null) {
277             return null;
278         }
279         Map JavaDoc<String JavaDoc, Boolean JavaDoc> map = new HashMap JavaDoc<String JavaDoc, Boolean JavaDoc>(s.size());
280         for (Object JavaDoc o : s) {
281             // ugly toString hack to make JSTL / EL get map value by key easier
282
map.put(o.toString(), new Boolean JavaDoc(true));
283         }
284         return map;
285     }
286     
287     public Map JavaDoc getSearchMap() {
288         Map JavaDoc<String JavaDoc, Map JavaDoc> map = new HashMap JavaDoc<String JavaDoc, Map JavaDoc>();
289         map.put("spaceSet", setToMap(spaceSet));
290         map.put("statusSet", setToMap(statusSet));
291         map.put("severitySet", setToMap(severitySet));
292         map.put("prioritySet", setToMap(prioritySet));
293         map.put("loggedBySet", setToMap(loggedBySet));
294         map.put("assignedToSet", setToMap(assignedToSet));
295         map.put("cusInt01Set", setToMap(cusInt01Set));
296         map.put("cusInt02Set", setToMap(cusInt02Set));
297         map.put("cusInt03Set", setToMap(cusInt03Set));
298         map.put("cusInt04Set", setToMap(cusInt04Set));
299         map.put("cusInt05Set", setToMap(cusInt05Set));
300         map.put("cusInt06Set", setToMap(cusInt06Set));
301         map.put("cusInt07Set", setToMap(cusInt07Set));
302         map.put("cusInt08Set", setToMap(cusInt08Set));
303         map.put("cusInt09Set", setToMap(cusInt09Set));
304         map.put("cusInt10Set", setToMap(cusInt10Set));
305         return map;
306     }
307     
308     public Map JavaDoc<String JavaDoc, String JavaDoc> getSeverityOptions() {
309         Field f = new Field(Field.Name.SEVERITY);
310         f.initOptions();
311         return f.getOptions();
312     }
313     
314     public Map JavaDoc<String JavaDoc, String JavaDoc> getPriorityOptions() {
315         Field f = new Field(Field.Name.PRIORITY);
316         f.initOptions();
317         return f.getOptions();
318     }
319     
320     public Map JavaDoc<Integer JavaDoc, String JavaDoc> getStatusOptions() {
321         if (space == null) {
322             Map JavaDoc<Integer JavaDoc, String JavaDoc> map = new HashMap JavaDoc<Integer JavaDoc, String JavaDoc>();
323             map.put(State.OPEN, "Open");
324             map.put(State.CLOSED, "Closed");
325             return map;
326         }
327         // is mutable so caution
328
Map JavaDoc<Integer JavaDoc, String JavaDoc> temp = new HashMap JavaDoc<Integer JavaDoc, String JavaDoc>(space.getMetadata().getStates());
329         temp.remove(State.NEW);
330         return temp;
331     }
332     
333     public Map JavaDoc<Integer JavaDoc, String JavaDoc> getSpaceOptions() {
334         if (user == null) {
335             return null;
336         }
337         Map JavaDoc<Integer JavaDoc, String JavaDoc> map = new HashMap JavaDoc<Integer JavaDoc, String JavaDoc>(user.getUserSpaceRoles().size());
338         for(UserSpaceRole usr : user.getUserSpaceRoles()) {
339             if (usr.getSpace() != null) {
340                 map.put((int) usr.getSpace().getId(), usr.getSpace().getName());
341             }
342         }
343         return map;
344     }
345     
346     public Map JavaDoc<String JavaDoc, Field> getFieldMap() {
347         if (space == null) {
348             return null;
349         }
350         Map JavaDoc<String JavaDoc, Field> fieldMap = new HashMap JavaDoc<String JavaDoc, Field>(space.getMetadata().getFieldCount());
351         for (Field f : space.getMetadata().getFields().values()) {
352             fieldMap.put(f.getName().toString(), f);
353         }
354         return fieldMap;
355     }
356     
357     //=====================================================================
358

359     public void setFields(List JavaDoc<Field> fields) {
360         this.fields = fields;
361     }
362     
363     public List JavaDoc<Field> getFields() {
364         return fields;
365     }
366     
367     public Space getSpace() {
368         return space;
369     }
370     
371     public void setSpace(Space space) {
372         this.space = space;
373     }
374     
375     public int getPageSize() {
376         return pageSize;
377     }
378     
379     public void setPageSize(int pageSize) {
380         this.pageSize = pageSize;
381     }
382     
383     public int getCurrentPage() {
384         return currentPage;
385     }
386     
387     public void setCurrentPage(int currentPage) {
388         this.currentPage = currentPage;
389     }
390     
391     public String JavaDoc getSortFieldName() {
392         return sortFieldName;
393     }
394     
395     public void setSortFieldName(String JavaDoc sortFieldName) {
396         this.sortFieldName = sortFieldName;
397     }
398     
399     public boolean isSortDescending() {
400         return sortDescending;
401     }
402     
403     public void setSortDescending(boolean sortDescending) {
404         this.sortDescending = sortDescending;
405     }
406     
407     public boolean isShowHistory() {
408         return showHistory;
409     }
410     
411     public void setShowHistory(boolean showHistory) {
412         this.showHistory = showHistory;
413     }
414     
415     public boolean isShowDetail() {
416         return showDetail;
417     }
418     
419     public void setShowDetail(boolean showDetail) {
420         this.showDetail = showDetail;
421     }
422     
423     public String JavaDoc getSummary() {
424         return summary;
425     }
426     
427     public void setSummary(String JavaDoc summary) {
428         this.summary = summary;
429     }
430     
431     public Date JavaDoc getCreatedDateStart() {
432         return createdDateStart;
433     }
434     
435     public void setCreatedDateStart(Date JavaDoc createdDateStart) {
436         this.createdDateStart = createdDateStart;
437     }
438     
439     public Date JavaDoc getCreatedDateEnd() {
440         return createdDateEnd;
441     }
442     
443     public void setCreatedDateEnd(Date JavaDoc createdDateEnd) {
444         this.createdDateEnd = createdDateEnd;
445     }
446     
447     public Date JavaDoc getModifiedDateStart() {
448         return modifiedDateStart;
449     }
450     
451     public void setModifiedDateStart(Date JavaDoc modifiedDateStart) {
452         this.modifiedDateStart = modifiedDateStart;
453     }
454     
455     public Date JavaDoc getModifiedDateEnd() {
456         return modifiedDateEnd;
457     }
458     
459     public void setModifiedDateEnd(Date JavaDoc modifiedDateEnd) {
460         this.modifiedDateEnd = modifiedDateEnd;
461     }
462     
463     public Collection JavaDoc<Long JavaDoc> getItemIds() {
464         return itemIds;
465     }
466     
467     public void setItemIds(Collection JavaDoc<Long JavaDoc> itemIds) {
468         this.itemIds = itemIds;
469     }
470     
471     public Set JavaDoc<Long JavaDoc> getSpaceSet() {
472         return spaceSet;
473     }
474     
475     public void setSpaceSet(Set JavaDoc<Long JavaDoc> spaceSet) {
476         this.spaceSet = spaceSet;
477     }
478     
479     public Set JavaDoc<Integer JavaDoc> getStatusSet() {
480         return statusSet;
481     }
482     
483     public void setStatusSet(Set JavaDoc<Integer JavaDoc> statusSet) {
484         this.statusSet = statusSet;
485     }
486     
487     public Set JavaDoc<Integer JavaDoc> getSeveritySet() {
488         return severitySet;
489     }
490     
491     public void setSeveritySet(Set JavaDoc<Integer JavaDoc> severitySet) {
492         this.severitySet = severitySet;
493     }
494     
495     public Set JavaDoc<Integer JavaDoc> getPrioritySet() {
496         return prioritySet;
497     }
498     
499     public void setPrioritySet(Set JavaDoc<Integer JavaDoc> prioritySet) {
500         this.prioritySet = prioritySet;
501     }
502     
503     public Set JavaDoc<Long JavaDoc> getLoggedBySet() {
504         return loggedBySet;
505     }
506     
507     public void setLoggedBySet(Set JavaDoc<Long JavaDoc> loggedBySet) {
508         this.loggedBySet = loggedBySet;
509     }
510     
511     public Set JavaDoc<Long JavaDoc> getAssignedToSet() {
512         return assignedToSet;
513     }
514     
515     public void setAssignedToSet(Set JavaDoc<Long JavaDoc> assignedToSet) {
516         this.assignedToSet = assignedToSet;
517     }
518     
519     public Set JavaDoc<Integer JavaDoc> getCusInt01Set() {
520         return cusInt01Set;
521     }
522     
523     public void setCusInt01Set(Set JavaDoc<Integer JavaDoc> cusInt01Set) {
524         this.cusInt01Set = cusInt01Set;
525     }
526     
527     public Set JavaDoc<Integer JavaDoc> getCusInt02Set() {
528         return cusInt02Set;
529     }
530     
531     public void setCusInt02Set(Set JavaDoc<Integer JavaDoc> cusInt02Set) {
532         this.cusInt02Set = cusInt02Set;
533     }
534     
535     public Set JavaDoc<Integer JavaDoc> getCusInt03Set() {
536         return cusInt03Set;
537     }
538     
539     public void setCusInt03Set(Set JavaDoc<Integer JavaDoc> cusInt03Set) {
540         this.cusInt03Set = cusInt03Set;
541     }
542     
543     public Set JavaDoc<Integer JavaDoc> getCusInt04Set() {
544         return cusInt04Set;
545     }
546     
547     public void setCusInt04Set(Set JavaDoc<Integer JavaDoc> cusInt04Set) {
548         this.cusInt04Set = cusInt04Set;
549     }
550     
551     public Set JavaDoc<Integer JavaDoc> getCusInt05Set() {
552         return cusInt05Set;
553     }
554     
555     public void setCusInt05Set(Set JavaDoc<Integer JavaDoc> cusInt05Set) {
556         this.cusInt05Set = cusInt05Set;
557     }
558     
559     public Set JavaDoc<Integer JavaDoc> getCusInt06Set() {
560         return cusInt06Set;
561     }
562     
563     public void setCusInt06Set(Set JavaDoc<Integer JavaDoc> cusInt06Set) {
564         this.cusInt06Set = cusInt06Set;
565     }
566     
567     public Set JavaDoc<Integer JavaDoc> getCusInt07Set() {
568         return cusInt07Set;
569     }
570     
571     public void setCusInt07Set(Set JavaDoc<Integer JavaDoc> cusInt07Set) {
572         this.cusInt07Set = cusInt07Set;
573     }
574     
575     public Set JavaDoc<Integer JavaDoc> getCusInt08Set() {
576         return cusInt08Set;
577     }
578     
579     public void setCusInt08Set(Set JavaDoc<Integer JavaDoc> cusInt08Set) {
580         this.cusInt08Set = cusInt08Set;
581     }
582     
583     public Set JavaDoc<Integer JavaDoc> getCusInt09Set() {
584         return cusInt09Set;
585     }
586     
587     public void setCusInt09Set(Set JavaDoc<Integer JavaDoc> cusInt09Set) {
588         this.cusInt09Set = cusInt09Set;
589     }
590     
591     public Set JavaDoc<Integer JavaDoc> getCusInt10Set() {
592         return cusInt10Set;
593     }
594     
595     public void setCusInt10Set(Set JavaDoc<Integer JavaDoc> cusInt10Set) {
596         this.cusInt10Set = cusInt10Set;
597     }
598     
599     public String JavaDoc getCusStr01() {
600         return cusStr01;
601     }
602     
603     public void setCusStr01(String JavaDoc cusStr01) {
604         this.cusStr01 = cusStr01;
605     }
606     
607     public String JavaDoc getCusStr02() {
608         return cusStr02;
609     }
610     
611     public void setCusStr02(String JavaDoc cusStr02) {
612         this.cusStr02 = cusStr02;
613     }
614     
615     public String JavaDoc getCusStr03() {
616         return cusStr03;
617     }
618     
619     public void setCusStr03(String JavaDoc cusStr03) {
620         this.cusStr03 = cusStr03;
621     }
622     
623     public String JavaDoc getCusStr04() {
624         return cusStr04;
625     }
626     
627     public void setCusStr04(String JavaDoc cusStr04) {
628         this.cusStr04 = cusStr04;
629     }
630     
631     public String JavaDoc getCusStr05() {
632         return cusStr05;
633     }
634     
635     public void setCusStr05(String JavaDoc cusStr05) {
636         this.cusStr05 = cusStr05;
637     }
638     
639     public Date JavaDoc getCusTim01Start() {
640         return cusTim01Start;
641     }
642     
643     public void setCusTim01Start(Date JavaDoc cusTim01Start) {
644         this.cusTim01Start = cusTim01Start;
645     }
646     
647     public Date JavaDoc getCusTim01End() {
648         return cusTim01End;
649     }
650     
651     public void setCusTim01End(Date JavaDoc cusTim01End) {
652         this.cusTim01End = cusTim01End;
653     }
654     
655     public Date JavaDoc getCusTim02Start() {
656         return cusTim02Start;
657     }
658     
659     public void setCusTim02Start(Date JavaDoc cusTim02Start) {
660         this.cusTim02Start = cusTim02Start;
661     }
662     
663     public Date JavaDoc getCusTim02End() {
664         return cusTim02End;
665     }
666     
667     public void setCusTim02End(Date JavaDoc cusTim02End) {
668         this.cusTim02End = cusTim02End;
669     }
670     
671     public Date JavaDoc getCusTim03Start() {
672         return cusTim03Start;
673     }
674     
675     public void setCusTim03Start(Date JavaDoc cusTim03Start) {
676         this.cusTim03Start = cusTim03Start;
677     }
678     
679     public Date JavaDoc getCusTim03End() {
680         return cusTim03End;
681     }
682     
683     public void setCusTim03End(Date JavaDoc cusTim03End) {
684         this.cusTim03End = cusTim03End;
685     }
686     
687     public User getUser() {
688         return user;
689     }
690     
691     public void setUser(User user) {
692         this.user = user;
693     }
694     
695     public long getResultCount() {
696         return resultCount;
697     }
698     
699     public void setResultCount(long resultCount) {
700         this.resultCount = resultCount;
701     }
702             
703 }
704
Popular Tags