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

Code extract for java.text.MessageFormat, form.ApplyPattern() is incorrect.

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P4 P4
    • 1.4.0
    • 1.2.0
    • docs
    • beta
    • generic
    • generic



      Name: rm29839 Date: 05/21/98


      The example shown in java.text.MessageFormat
      for applyPattern using a ChoiceFormat is incorrect
      and generates an exception.

      It currently shows form.applyPattern(
      "There are {0,choice,0#are no files|1#is one file|1#are {0,number,integer} files}.");

      It should read:
      "There are {0,choice,0#are no files|1#is one file|1<are {0,number,integer} files}.");

      http://java.sun.com:80/products/jdk/1.2/docs/api/java.text.MessageFormat.html
      (Review ID: 28817)
      ======================================================================

            jhosunw Jamie Ho (Inactive)
            rmandelsunw Ronan Mandel (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: