harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alexei Zakharov (JIRA)" <j...@apache.org>
Subject [jira] Updated: (HARMONY-5675) [classlib][beans] Introspector unable to determine set method correctly
Date Wed, 09 Apr 2008 16:43:25 GMT

     [ https://issues.apache.org/jira/browse/HARMONY-5675?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Alexei Zakharov updated HARMONY-5675:
-------------------------------------

    Attachment: H5675-StandardBeanInfo.patch

Patch for the class library code. Please note that I had to refactor several methods of StandardBeanInfo
in order to cover all cases from IntrospectorTest.test5675() . The patch is only 19Kb, 25kb
was the size of cumulative patch - classlib + test. :)

After applying this patch you may encounter several failures in java.beans.PersistentDelegateTest.
IMO my patch is not the real reason of these failures. It just triggers some new execution
paths that were hidden before. I've filed a new JIRA about this - please see HARMONY-5707.

> [classlib][beans] Introspector unable to determine set method correctly
> -----------------------------------------------------------------------
>
>                 Key: HARMONY-5675
>                 URL: https://issues.apache.org/jira/browse/HARMONY-5675
>             Project: Harmony
>          Issue Type: Sub-task
>          Components: App-Oriented Bug Reports, Classlib
>         Environment: Debian Linux 32
>            Reporter: Alexei Zakharov
>            Assignee: Alexei Zakharov
>         Attachments: H5675-IntrospectorTest.patch, H5675-StandardBeanInfo.patch, Harmony-5675.diff
>
>
> In some tricky situations java.beans.Introspector is unable to determine bean's set method
correctly. Please see the test case below.
> IntrospectorTest.java
> --- 
> import java.beans.*;
> import java.io.*;
> public class IntrospectorTest {
>     public static void main(String argv[]) throws Exception {
>         BeanInfo bInfo = Introspector.getBeanInfo(TstBean.class);
>         int n = 0;
>         for (PropertyDescriptor desc: bInfo.getPropertyDescriptors()) {
>             System.out.println(" " + desc.getName() + " " +
>                     desc.getReadMethod() + " " +
>                     desc.getWriteMethod());
>             n++;
>         }
>         System.out.println("TOTAL: " + n + " properties");
>     }
> }
> class TstBean {
>     public void setProp1(String uri)
>     {
>     }
>     public void setProp1(Integer i)
>     {
>     }
>     public Integer getProp1()
>     {
>         return null;
>     }
> }
> This issue prevents Confluence from loading successfully on Harmony.

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


Mime
View raw message