code: public static int getIntValue(String value, int defaultValue, String key) {
  
          int result;
          try {
              result = Integer.valueOf(value).intValue();
          } catch (Exception e) {
              if (LOG.isDebugEnabled()) {
                  LOG.debug(Messages.get().getBundle().key(Messages.ERR_UNABLE_TO_PARSE_INT_2, value, key));
              }
              result = defaultValue;
          }
          return result;
      }
docs: Returns the Integer (int) value for the given String value.<p>
  
  All parse errors are caught and the given default value is returned in this case.<p>
  
  @param value the value to parse as int
  @param defaultValue the default value in case of parsing errors
  @param key a key to be included in the debug output in case of parse errors
  
  @return the int value for the given parameter value String