[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: Re: [ubl] Global vs. Local -- Gunther's Recommendation
The focus of this discussion on OO vs XSD is too limited a view on this question. My preference for local elements in XSD is based on a broader concern for component-based design, reuse, and system integration. As many of you know, I prefer UML as an approach for schema design, but not because UML is based on object-oriented principles: I see UML as the best current approach to facilitate system integation across our many technology silos. (As Dan Vint pointed out, it's not the ultimate univeral language, but I don't expect to see a perfect modeling language in my lifetime.) This was exactly the topic of my plenary presentation at XML 2001. It was about UML, but not necessarily about OO development. Those powerpoint slides are available here: http://xmlmodeling.com/presentations/XML2001.ppt And the paper is available here, titled "Integrating XML and non-XML data with UML": http://xmlmodeling.com/articles/IntegratingXMLData.pdf This was written in Sept 2001 so refers to an xCBL SOX schema instead of XSD, but the ideas still apply now. Slides 3 and 4 of the presentation illustrate a subset of the technology silos that concern me. We could add many more. For system integration, we often need to transform BI-directionally between these silos. In addition to mapping between implementation languages, it would be better to capture the common information model and components in a way that facilitates a shared view of analysis and design. This is how I use UML. I believe that the ebXML Core Components Spec shares the same general vision for implementation-independent analysis and component repository. I am exploring three alternative approaches for robust bi-directional mapping between XSD with global elements and UML information models. The goal is to achieve complete round-trip design. With the current UBL 0p70 schemas, I am able to transform XSD -> UML -> XSD, with the resulting schemas equivalent to the original, including use of global elements. Gunther mentioned the use of "pseudo-classes" in the UML model to represent global elements. This is one of my three approaches to mapping, but I reject it as unusable because the resulting class diagrams no longer illustrate "good" conceptual models of the information. A pseudo-class provides an explicit representation of the global element as a "first class citizen" in the model, typically using a UML realization link to the class that defines its type. This makes the model and diagrams tightly bound to XSD syntax and reduces reuse for mapping to other implementations. The other approaches to mapping require additional metadata captured in the model to support global elements (e.g. tagged values and dependency links). Although this works, it increases the burden on model design and maintenance. It will also complicate use of this model for mapping to and from other implementations (e.g. RDBMS, Java, C++, etc.). The most difficult problem is with mapping (in UML) a global element to the namespace in which it is declared. The global element may be declared in a different schema module, and possibly a different XML namespace, than the complexType or simpleType on which it is based. Some XML Schemas (e.g. ACORD) use one very large schema file in one namespace; global elements are quite straightforward here. Other schemas (e.g. OAGIS 8.0 and 8.1) use a very large number of schema modules to support reuse and abstraction, which greatly complicates mapping global elements to schema modules and namespaces. UML has not yet settled on a rule for determining schema document modularity and their namespace assignment. See my related posting to this thread a few days ago: http://lists.oasis-open.org/archives/ubl/200302/msg00028.html My interest in NDR recommendations is more general than UBL. I'm looking for a set of industry best practices. I am still testing alternative approaches to support global element mapping to UML and expect to find a workable solution, but use of local elements (or restricted use of global elements in some situations) simplifies the mapping and will reduce long-term maintenance of UML models used for system integration. Best Regards, Dave Carlson http://XMLmodeling.com ---------------------------------------------------------------- To subscribe or unsubscribe from this elist use the subscription manager: <http://lists.oasis-open.org/ob/adm.pl>
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]