Luigi Paioro <[EMAIL PROTECTED]> writes:

> 
> Dear Dave and all,
> 
> I have a peculiar use-case I would like to explain you in order to 
> suggest a possible improvement of generateDS (that would be very useful 
> to me).
> 
> In attachment you find an XSD schema (package.xsd), an example of XML 
> instance (skycat_example.xml), an originally generateDS generated file 
> (orig.package.py) and the same file modified by me (package.py).
> 
> Well, as you can easily see, in skycat_example.xml there is an element 
> named <parameter> that has got the special attribute xsi:type="uri". 
> This because <parameter> is of parameterType type which is an abstract 
> type with many different implementations like, for instance, <uri> (in 
> this case).
> 
> When generateDS creates the data structure for <parameter> element, it 
> is not able to recognize its type (I guess), and then treats it as a 
> string, failing to create a suitable class structure.
> 
> So, what basically I did was to modify the parameter.build method like this:

Luigi -

Wow.  I had no idea that you could specify the type of an element in an instance
document.  Have I got that right?

Thanks for pointing this out.  And, thanks for your guidances on a solution to
this problem.

Give me a day or two to look into it.

- Dave







-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
generateds-users mailing list
generateds-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/generateds-users

Reply via email to