harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sebb (JIRA)" <j...@apache.org>
Subject [jira] Created: (HARMONY-6422) StandardBeanInfo behaves differently from RI GenericBeanInfo
Date Mon, 18 Jan 2010 19:38:54 GMT
StandardBeanInfo behaves differently from RI GenericBeanInfo

                 Key: HARMONY-6422
                 URL: https://issues.apache.org/jira/browse/HARMONY-6422
             Project: Harmony
          Issue Type: Bug
          Components: Classlib
            Reporter: Sebb

StandardBeanInfo behaves differently from RI GenericBeanInfo:

-----cut here-------
import java.beans.BeanInfo;
import java.beans.Introspector;
public class BeanTest {
    public static void main(String[] args) throws Exception {
         BeanInfo beanInfo = Introspector.getBeanInfo(BeanTest.class);
         System.out.println(beanInfo.getClass().getName()); // RI=GenericBeanInfo, Harmony=StandardBeanInfo
         System.out.println(beanInfo.getBeanDescriptor().getDisplayName()); // BeanTest (both)
         System.out.println(beanInfo.getBeanDescriptor().getDisplayName());// test (RI) BeanTest
-----cut here-------

This is because the RI always returns the same instance from getBeanDescriptor() whereas Harmony
returns a new instance.

I don't know if this is a spec. violation or not, but the behaviour is different and unexpected,
so should at least be documented in the BeanInfo Javadoc.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message