public Integer getInt ( String name , Integer def ) { final String s = getProperty ( name ) ; try { return Integer . parseInt ( s ) ; } catch ( Exception e ) { return def ; } }
Returns the property assuming its an int . If it isn t or if its not defined returns default value