[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: DTD vs Schema

  • From: "AMER, Nidal" <Nidal.AMER@h...>
  • To: "'Peter Murray-Rust'" <peter@u...>
  • Date: Fri, 11 Sep 1998 15:19:23 +0200

dtd vs. schemas
In fact I am trying to implement in XML an object model I have designed
with UML in which I clearly define generalization and specialization
relationships. In instance, I am treating a generic type called
transaction from which I derive different types of transactions all of
which share a common behavior. 
The XML Data schema uses SUPERTYPE to declare inheritance, even if this
is not very useful unless the DOM model, built by the parser, could
recognize that an element inherits another one and lets the application
treat the subtype the same way as the supertype ( polymorphism ). Also,
when referenced, the subtype should be checked against applying the
validity constraints of the supertype plus its own constraints.

Unfortunately, as this seems not to be implemented, I have to build this
logic in the code.

Regards,
Nidal.

	-----Original Message-----
	From:	Peter Murray-Rust [SMTP:peter@u...]
	Sent:	Friday, September 11, 1998 2:21 PM
	To:	AMER, Nidal
	Subject:	Re: DTD vs Schema

	At 12:44 11/09/98 +0200, you wrote:
	>Thank you all a lot for your answers. I am a step further now.
	>Just I still can't express inheritance with DTD in an elegant
way.

	No - it's not easily built in to XML. I think that we shall
develop some
	general means for doing this. It depends *what* your want to
inherit.

	I have developed this in my Chemical Markup Language,
	http://www.xml-cml.org (BTW I used to work in the pharma
industry). I have
	an array element which can be subclassed to atomArray and
bondArray (and
	all of these are mapped to Java). But there is no way of
*enforcing* the
	parallel between XML and Java here - I have to remember it when
I write the
	code.

	I think DCD and other schemas will start addressing this.

		P.

	>~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
	>Nidal AMER
	>Deputy R & D Director
	>Health Data Management Partners (HDMP)
	>A SmithKline-Beecham Company
	>6 Rue de Genève,
	>1140 Brussels, Belgium
	>Tel: + 32 (2) 724 00 93
	>Fax: + 32 (2) 726 91 59
	>E-mail: nidal.amer@h... <mailto:nidal.amer@h...> 
	>Visit our web site: http://www.hdmp.com <http://www.hdmp.com> 
	>~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
	>
	Peter Murray-Rust, Director Virtual School of Molecular
Sciences, domestic
	net connection
	VSMS http://www.nottingham.ac.uk/vsms, Virtual Hyperglossary
	http://www.venus.co.uk/vhg

xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev@i...
Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/
To (un)subscribe, mailto:majordomo@i... the following message;
(un)subscribe xml-dev
To subscribe to the digests, mailto:majordomo@i... the following message;
subscribe xml-dev-digest
List coordinator, Henry Rzepa (mailto:rzepa@i...)


PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.