[jira] Created: (MODELLO-208) class cast assertion to wrong type in one multiplicity association setter when using java.useInterface

View: New views
2 Messages — Rating Filter:   Alert me  

[jira] Created: (MODELLO-208) class cast assertion to wrong type in one multiplicity association setter when using java.useInterface

by JIRA jira@codehaus.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

class cast assertion to wrong type in one multiplicity association setter when using java.useInterface
------------------------------------------------------------------------------------------------------

                 Key: MODELLO-208
                 URL: http://jira.codehaus.org/browse/MODELLO-208
             Project: Modello
          Issue Type: Bug
          Components: modello-plugin-java
    Affects Versions: 1.0.2
            Reporter: Herve Boutemy


features.mdo generates following code in JavaFeatures.java
{code:java}    public void setUseInterface( BaseClass useInterface )
{
    if ( !( useInterface instanceof BaseClass ) )
    {
        throw new ClassCastException( "JavaFeatures.setUseInterface(useInterface) parameter must be instanceof " + BaseClass.class.getName() );
    }
    this.useInterface = (SubClassLevel1) useInterface;
} //-- void setUseInterface( BaseClass )
{code}
Should not generate an instanceof check against BaseClass but against SubClassLevel1

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email



[jira] Closed: (MODELLO-208) class cast assertion to wrong type in one multiplicity association setter when using java.useInterface

by JIRA jira@codehaus.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


     [ http://jira.codehaus.org/browse/MODELLO-208?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Herve Boutemy closed MODELLO-208.
---------------------------------

         Assignee: Herve Boutemy
       Resolution: Fixed
    Fix Version/s: 1.1

fixed in r1279

> class cast assertion to wrong type in one multiplicity association setter when using java.useInterface
> ------------------------------------------------------------------------------------------------------
>
>                 Key: MODELLO-208
>                 URL: http://jira.codehaus.org/browse/MODELLO-208
>             Project: Modello
>          Issue Type: Bug
>          Components: modello-plugin-java
>    Affects Versions: 1.0.2
>            Reporter: Herve Boutemy
>            Assignee: Herve Boutemy
>             Fix For: 1.1
>
>
> features.mdo generates following code in JavaFeatures.java
> {code:java}    public void setUseInterface( BaseClass useInterface )
> {
>     if ( !( useInterface instanceof BaseClass ) )
>     {
>         throw new ClassCastException( "JavaFeatures.setUseInterface(useInterface) parameter must be instanceof " + BaseClass.class.getName() );
>     }
>     this.useInterface = (SubClassLevel1) useInterface;
> } //-- void setUseInterface( BaseClass )
> {code}
> Should not generate an instanceof check against BaseClass but against SubClassLevel1

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email