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

Missing @throws in DateTimeFormatterBuilder.appendOffset

    Details

    • Subcomponent:
    • Resolved In Build:
      b50

      Backports

        Description

        The method DateTimeFormatterBuilder.appendOffset(String,String) can throw an exception that is not properly specified. The current spec implies an exception as follows: "The format of the offset is controlled by a pattern which must be one of the following", however there is no @throws clause.

        Fix proposed as follows:

             * @param pattern the pattern to use, not null
             * @param noOffsetText the text to use when the offset is zero, not null
             * @return this, for chaining, not null
             * @throws IllegalArgumentException if the pattern is invalid
             */
            public DateTimeFormatterBuilder appendOffset(String pattern, String noOffsetText) {

        (around line 914)

          Activity

          Hide
          hgupdate HG Updates added a comment -
          URL: http://hg.openjdk.java.net/jdk9/dev/jdk/rev/bd4d6a62e1fd
          User: rriggs
          Date: 2015-01-30 21:17:52 +0000
          Show
          hgupdate HG Updates added a comment - URL: http://hg.openjdk.java.net/jdk9/dev/jdk/rev/bd4d6a62e1fd User: rriggs Date: 2015-01-30 21:17:52 +0000
          Hide
          hgupdate HG Updates added a comment -
          URL: http://hg.openjdk.java.net/jdk9/jdk9/jdk/rev/bd4d6a62e1fd
          User: lana
          Date: 2015-02-11 23:06:32 +0000
          Show
          hgupdate HG Updates added a comment - URL: http://hg.openjdk.java.net/jdk9/jdk9/jdk/rev/bd4d6a62e1fd User: lana Date: 2015-02-11 23:06:32 +0000

            People

            • Assignee:
              rriggs Roger Riggs
              Reporter:
              scolebourne Stephen Colebourne
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: