Hi,

As Rhett said, the way to go is to file an enhancement request. Please
note that the feature you are requesting is currently under development
via the Binding File.
Indeed you will have the ability to choose the name of java members
generated for enumeration values.

Arnaud



This message is intended only for the use of the Addressee and may
contain information that is PRIVILEGED and CONFIDENTIAL. If you are not
the intended recipient, dissemination of this communication is
prohibited. If you have received this communication in error, please
erase all copies of the message and its attachments and notify us
immediately.



> -----Original Message-----
> From: Rhett Sutphin [mailto:[EMAIL PROTECTED] 
> Sent: Monday, January 12, 2004 10:16 PM
> To: [EMAIL PROTECTED]
> Subject: Re: [castor-dev] Re: Enumerated Types and Underscore 
> Character
> 
> 
> Hi Robert,
> 
> Two things:
> 
> 1) I think the INTEGER case is already handled -- if the 
> value parses to an int, the enumerated value will be VALUE_{int}.
> 
> 2) An enhancement request would be the right way to go.  
> Allow me to suggest, though, that you do it yourself and 
> contribute the code back.  If you look at the method added by 
> the patch in bug 1245 (translateEnumValueToIdentifier), it 
> should be easy to add your check for a float and handle it 
> appropriately.
> 
> Rhett
> 
> [EMAIL PROTECTED] wrote:
> > Just a follow up msg to let everyone know that I resolved this 
> > problem.  It turns out that the underscores was not the problem (at 
> > least with the CVS version of Castor - it may still be a 
> problem with 
> > the 0.9.5.2 release though)  It was a problem with hyphens 
> and numbers 
> > in the enums in my schema.  Hyphens are clearly invalid so 
> I changed 
> > the hypens to underscores and that works fine.
> > 
> > However, it would be nice if Castor created more readable 
> enumerations 
> > for integers and decimal numbers.
> > 
> > e.g.
> > 
> > <xsd:simpleType name="dpiType">
> >    <xsd:restriction base="xsd:string">
> >       <xsd:enumeration value="300"/>
> >       <xsd:enumeration value="600"/>
> >       <xsd:enumeration value="1200"/>
> >    </xsd:restriction>      
> > </xsd:simpleType>
> > 
> > could generate ---> INTEGER_600, INTEGER_1200
> > 
> > <xsd:simpleType name="exchangeRateType">
> >    <xsd:restriction base="xsd:string">
> >       <xsd:enumeration value="1.56"/>
> >       <xsd:enumeration value="1.89"/>
> >    </xsd:restriction>     
> > </xsd:simpleType>
> > 
> > could generate ---> DECIMAL_1_56, DECIMAL_1_89
> > 
> > The prefixes can be different but I think this is much more 
> readable 
> > than VALUE_0, VALUE_1, etc...
> > 
> > Should I add an enhancement request in BugZilla>
> > 
> > -----------------------------------------------------------
> > If you wish to unsubscribe from this mailing, send mail to
> > [EMAIL PROTECTED] with a subject of:
> >         unsubscribe castor-dev
> > 
> 
> ----------------------------------------------------------- 
> If you wish to unsubscribe from this mailing, send mail to
> [EMAIL PROTECTED] with a subject of:
>         unsubscribe castor-dev
> 

----------------------------------------------------------- 
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
        unsubscribe castor-dev

Reply via email to