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

spec: getObjectClass description is self contradictory

XMLWordPrintable

    • beta2
    • generic
    • generic



      Name: dkR10031 Date: 04/12/2001


      Specification of the method
      javax.imageio.metadata.IIOMetadataFormatImpl.getObjectClass says:

      "Returns the Class type of the Object reference stored within the element.
      If null, this element may not contain an Object reference. ...
      Returns:
               a Class object, or null."

      The same description states:

      "Throws: ...
          IllegalArgumentException - if the named element cannot contain an object
          value (i.e., if getObjectValueType(elementName) == VALUE_NONE).

      These two statements contradict each other.
      Note that implementation (JDK 1.4.0beta, build b59) of the method does
      throw the exception.

      This bug affects new JCK test:
      api/javax_imageio/metadata/IIOMetadataFormatImpl/index.html#getObjectClass


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

            dricesunw Daniel Rice (Inactive)
            dimasunw Dima Dima (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: