harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mikhail Markov (JIRA)" <j...@apache.org>
Subject [jira] Updated: (HARMONY-4033) [classlib][beans] A listener created by means of EventHandler.create() does not work
Date Thu, 21 Jun 2007 12:23:26 GMT

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

Mikhail Markov updated HARMONY-4033:
------------------------------------

    Attachment: H-4033.patch

Here is the patch fixing the problem + regression test.

Fix description: when listener's method with 1 parameter is called, eventPropertyName could
possibly be null and this is valid call (sending null event).

> [classlib][beans] A listener created by means of EventHandler.create() does not work
> ------------------------------------------------------------------------------------
>
>                 Key: HARMONY-4033
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4033
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Roman S. Bushmanov
>         Attachments: H-4033.patch, test.zip
>
>
> A listener created by
> EventHandler.create(FredListener.class, target, "methodWithoutParam", null, "fireFredEvent")
> doesn't call target.methodWithoutParam() method when its fireFredEvent(event) method
is called.
> To reproduce the issue please run the attached test.
> The expected output is "OK". 
> Harmony throws the following exception instead.
> java.lang.reflect.InvocationTargetException
>         at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)
>         at java.lang.reflect.Method.invoke(Method.java:382)
>         at Test.main(Test.java:11)
> Caused by: java.lang.IllegalArgumentException: Invalid method call
>         at java.beans.EventHandler.invoke(EventHandler.java:96)
>         at $Proxy0.fireFredEvent(Unknown Source)
>         at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)
>         ... 2 more
> Affected tests:
> functional/org/apache/harmony/test/func/api/java/beans/eventhandler/ImplementationOnlyOneMethodFalse.xml
> functional/org/apache/harmony/test/func/api/java/beans/eventhandler/ImplementationOnlyOneMethodTrue.xml
> (see HARMONY-3528)

-- 
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