code: int getIntProperty(String name, int defaultValue) {
          String val = getProperty(name);
          if (val == null) {
              return defaultValue;
          }
          try {
              return Integer.parseInt(val.trim());
          } catch (Exception ex) {
              return defaultValue;
          }
      }
docs: we return the given default value.