Package org.jresearch.gossip.beans

Examples of org.jresearch.gossip.beans.LogSearchCriteria


     */
    protected ActionForward process(ActionMapping mapping, ActionForm form,
            HttpServletRequest request, HttpServletResponse response)
            throws JGossipException {
        SearchLogForm slForm = (SearchLogForm) form;
        LogSearchCriteria criteria = slForm.getSearchCriteria();
        request.getSession().setAttribute(IConst.SESSION.SEARCH_CRITERIA_LOG,
                criteria);
        return (mapping.findForward(IConst.TOKEN.PAGE));
    }
View Full Code Here


            User user = (User) session.getAttribute(IConst.SESSION.USER_KEY);
            records.setBlockSize((null != user) ? user.getSettings()
                    .getMes_per_page() : 25);
            if (session.getAttribute(IConst.SESSION.SEARCH_CRITERIA_LOG) == null) {
                session.setAttribute(IConst.SESSION.SEARCH_CRITERIA_LOG,
                        new LogSearchCriteria());
            }
            LogSearchCriteria criteria = (LogSearchCriteria) session
                    .getAttribute(IConst.SESSION.SEARCH_CRITERIA_LOG);
            int block = Integer.parseInt(lForm.getBlock());
            dao.fillLogEntryList(criteria, records, block);
            request.setAttribute(IConst.REQUEST.RECORDS_DATA, records);
            ArrayIterator it = new ArrayIterator();
View Full Code Here

    /**
     * @return
     */
    public LogSearchCriteria getSearchCriteria() {
        return new LogSearchCriteria(getFrom(), getTo(),
                logger.equals("") ? IConst.VALUES.ALL : logger.trim(), log_level
                        .equals("") ? IConst.VALUES.ALL : log_level.trim(), remote_ip
                        .equals("") ? IConst.VALUES.ALL : remote_ip.trim(), user_name
                        .equals("") ? IConst.VALUES.ALL : user_name.trim(), session_id
                        .equals("") ? IConst.VALUES.ALL : session_id.trim(), true);
View Full Code Here

  final public void testFillLogEntryList() throws Exception
  {
    RecordsData records = new RecordsData();
    User user = null;
    records.setBlockSize((null != user)?user.getSettings().getMes_per_page():25);
    LogSearchCriteria criteria = new LogSearchCriteria();
    criteria.setFrom(from);
    criteria.setTo(to);
    criteria.setLog_level(IConst.VALUES.ALL);
    criteria.setLogger(IConst.VALUES.ALL);
    criteria.setRemote_ip(IConst.VALUES.ALL);
    criteria.setSession_id(IConst.VALUES.ALL);
    criteria.setUser_name(IConst.VALUES.ALL);
    int block = 1;
    dao.fillLogEntryList(criteria, records, block);
    Iterator it = records.getRecords().iterator();
    assertTrue(it.hasNext());
    assertTrue(records.getRecordsCount() > 0);
View Full Code Here

  final public void testFillLogEntryListWARN() throws Exception
  {
    RecordsData records = new RecordsData();
    User user = null;
    records.setBlockSize((null != user)?user.getSettings().getMes_per_page():25);
    LogSearchCriteria criteria = new LogSearchCriteria();
    criteria.setFrom(from);
    criteria.setTo(to);
    criteria.setLog_level("WARN");
    criteria.setLogger(IConst.VALUES.ALL);
    criteria.setRemote_ip(IConst.VALUES.ALL);
    criteria.setSession_id(IConst.VALUES.ALL);
    criteria.setUser_name(IConst.VALUES.ALL);
    int block = 1;
    dao.fillLogEntryList(criteria, records, block);
    Iterator it = records.getRecords().iterator();
    assertTrue(!it.hasNext());
    assertTrue(records.getRecordsCount() == 0);
View Full Code Here

  final public void testFillLogEntryListINFO() throws Exception
  {
    RecordsData records = new RecordsData();
    User user = null;
    records.setBlockSize((null != user)?user.getSettings().getMes_per_page():25);
    LogSearchCriteria criteria = new LogSearchCriteria();
    criteria.setFrom(from);
    criteria.setTo(to);
    criteria.setLog_level("INFO");
    criteria.setLogger("FORUM");
    criteria.setRemote_ip(IConst.VALUES.ALL);
    criteria.setSession_id(IConst.VALUES.ALL);
    criteria.setUser_name(IConst.VALUES.ALL);
    int block = 1;
    dao.fillLogEntryList(criteria, records, block);
    Iterator it = records.getRecords().iterator();
    assertTrue(it.hasNext());
    assertTrue(records.getRecordsCount() > 0);
View Full Code Here

TOP

Related Classes of org.jresearch.gossip.beans.LogSearchCriteria

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.