/** * Return the log level for a certain log level code * * @param code * the code to look for * @return the log level or BASIC if nothing matches. */ public static LogLevel getLogLevelForCode( String code ) { for ( LogLevel logLevel : values() ) { if ( logLevel.getCode().equals( code ) ) { return logLevel; } } return BASIC; }
public void getInfo() { try { configuration.setReplayDate( null ); // removed from new execution dialog. getConfiguration().setRunConfiguration( wRunConfiguration.getText() ); configuration.setSafeModeEnabled( wSafeMode.getSelection() ); configuration.setClearingLog( wClearLog.getSelection() ); configuration.setLogLevel( LogLevel.values()[wLogLevel.getSelectionIndex()] ); configuration.setGatheringMetrics( wGatherMetrics.getSelection() ); // The lower part of the dialog... getInfoParameters(); getInfoVariables(); } catch ( Exception e ) { new ErrorDialog( shell, "Error in settings", "There is an error in the dialog settings", e ); } }
private void ok() { int idx = wLoglevel.getSelectionIndex(); DefaultLogLevel.setLogLevel( LogLevel.values()[idx] ); /* * String filter = wFilter.getText(); if (Utils.isEmpty(filter)) { LogWriter.getInstance().setFilter(null); // clear * filter } else { LogWriter.getInstance().setFilter(wFilter.getText()); } // * layout.setTimeAdded(wTime.getSelection()); */ // props.setLogFilter(wFilter.getText()); props.setLogLevel( wLoglevel.getText() ); props.saveProps(); dispose(); } }
private void ok() { if ( Utils.isEmpty( wName.getText() ) ) { MessageBox mb = new MessageBox( shell, SWT.OK | SWT.ICON_ERROR ); mb.setText( BaseMessages.getString( PKG, "System.StepJobEntryNameMissing.Title" ) ); mb.setMessage( BaseMessages.getString( PKG, "System.JobEntryNameMissing.Msg" ) ); mb.open(); return; } jobEntry.setName( wName.getText() ); jobEntry.setLogMessage( wLogMessage.getText() ); jobEntry.setLogSubject( wLogSubject.getText() ); if ( wLoglevel.getSelectionIndex() != -1 ) { jobEntry.setEntryLogLevel( LogLevel.values()[wLoglevel.getSelectionIndex()] ); } dispose(); } }
jobEntry.logext = wLogext.getText(); if ( wLoglevel.getSelectionIndex() >= 0 ) { jobEntry.logFileLevel = LogLevel.values()[wLoglevel.getSelectionIndex()]; } else { jobEntry.logFileLevel = LogLevel.BASIC;
public void getInfo() { try { getConfiguration().setExpandingRemoteJob( wExpandRemote.getSelection() ); getConfiguration().setRunConfiguration( wRunConfiguration.getText() ); // various settings // configuration.setReplayDate( null ); configuration.setSafeModeEnabled( wSafeMode.getSelection() ); configuration.setClearingLog( wClearLog.getSelection() ); configuration.setLogLevel( LogLevel.values()[wLogLevel.getSelectionIndex()] ); String startCopyName = null; int startCopyNr = 0; if ( !Utils.isEmpty( wStartCopy.getText() ) ) { if ( wStartCopy.getSelectionIndex() >= 0 ) { JobEntryCopy copy = ( (JobMeta) abstractMeta ).getJobCopies().get( wStartCopy.getSelectionIndex() ); startCopyName = copy.getName(); startCopyNr = copy.getNr(); } } getConfiguration().setStartCopyName( startCopyName ); getConfiguration().setStartCopyNr( startCopyNr ); // The lower part of the dialog... getInfoParameters(); getInfoVariables(); // Metrics configuration.setGatheringMetrics( wGatherMetrics.getSelection() ); } catch ( Exception e ) { new ErrorDialog( shell, "Error in settings", "There is an error in the dialog settings", e ); } }
jej.logext = wLogext.getText(); if ( wLoglevel.getSelectionIndex() >= 0 ) { jej.logFileLevel = LogLevel.values()[wLoglevel.getSelectionIndex()]; } else { jej.logFileLevel = LogLevel.BASIC;
jet.logFileLevel = LogLevel.values()[ wLoglevel.getSelectionIndex() ]; } else { jet.logFileLevel = LogLevel.BASIC;