Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4941661

SPEC BUG: javax.sql.rowset.BaseRowSet: ambiguity regarding default value

XMLWordPrintable

    • beta
    • sparc
    • solaris_2.6



      Name: sdR10048 Date: 10/22/2003


      Filed By : SPB JCK team (###@###.###)
      JDK : java full version "1.5.0-beta-b23"

      Problem description
      ===================
      There some methods in BaseRowSet class (they look like getXXX()) with
      an ambiguity regarding default value.
      They are (with appropriate quotes):

      public int getConcurrency() throws java.sql.SQLException

          "In other words, when a default RowSet object is created, it is as
           if the following BaseRowSet methods had been called:
           ...
           setConcurrency(ResultSet.CONCUR_READ_ONLY);"

          "The default is CONCUR_UPDATABLE."

          "Throws: java.sql.SQLException -...if no concurrency has been set."
          (It IS set - in constructor, see 1st quote)

      public int getMaxFieldSize() throws java.sql.SQLExceptionThrows:

          "java.sql.SQLException - ... or if no max field size has been
           set."

          "In other words, when a default RowSet object is created, it is as
           if the following BaseRowSet methods had been called:
           ...
           setMaxFieldSize(0);"

      public int getMaxRows() throws java.sql.SQLException

          "Throws: java.sql.SQLException - ... or if no max rows has been
           set."

          "In other words, when a default RowSet object is created, it is as
           if the following BaseRowSet methods had been called:
           ...
           setMaxRows(0);"

      public int getQueryTimeout() throws java.sql.SQLException

          "In other words, when a default RowSet object is created, it is as
           if the following BaseRowSet methods had been called:
           ...
           setQueryTimeout(0);"

          "Returns: ... zero means that there is no limit"

          "Throws: java.sql.SQLException - ... or if no query time-out value
           has been set ..."
          (It IS set - in constructor, see 1st quote)

          "Throws: java.sql.SQLException - ... ...
           or if the query time-out is of value 0 or less."
           (contradicts with @return tag)
           (also this can not be, since setQueryTimeout throws SQLException
            in case query time-out is of value 0 or less.)


      public boolean getShowDeleted() throws java.sql.SQLException

          "In other words, when a default RowSet object is created, it is as
           if the following BaseRowSet methods had been called:
           setShowDeleted(false);"

          "The following is true of a default BaseRowSet instance:
           Does not show deleted rows"

          "Throws:
           java.sql.SQLException - ... or if deleted row visibility is not
           set."
          (It IS set - in constructor, see 1st quote)

      public boolean isReadOnly()

          "By default, rowsets are updatable if updates are possible."

          "In other words, when a default RowSet object is created, it is as
           if the following BaseRowSet methods had been called:
           ...
           setReadOnly(true);"


      ======================================================================

            jbrucesunw Jonathan Bruce (Inactive)
            dsvsunw Dsv Dsv (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: