}
List v = new Vector();
ForumFactory forumFactory = ForumFactory.getInstance(getAuthToken(request));
ProfileManager manager = forumFactory.getProfileManager();
Iterator userIterator = null;
if (request.getParameter("query") != null) {
//::TODO::search, not very nice
String query = request.getParameter("query");
userIterator = manager.users();
List tempListe = new ArrayList();
User userTemp = null;
int c = 0;
while (userIterator.hasNext()) {
userTemp = (User) userIterator.next();
if (userTemp.getName().toLowerCase().indexOf(query.toLowerCase()) > -1
|| userTemp.getUsername().toLowerCase().indexOf(query.toLowerCase()) > -1
|| userTemp.getEmail().toLowerCase().indexOf(query.toLowerCase()) > -1) {
//match
if(c >= start && c<(start+maxPageItems)){
tempListe.add(userTemp);
}
c++;
}
}
userIterator = tempListe.iterator();
request.setAttribute("nbItems", new Integer(c));
request.setAttribute("query", query);
} else {
userIterator = manager.users(start, maxPageItems);
request.setAttribute("nbItems", new Integer(manager.getUserCount()));
}
//populate
String temp = null;
UserBean ub = null;
User user = null;