[ 
http://issues.apache.org/jira/browse/TUSCANY-547?page=comments#action_12422591 
] 
            
Geoff Winn commented on TUSCANY-547:
------------------------------------

I'm looking into this.

> Discriminated types
> -------------------
>
>                 Key: TUSCANY-547
>                 URL: http://issues.apache.org/jira/browse/TUSCANY-547
>             Project: Tuscany
>          Issue Type: Improvement
>          Components: C++ SDO
>         Environment: all
>            Reporter: Ed Slattery
>
> There are macros in the SDO code in data object, and lists/sequences to 
> handle the many get/set/add/insert APIS for each type if data object. These 
> are a pain to debug, and the conversion routines in TypeImpl are necessarity 
> duplicased for each type of data object.
> One suggested approach which appeals would be to define a content holder 
> class, which would hold the value of any type of data object. By allowing it 
> to be constructed from any incoming type, we could reduce the get/set methods 
> to  oneline methods which set up this generic blob, flag its original type, 
> and pass it on to a generic setter/getter.
> Similarly the conversion routines could query the current type of the blob, 
> and perform the correct conversion for the blob to the requested type.
> This would reduce the codebase, make it cleaner.
> Also, we dont deal with XSD Unions at present, but having this blob in place, 
> we could extend the flag saying what type it is, to be perhaps a bitmask 
> saying what types if could be, and what type it is currently - this would 
> make unions supportable.

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

        

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to