code: public static String calculateCheckDigit(final String iban) throws IbanFormatException {
          final String reformattedIban = replaceCheckDigit(iban,
                  Iban.DEFAULT_CHECK_DIGIT);
          final int modResult = calculateMod(reformattedIban);
          final int checkDigitIntValue = (98 - modResult);
          final String checkDigit = Integer.toString(checkDigitIntValue);
          return checkDigitIntValue > 9 ? checkDigit : "0" + checkDigit;
      }
docs: Calculates Iban
  <a href="http://en.wikipedia.org/wiki/ISO_13616#Generating_IBAN_check_digits">Check Digit</a>.
  
  @param iban string value
  @throws IbanFormatException if iban contains invalid character.
  
  @return check digit as String