code: private int indexToOutputIndex(int parameterIndex) throws SQLException {
      try {
        if (outputParameterMapper[parameterIndex - 1] == -1) {
          //this is not an outputParameter
          throw new SQLException("Parameter in index '" + parameterIndex
              + "' is not declared as output parameter with method registerOutParameter");
        }
        return outputParameterMapper[parameterIndex - 1];
      } catch (ArrayIndexOutOfBoundsException arrayIndexOutOfBoundsException) {
        if (parameterIndex < 1) {
          throw new SQLException("Index " + parameterIndex + " must at minimum be 1");
        }
        throw new SQLException("Index value '" + parameterIndex
            + "' is incorrect. Maximum value is " + params.size());
      }
    }
docs: Convert parameter index to corresponding outputIndex.
  
  @param parameterIndex index
  @return index
  @throws SQLException exception