@Override public void loadXML( Node ruleNode ) throws KettleException { id = XMLHandler.getTagValue( ruleNode, "id" ); enabled = ValueMetaString.convertStringToBoolean( XMLHandler.getTagValue( ruleNode, "enabled" ) ); }
public synchronized boolean getJobEntryAttributeBoolean( ObjectId id_jobentry, int nr, String code, boolean def ) throws KettleException { RowMetaAndData r = getJobEntryAttributeRow( id_jobentry, nr, code ); if ( r == null ) { return def; } String v = r.getString( KettleDatabaseRepository.FIELD_JOBENTRY_ATTRIBUTE_VALUE_STR, null ); if ( v == null || Utils.isEmpty( v ) ) { return def; } return ValueMetaString.convertStringToBoolean( v ).booleanValue(); }
@Override public boolean getBooleanValueOfVariable( String variableName, boolean defaultValue ) { if ( !Utils.isEmpty( variableName ) ) { String value = environmentSubstitute( variableName ); if ( !Utils.isEmpty( value ) ) { return ValueMetaString.convertStringToBoolean( value ); } } return defaultValue; }
public boolean getBooleanValueOfVariable( String variableName, boolean defaultValue ) { if ( !Utils.isEmpty( variableName ) ) { String value = environmentSubstitute( variableName ); if ( !Utils.isEmpty( value ) ) { return ValueMetaString.convertStringToBoolean( value ); } } return defaultValue; }
@Override public boolean getBooleanValueOfVariable( String variableName, boolean defaultValue ) { if ( !Utils.isEmpty( variableName ) ) { String value = environmentSubstitute( variableName ); if ( !Utils.isEmpty( value ) ) { return ValueMetaString.convertStringToBoolean( value ); } } return defaultValue; }
public boolean getBooleanValueOfVariable( String variableName, boolean defaultValue ) { if ( !Utils.isEmpty( variableName ) ) { String value = environmentSubstitute( variableName ); if ( !Utils.isEmpty( value ) ) { return ValueMetaString.convertStringToBoolean( value ); } } return defaultValue; }
@Override public boolean getBooleanValueOfVariable( String variableName, boolean defaultValue ) { if ( !Utils.isEmpty( variableName ) ) { String value = environmentSubstitute( variableName ); if ( !Utils.isEmpty( value ) ) { return ValueMetaString.convertStringToBoolean( value ); } } return defaultValue; }
/** * Returns a boolean representation of the specified variable after performing any necessary substitution. Truth * values include case-insensitive versions of "Y", "YES", "TRUE" or "1". * * @param variableName the variable name * @param defaultValue the default value * @return a boolean representation of the specified variable after performing any necessary substitution * @see org.pentaho.di.core.variables.VariableSpace#getBooleanValueOfVariable(java.lang.String, boolean) */ @Override public boolean getBooleanValueOfVariable( String variableName, boolean defaultValue ) { if ( !Utils.isEmpty( variableName ) ) { String value = environmentSubstitute( variableName ); if ( !Utils.isEmpty( value ) ) { return ValueMetaString.convertStringToBoolean( value ); } } return defaultValue; }
public synchronized boolean getStepAttributeBoolean( ObjectId id_step, int nr, String code, boolean def ) throws KettleException { RowMetaAndData r = null; if ( stepAttributesBuffer != null ) { r = searchStepAttributeInBuffer( id_step, code, nr ); } else { r = getStepAttributeRow( id_step, nr, code ); } if ( r == null ) { return def; } String v = r.getString( KettleDatabaseRepository.FIELD_STEP_ATTRIBUTE_VALUE_STR, null ); if ( v == null || Utils.isEmpty( v ) ) { return def; } return ValueMetaString.convertStringToBoolean( v ).booleanValue(); }
/** * Returns a boolean representation of the specified variable after performing any necessary substitution. Truth * values include case-insensitive versions of "Y", "YES", "TRUE" or "1". * * @param variableName * the name of the variable to interrogate * @boolean defaultValue the value to use if the specified variable is unassigned. * @return a boolean representation of the specified variable after performing any necessary substitution * @see org.pentaho.di.core.variables.VariableSpace#getBooleanValueOfVariable(java.lang.String, boolean) */ @Override public boolean getBooleanValueOfVariable( String variableName, boolean defaultValue ) { if ( !Utils.isEmpty( variableName ) ) { String value = environmentSubstitute( variableName ); if ( !Utils.isEmpty( value ) ) { return ValueMetaString.convertStringToBoolean( value ); } } return defaultValue; }
Utils.isEmpty( optionReplace ) ? false : ValueMetaString.convertStringToBoolean( optionReplace.toString() ); final boolean continueOnError = Utils.isEmpty( optionContinueOnError ) ? false : ValueMetaString.convertStringToBoolean( optionContinueOnError .toString() );
public void start( CommandLineOption[] options ) throws KettleException { // Read the start option parameters // handleStartOptions( options ); // Enable menus based on whether user was able to login or not // enableMenus(); // enable perspective switching SpoonPerspectiveManager.getInstance().setForcePerspective( false ); if ( splash != null ) { splash.dispose(); splash = null; } // If we are a MILESTONE or RELEASE_CANDIDATE if ( !ValueMetaString.convertStringToBoolean( System.getProperty( "KETTLE_HIDE_DEVELOPMENT_VERSION_WARNING", "N" ) ) && Const.RELEASE.equals( Const.ReleaseType.MILESTONE ) ) { // display the same warning message MessageBox dialog = new MessageBox( shell, SWT.ICON_WARNING ); dialog.setText( BaseMessages.getString( PKG, "Spoon.Warning.DevelopmentRelease.Title" ) ); dialog.setMessage( BaseMessages.getString( PKG, "Spoon.Warning.DevelopmentRelease.Message", Const.CR, BuildVersion.getInstance().getVersion() ) ); dialog.open(); } }
boolean valuebool; try { valuebool = ValueMetaString.convertStringToBoolean( sourcevalue ); } catch ( Exception e ) { logError( BaseMessages.getString( PKG, "JobEntrySimpleEval.Error.UnparsableBoolean", sourcevalue, e
ValueMetaString.convertStringToBoolean( System.getProperty( Const.KETTLE_BATCHING_ROWSET ) ); if ( batchingRowSet != null && batchingRowSet.booleanValue() ) { rowSet = new BlockingBatchingRowSet( transMeta.getSizeRowset() );