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

ListResourceBundle.getKeys() enumeration never throws NoSuchElementException

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P4 P4
    • 1.4.0
    • 1.3.0
    • core-libs
    • beta2
    • x86
    • windows_98



      Name: skT45625 Date: 08/09/2000


      java version

      The method getKeys returns an enumeration which
      is declared inline.
      That enumeration nextElement() will return NULL
      when there is no more elements instead of
      throwing a NoSuchElementException.

      How To Fix:
      -1- try/catch NoSuchElementException around nextElement in hasMoreElements()
      -2-just before the return in next element: throw exception if returnval and
      temp are both NULL.
      (Review ID: 108180)
      ======================================================================

            nlindenbsunw Norbert Lindenberg (Inactive)
            skondamasunw Suresh Kondamareddy (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: