/** * Determine if an object is null. This is the case if data==null or if it's an empty string. * * @param data * the object to test * @return true if the object is considered null. * @throws KettleValueException * in case there is a conversion error (only thrown in case of lazy conversion) */ @Override public boolean isNull( Object data ) throws KettleValueException { //noinspection deprecation return isNull( data, EMPTY_STRING_AND_NULL_ARE_DIFFERENT ); }
switch ( getType() ) { case ValueMetaInterface.TYPE_NUMBER: if ( !isNull( data ) ) { double num = getNumber( data ).doubleValue(); if ( databaseMeta.supportsFloatRoundingOnUpdate() && getPrecision() >= 0 ) { if ( !isNull( data ) ) { if ( databaseMeta.supportsSetLong() ) { preparedStatement.setLong( index, getInteger( data ).longValue() ); if ( !isNull( data ) ) { if ( getLength() == DatabaseMeta.CLOB_LENGTH ) { setLength( databaseMeta.getMaxTextFieldLength() ); if ( !isNull( data ) ) { case ValueMetaInterface.TYPE_BOOLEAN: if ( databaseMeta.supportsBooleanDataType() ) { if ( !isNull( data ) ) { preparedStatement.setBoolean( index, getBoolean( data ).booleanValue() ); } else { if ( !isNull( data ) ) { preparedStatement.setString( index, getBoolean( data ).booleanValue() ? "Y" : "N" ); } else { if ( !isNull( data ) ) { preparedStatement.setBigDecimal( index, getBigNumber( data ) ); } else {
int hash = 0; if ( isNull( object ) ) { switch ( getType() ) { case TYPE_BOOLEAN:
@Override public Long getInteger( Object object ) throws KettleValueException { try { if ( isNull( object ) ) { return null;
@Override public Double getNumber( Object object ) throws KettleValueException { try { if ( isNull( object ) ) { return null;
@Override public BigDecimal getBigNumber( Object object ) throws KettleValueException { try { if ( isNull( object ) ) { return null;
value.setLength( length, precision ); if ( isNull( data ) ) { value.setNull(); } else {
@Override public Date getDate( Object object ) throws KettleValueException { if ( isNull( object ) ) { return null;