/**
   * The getPropertyInfo method is intended to allow a generic GUI tool to discover what properties
   * it should prompt a human for in order to get enough information to connect to a database.
   *
   * <p>Note that depending on the values the human has supplied so far, additional values may
   * become necessary, so it may be necessary to iterate through several calls to getPropertyInfo
   *
   * @param url the Url of the database to connect to
   * @param info a proposed list of tag/value pairs that will be sent on connect open.
   * @return An array of DriverPropertyInfo objects describing possible properties. This array may
   *     be an empty array if no properties are required
   * @exception SQLException if a database-access error occurs
   * @see java.sql.Driver#getPropertyInfo
   */
  public DriverPropertyInfo[] getPropertyInfo(String url, Properties info) throws SQLException {
    if (info == null) {
      info = new Properties();
    }

    if ((url != null) && url.startsWith(URL_PREFIX)) { // $NON-NLS-1$
      info = parseURL(url, info);
    }

    DriverPropertyInfo hostProp =
        new DriverPropertyInfo(
            HOST_PROPERTY_KEY, //$NON-NLS-1$
            info.getProperty(HOST_PROPERTY_KEY)); // $NON-NLS-1$
    hostProp.required = true;
    hostProp.description = Messages.getString("NonRegisteringDriver.3"); // $NON-NLS-1$

    DriverPropertyInfo portProp =
        new DriverPropertyInfo(
            PORT_PROPERTY_KEY, //$NON-NLS-1$
            info.getProperty(PORT_PROPERTY_KEY, "3306")); // $NON-NLS-1$ //$NON-NLS-2$
    portProp.required = false;
    portProp.description = Messages.getString("NonRegisteringDriver.7"); // $NON-NLS-1$

    DriverPropertyInfo dbProp =
        new DriverPropertyInfo(
            DBNAME_PROPERTY_KEY, //$NON-NLS-1$
            info.getProperty(DBNAME_PROPERTY_KEY)); // $NON-NLS-1$
    dbProp.required = false;
    dbProp.description = "Database name"; // $NON-NLS-1$

    DriverPropertyInfo userProp =
        new DriverPropertyInfo(
            USER_PROPERTY_KEY, //$NON-NLS-1$
            info.getProperty(USER_PROPERTY_KEY)); // $NON-NLS-1$
    userProp.required = true;
    userProp.description = Messages.getString("NonRegisteringDriver.13"); // $NON-NLS-1$

    DriverPropertyInfo passwordProp =
        new DriverPropertyInfo(
            PASSWORD_PROPERTY_KEY, //$NON-NLS-1$
            info.getProperty(PASSWORD_PROPERTY_KEY)); // $NON-NLS-1$
    passwordProp.required = true;
    passwordProp.description = Messages.getString("NonRegisteringDriver.16"); // $NON-NLS-1$

    DriverPropertyInfo[] dpi = ConnectionPropertiesImpl.exposeAsDriverPropertyInfo(info, 5);

    dpi[0] = hostProp;
    dpi[1] = portProp;
    dpi[2] = dbProp;
    dpi[3] = userProp;
    dpi[4] = passwordProp;

    return dpi;
  }