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

sun.beans.editors package do not conform to the Beans PropertyEditor naming con

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P3
    • Resolution: Not an Issue
    • Affects Version/s: 1.1.3
    • Fix Version/s: None
    • Component/s: client-libs
    • Subcomponent:
    • CPU:
      generic
    • OS:
      generic

      Description

      Since the Integer and Boolean property editors (IntEditor and
      BoolEditor) provided in the sun.beans.editors package do not conform
      to the Beans PropertyEditor naming convention, the
      PropertyEditorManager should register them using both .TYPE and
      .CLASS. Right now, it only uses .TYPE, and findEditor class for
      java.lang.Integer.class and java.lang.Boolean.class return null. See
      output from program below...

      Scott

      D:\java_bugs\six>type Bug.java

      import java.beans.*;

      public class Bug
      {
              public static void main(String[] args)
              {
                      PropertyEditor pe;
                      pe =
      PropertyEditorManager.findEditor(java.lang.Integer.class);
                      System.out.println( "Integer.class: " + pe );
                      pe = PropertyEditorManager.findEditor(
      java.lang.Integer.TYPE );

                      System.out.println( "Integer.TYPE: " + pe );
                      pe = PropertyEditorManager.findEditor(
      java.lang.Float.class );
                      System.out.println( "Float.class: " + pe );
                      pe = PropertyEditorManager.findEditor(
      java.lang.Float.TYPE );
                      System.out.println( "Float.TYPE: " + pe );
              }
      }

      Here's the output :

      D:\java_bugs\six>java Bug
      Symantec Java! JustInTime Compiler Version 210.046 for JDK 1.1.2
      Copyright (C) 1996-97 Symantec Corporation
      Integer.class: null
      Integer.TYPE: sun.beans.editors.IntEditor@1ec7e1
      Float.class: sun.beans.editors.FloatEditor@1ec803
      Float.TYPE: sun.beans.editors.FloatEditor@1ec813

        Attachments

          Activity

            People

            Assignee:
            ghamiltosunw Graham Hamilton (Inactive)
            Reporter:
            mmma Marvin Ma (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: