You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tuscany.apache.org by "Cezary Tkaczyk (JIRA)" <tu...@ws.apache.org> on 2007/10/24 22:53:50 UTC

[jira] Closed: (TUSCANY-1853) XSD2JavaGenerator generates Java identifier with dots

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

Cezary Tkaczyk closed TUSCANY-1853.
-----------------------------------

       Resolution: Fixed
    Fix Version/s: Java-SDO-Next

The snapshot version works fine. Sorry, I haven't checked it out, before creating a bug. I had trouble building a snapshot - sdo-tools tests failure. Omission of these tests leads to successful build.

> XSD2JavaGenerator generates Java identifier with dots
> -----------------------------------------------------
>
>                 Key: TUSCANY-1853
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-1853
>             Project: Tuscany
>          Issue Type: Bug
>          Components: Java SDO Tools
>    Affects Versions: Java-SDO-1.0
>         Environment: Windows XP, jre 1.5
>            Reporter: Cezary Tkaczyk
>             Fix For: Java-SDO-Next
>
>
> Hello,
> While I'm trying to compile generated by XSD2JavaGenerator Java classes, I've got such an error:
>     
>     [javac] C:\projekty\eclipse-workspace-rbpl-sdo-1.0\REB-Catalog-SDO-Java\src-autogen\pl\esb\impl\EsbFactoryImpl.java:169: ';' expected
>     [javac]     pl.esb.blm.adapter.AdapterFactory pl.esb.blm.adapter.AdapterFactoryInstance = pl.esb.blm.adapter.AdapterFactory.INSTANCE;
>     [javac]                                                    ^
>  
> The problem is: variable identifier cannot contain dots.
> The place, where this error appears looks like this:
> public static EsbFactoryImpl init()
>   {
>     if (instance != null ) return instance;
>     instance = new EsbFactoryImpl();
>     // Initialize dependent packages
>     AdapterFactory AdapterFactoryInstance = AdapterFactory.INSTANCE;
>     RebFactory RebFactoryInstance = RebFactory.INSTANCE;
>     pl.raiffeisen.esb.blm.adapter.AdapterFactory pl.raiffeisen.esb.blm.adapter.AdapterFactoryInstance = pl.raiffeisen.esb.blm.adapter.AdapterFactory.INSTANCE;
>     
>     // Create package meta-data objects
>     instance.createMetaData();
>     // Initialize created meta-data
>     instance.initializeMetaData();
>     
>     // Mark meta-data to indicate it can't be changed
>     //theEsbFactoryImpl.freeze(); //FB do we need to freeze / should we freeze ????
>     return instance;
>   }
> I think the problem is that I have two namespaces of the same suffix:
> http://www.esb.pl/blm/adapter
> http://www.esb.pl/ods1/adapter
> So, generator is trying to avoid the problem creating unique variable name: pl.esb.blm.adapter.AdapterFactoryInstance
> Unfortunately, this is not valid identifier.
> Kind Regards,
> Czarek

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


---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-dev-help@ws.apache.org