protected boolean getBoolean( DataNode node, String name, boolean defaultValue ) { if ( node.hasProperty( name ) ) { return node.getProperty( name ).getBoolean(); } else { return defaultValue; } }
public long getJobEntryAttributeInteger( ObjectId idJobentry, int nr, String code ) throws KettleException { if ( node.hasProperty( code + PROP_CODE_NR_SEPARATOR + nr ) ) { return node.getProperty( code + PROP_CODE_NR_SEPARATOR + nr ).getLong(); } else if ( nr == 0 && node.hasProperty( code ) ) { // Old pur stored elements with no nr when not specified return node.getProperty( code ).getLong(); } else { return 0; } }
public String getAttributeString( String code ) { DataProperty property = dataNode.getProperty( code ); if ( property != null ) { return property.getString(); } return null; }
public String getJobEntryAttributeString( ObjectId idJobentry, int nr, String code ) throws KettleException { String propName = code + PROP_CODE_NR_SEPARATOR + nr; if ( node.hasProperty( propName ) ) { return node.getProperty( propName ).getString(); } else if ( nr == 0 && node.hasProperty( code ) ) { // Old pur stored elements with no nr when not specified return node.getProperty( code ).getString(); } else { return null; } }
protected Date getDate( DataNode node, String name ) { if ( node.hasProperty( name ) ) { return node.getProperty( name ).getDate(); } else { return null; } }
public void insertStepDatabase( ObjectId idTransformation, ObjectId idStep, ObjectId idDatabase ) throws KettleException { DataNodeRef ref = new DataNodeRef( idDatabase.getId() ); node.setProperty( idDatabase.getId(), ref ); }
public boolean getAttributeBoolean( String code ) { DataProperty property = dataNode.getProperty( code ); if ( property != null ) { return property.getBoolean(); } return false; }
public long getAttributeInteger( String code ) { DataProperty property = dataNode.getProperty( code ); if ( property != null ) { return property.getLong(); } return 0L; }
protected int getPropertyCount( final ObjectId idStep, final String code ) throws KettleException { int count = 0; for ( DataProperty prop : node.getProperties() ) { if ( prop.getName().startsWith( code + PROP_CODE_NR_SEPARATOR ) ) { count++; } } return count; }
public void saveJobEntryAttribute( ObjectId idJob, ObjectId idJobentry, int nr, String code, long value ) throws KettleException { node.setProperty( code + PROP_CODE_NR_SEPARATOR + nr, value ); }
protected String getString( DataNode node, String name ) { if ( node.hasProperty( name ) ) { return node.getProperty( name ).getString(); } else { return null; } }
public boolean getStepAttributeBoolean( ObjectId idStep, int nr, String code, boolean def ) throws KettleException { if ( node.hasProperty( code + PROP_CODE_NR_SEPARATOR + nr ) ) { return node.getProperty( code + PROP_CODE_NR_SEPARATOR + nr ).getBoolean(); } else if ( nr == 0 && node.hasProperty( code ) ) { // Old pur stored elements with no nr when not specified return node.getProperty( code ).getBoolean(); } else { return def; } }
public long getStepAttributeInteger( ObjectId idStep, int nr, String code ) throws KettleException { if ( node.hasProperty( code + PROP_CODE_NR_SEPARATOR + nr ) ) { return node.getProperty( code + PROP_CODE_NR_SEPARATOR + nr ).getLong(); } else if ( nr == 0 && node.hasProperty( code ) ) { // Old pur stored elements with no nr when not specified return node.getProperty( code ).getLong(); } else { return 0; } }
public void insertJobEntryDatabase( ObjectId idJob, ObjectId idJobentry, ObjectId idDatabase ) throws KettleException { DataNodeRef ref = new DataNodeRef( idDatabase.getId() ); node.setProperty( idDatabase.getId(), ref ); }
public void saveJobEntryAttribute( ObjectId idJob, ObjectId idJobentry, int nr, String code, String value ) throws KettleException { node.setProperty( code + PROP_CODE_NR_SEPARATOR + nr, value ); }
public String getStepAttributeString( ObjectId idStep, int nr, String code ) throws KettleException { String propName = code + PROP_CODE_NR_SEPARATOR + nr; if ( node.hasProperty( propName ) ) { return node.getProperty( propName ).getString(); } else if ( nr == 0 && node.hasProperty( code ) ) { // Old pur stored elements with no nr when not specified return node.getProperty( code ).getString(); } else { return null; } }
@Override public boolean getJobEntryAttributeBoolean( ObjectId idJobentry, int nr, String code, boolean def ) throws KettleException { String attribute = code + PROP_CODE_NR_SEPARATOR + nr; if ( node.hasProperty( attribute ) ) { return node.getProperty( attribute ).getBoolean(); } else if ( nr == 0 && node.hasProperty( code ) ) { // Old pur stored elements with no nr when not specified return node.getProperty( code ).getBoolean(); } else { return def; } }
protected long getLong( DataNode node, String name ) { if ( node.hasProperty( name ) ) { return node.getProperty( name ).getLong(); } else { return 0L; } }
public void saveStepAttribute( ObjectId idTransformation, ObjectId idStep, int nr, String code, boolean value ) throws KettleException { node.setProperty( code + PROP_CODE_NR_SEPARATOR + nr, value ); }
public void saveStepAttribute( ObjectId idTransformation, ObjectId idStep, int nr, String code, long value ) throws KettleException { node.setProperty( code + PROP_CODE_NR_SEPARATOR + nr, value ); }