[ http://issues.apache.org/jira/browse/TUSCANY-546?page=all ]

Geoff Winn updated TUSCANY-546:
-------------------------------

    Attachment: TUSCANY-546.patch

I've implemented one option for making the type system more flexible and the 
changes are attached as a patch.

Built and tested on XP with VC7.1 and RHEL3.

This version allows brand new types to be added after a data object has been 
created, however existing types cannot be modified. An attempt to create a 
duplicate type is treated in the same way as it was previously.

> Flexible Type System
> --------------------
>
>                 Key: TUSCANY-546
>                 URL: http://issues.apache.org/jira/browse/TUSCANY-546
>             Project: Tuscany
>          Issue Type: Improvement
>          Components: C++ SDO
>    Affects Versions: Cpp-current
>         Environment: all
>            Reporter: Ed Slattery
>         Assigned To: Geoff Winn
>             Fix For: Cpp-current
>
>         Attachments: TUSCANY-546.patch
>
>
> The SDO type system may be added to by loading a schema, or by using the data 
> factory addType/addPropertyToType apis. When  the first data object is 
> created, the type system is frozen and the properties of parent types are 
> transferred to child types - the system is 'resolved'.
> There is a requirement being proposed that we should be able to unfreeze the 
> system, and add new types after the first data object creation, as long as 
> the new ones dont cause the old model to be modified. 
> This has substantial knock on effects, and would need to be designed 
> carefully.
> Ths issues to consider:
> 1) A type is loaded which is already in the system - throw, or warn, or 
> silently ignore?
> 2) Attempt to add a property to an existing type - throw or ignore?
> 3) When  moving data objects from one factory to another - the compatibility 
> of type systems is tested - would need to narrow this to validation only of 
> the types actually being copied at the time.
> The suggestion is that the sensible place to add this is in AddType, which 
> could, after resolve, simply still work, but add types not to the type 
> system, but to a resolver cache. At any object instantiation, if the resolver 
> cache is not empty, then a new resolve of only the new types is performed. 
> Duplicate types are silently ignored.

-- 
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