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

updated Deprecated JDBC methods to include the since element

    XMLWordPrintable

Details

    • b144

    Description

      The following methods will have their Deprecated annotation updated:

      $ hg diff
      diff -r 77f35eef4ef9 src/java.sql/share/classes/java/sql/CallableStatement.java
      --- a/src/java.sql/share/classes/java/sql/CallableStatement.java Mon Oct 31 16:41:41 2016 +0800
      +++ b/src/java.sql/share/classes/java/sql/CallableStatement.java Tue Nov 01 17:11:23 2016 -0400
      @@ -295,7 +295,7 @@
            * or <code>getBigDecimal(String parameterName)</code>
            * @see #setBigDecimal
            */
      - @Deprecated
      + @Deprecated(since="1.2")
           BigDecimal getBigDecimal(int parameterIndex, int scale)
               throws SQLException;
       
      diff -r 77f35eef4ef9 src/java.sql/share/classes/java/sql/Date.java
      --- a/src/java.sql/share/classes/java/sql/Date.java Mon Oct 31 16:41:41 2016 +0800
      +++ b/src/java.sql/share/classes/java/sql/Date.java Tue Nov 01 17:11:23 2016 -0400
      @@ -58,7 +58,7 @@
            * @param day 1 to 31
            * @deprecated instead use the constructor <code>Date(long date)</code>
            */
      - @Deprecated
      + @Deprecated(since="1.2")
           public Date(int year, int month, int day) {
               super(year, month, day);
           }
      @@ -199,7 +199,7 @@
           * @exception java.lang.IllegalArgumentException if this method is invoked
           * @see #setHours
           */
      - @Deprecated
      + @Deprecated(since="1.2")
           public int getHours() {
               throw new java.lang.IllegalArgumentException();
           }
      @@ -212,7 +212,7 @@
           * @exception java.lang.IllegalArgumentException if this method is invoked
           * @see #setMinutes
           */
      - @Deprecated
      + @Deprecated(since="1.2")
           public int getMinutes() {
               throw new java.lang.IllegalArgumentException();
           }
      @@ -225,7 +225,7 @@
           * @exception java.lang.IllegalArgumentException if this method is invoked
           * @see #setSeconds
           */
      - @Deprecated
      + @Deprecated(since="1.2")
           public int getSeconds() {
               throw new java.lang.IllegalArgumentException();
           }
      @@ -238,7 +238,7 @@
           * @exception java.lang.IllegalArgumentException if this method is invoked
           * @see #getHours
           */
      - @Deprecated
      + @Deprecated(since="1.2")
           public void setHours(int i) {
               throw new java.lang.IllegalArgumentException();
           }
      @@ -251,7 +251,7 @@
           * @exception java.lang.IllegalArgumentException if this method is invoked
           * @see #getMinutes
           */
      - @Deprecated
      + @Deprecated(since="1.2")
           public void setMinutes(int i) {
               throw new java.lang.IllegalArgumentException();
           }
      @@ -264,7 +264,7 @@
           * @exception java.lang.IllegalArgumentException if this method is invoked
           * @see #getSeconds
           */
      - @Deprecated
      + @Deprecated(since="1.2")
           public void setSeconds(int i) {
               throw new java.lang.IllegalArgumentException();
           }
      diff -r 77f35eef4ef9 src/java.sql/share/classes/java/sql/DriverManager.java
      --- a/src/java.sql/share/classes/java/sql/DriverManager.java Mon Oct 31 16:41:41 2016 +0800
      +++ b/src/java.sql/share/classes/java/sql/DriverManager.java Tue Nov 01 17:11:23 2016 -0400
      @@ -515,7 +515,7 @@
            * @see SecurityManager#checkPermission
            * @see #getLogStream
            */
      - @Deprecated
      + @Deprecated(since="1.2")
           public static void setLogStream(java.io.PrintStream out) {
       
               SecurityManager sec = System.getSecurityManager();
      @@ -538,7 +538,7 @@
            * @deprecated Use {@code getLogWriter}
            * @see #setLogStream
            */
      - @Deprecated
      + @Deprecated(since="1.2")
           public static java.io.PrintStream getLogStream() {
               return logStream;
           }
      diff -r 77f35eef4ef9 src/java.sql/share/classes/java/sql/PreparedStatement.java
      --- a/src/java.sql/share/classes/java/sql/PreparedStatement.java Mon Oct 31 16:41:41 2016 +0800
      +++ b/src/java.sql/share/classes/java/sql/PreparedStatement.java Tue Nov 01 17:11:23 2016 -0400
      @@ -344,7 +344,7 @@
            * this method
            * @deprecated Use {@code setCharacterStream}
            */
      - @Deprecated
      + @Deprecated(since="1.2")
           void setUnicodeStream(int parameterIndex, java.io.InputStream x,
                                 int length) throws SQLException;
       
      diff -r 77f35eef4ef9 src/java.sql/share/classes/java/sql/ResultSet.java
      --- a/src/java.sql/share/classes/java/sql/ResultSet.java Mon Oct 31 16:41:41 2016 +0800
      +++ b/src/java.sql/share/classes/java/sql/ResultSet.java Tue Nov 01 17:11:23 2016 -0400
      @@ -358,7 +358,7 @@
            * @deprecated Use {@code getBigDecimal(int columnIndex)}
            * or {@code getBigDecimal(String columnLabel)}
            */
      - @Deprecated
      + @Deprecated(since="1.2")
           BigDecimal getBigDecimal(int columnIndex, int scale) throws SQLException;
       
           /**
      @@ -478,7 +478,7 @@
            * @deprecated use <code>getCharacterStream</code> in place of
            * <code>getUnicodeStream</code>
            */
      - @Deprecated
      + @Deprecated(since="1.2")
           java.io.InputStream getUnicodeStream(int columnIndex) throws SQLException;
       
           /**
      @@ -646,7 +646,7 @@
            * @deprecated Use {@code getBigDecimal(int columnIndex)}
            * or {@code getBigDecimal(String columnLabel)}
            */
      - @Deprecated
      + @Deprecated(since="1.2")
           BigDecimal getBigDecimal(String columnLabel, int scale) throws SQLException;
       
           /**
      @@ -764,7 +764,7 @@
            * this method
            * @deprecated use <code>getCharacterStream</code> instead
            */
      - @Deprecated
      + @Deprecated(since="1.2")
           java.io.InputStream getUnicodeStream(String columnLabel) throws SQLException;
       
           /**
      diff -r 77f35eef4ef9 src/java.sql/share/classes/java/sql/Time.java
      --- a/src/java.sql/share/classes/java/sql/Time.java Mon Oct 31 16:41:41 2016 +0800
      +++ b/src/java.sql/share/classes/java/sql/Time.java Tue Nov 01 17:11:23 2016 -0400
      @@ -60,7 +60,7 @@
            * @deprecated Use the constructor that takes a milliseconds value
            * in place of this constructor
            */
      - @Deprecated
      + @Deprecated(since="1.2")
           public Time(int hour, int minute, int second) {
               super(70, 0, 1, hour, minute, second);
           }
      @@ -146,7 +146,7 @@
           * method is invoked
           * @see #setYear
           */
      - @Deprecated
      + @Deprecated(since="1.2")
           public int getYear() {
               throw new java.lang.IllegalArgumentException();
           }
      @@ -160,7 +160,7 @@
           * method is invoked
           * @see #setMonth
           */
      - @Deprecated
      + @Deprecated(since="1.2")
           public int getMonth() {
               throw new java.lang.IllegalArgumentException();
           }
      @@ -173,7 +173,7 @@
           * @exception java.lang.IllegalArgumentException if this
           * method is invoked
           */
      - @Deprecated
      + @Deprecated(since="1.2")
           public int getDay() {
               throw new java.lang.IllegalArgumentException();
           }
      @@ -187,7 +187,7 @@
           * method is invoked
           * @see #setDate
           */
      - @Deprecated
      + @Deprecated(since="1.2")
           public int getDate() {
               throw new java.lang.IllegalArgumentException();
           }
      @@ -201,7 +201,7 @@
           * method is invoked
           * @see #getYear
           */
      - @Deprecated
      + @Deprecated(since="1.2")
           public void setYear(int i) {
               throw new java.lang.IllegalArgumentException();
           }
      @@ -215,7 +215,7 @@
           * method is invoked
           * @see #getMonth
           */
      - @Deprecated
      + @Deprecated(since="1.2")
           public void setMonth(int i) {
               throw new java.lang.IllegalArgumentException();
           }
      @@ -229,7 +229,7 @@
           * method is invoked
           * @see #getDate
           */
      - @Deprecated
      + @Deprecated(since="1.2")
           public void setDate(int i) {
               throw new java.lang.IllegalArgumentException();
           }
      diff -r 77f35eef4ef9 src/java.sql/share/classes/java/sql/Timestamp.java
      --- a/src/java.sql/share/classes/java/sql/Timestamp.java Mon Oct 31 16:41:41 2016 +0800
      +++ b/src/java.sql/share/classes/java/sql/Timestamp.java Tue Nov 01 17:11:23 2016 -0400
      @@ -88,7 +88,7 @@
            * @deprecated instead use the constructor {@code Timestamp(long millis)}
            * @exception IllegalArgumentException if the nano argument is out of bounds
            */
      - @Deprecated
      + @Deprecated(since="1.2")
           public Timestamp(int year, int month, int date,
                            int hour, int minute, int second, int nano) {
               super(year, month, date, hour, minute, second);
      $

      Attachments

        Activity

          People

            lancea Lance Andersen
            lancea Lance Andersen
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: