Package net.sourceforge.jivalo.platform.logging

Examples of net.sourceforge.jivalo.platform.logging.LogQueryBuilder


                Level level = (Level) levelBox.getSelectedItem();
                String component = componentField.getText().trim();
                String className = classField.getText().trim();
                String methodName = methodField.getText().trim();

                LogQueryBuilder builder = null;
        try {
          builder = new LogQueryBuilder((PersistentHandler)ServiceManager.getService(PersistentHandler.JIVALO_PERSISTENT_HANDLER_LOOKUP_NAME));
        } catch (BaseException ex) {
                    ex.printStackTrace();
                    JOptionPane.showMessageDialog(LogSearchPanel.this.viewer,
                                                  "Error while getting PersistentHandler: " +
                                                  ex.getMessage());
                    return;
        }
                builder.addConditionStartDate(startDate);
                builder.addConditionEndDate(endDate);
                if (!level.equals(Level.ALL)) {
                    builder.addConditionThresholdLevel(level);
                }
                if (component.length() > 0) {
                    builder.addConditionComponentID(component);
                }
                if (className.length() > 0) {
                    builder.addConditionClassNameContains(className);
                }
                if (methodName.length() > 0) {
                    builder.addConditionMethodNameContains(methodName);
                }
                try {
                    List records = builder.getLogRecords();
                    LogSearchPanel.this.viewer.refreshList(records);
                    LogSearchPanel.this.viewer.recordSelected(null);
                }
                catch (Exception ex) {
                    ex.printStackTrace();
View Full Code Here

TOP

Related Classes of net.sourceforge.jivalo.platform.logging.LogQueryBuilder

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.