code: private int parseInteger(String value, int defaultValue)
  	{
  		try
  		{
  			return Integer.parseInt(value);
  		}
  		catch (NumberFormatException e)
  		{
  			return defaultValue;
  		}
  	}
docs: Parses an integer.
  
  @param value
  The value to parse.
  @return The parsed integer.