[XML-DEV Mailing List Archive Home]
[By Thread]
[By Date]
[Recent Entries]
[Reply To This Message]
Re: How can I constrain publicly available schemas?
Hi, Joseph,
Thanks for getting back so quickly. Maybe I should clarify -
The people submitting documents to my system are free to create
documents as they wish so long as they validate against xCIL, so they
can create a document with OrganisationInfo elements but my system can
only deal with documents with PersonInfo elements. As far as my system
is concerned the xCIL schema hasn't constrained the document
sufficiently.
So do I use business logic code to validate against this situation or
do I create a more constrained schema in the same namespace (a scary
thought)?
Cheers,
Fraser
Chiusano Joseph wrote:
<Quote>
for instance one of the immediate children the CustomerDetails element
can be either OrganisationInfo or PersonInfo. My system, however, only
wants to process PersonInfo elements and never OrganisationInfo so, do I
-
</Quote>
According to your explanation, there's no issue because there is a
choice (that is, an xs:choice) in the schema of using OrganisationInfo
or PersonInfo - so if your XML documents always have PersonInfo elements
and never OrganisationInfo elements, they should conform to the schema
in that regard.
Kind Regards,
Joseph Chiusano
Booz Allen Hamilton
Visit us online@ http://www.boozallen.com
-----Original Message-----
From: Fraser Crichton [mailto:fraser.crichton@s...]
Sent: Sunday, April 03, 2005 6:56 PM
To: xml-dev@l...
Subject: How can I constrain publicly available schemas?
Hi,
I'm working on an application where I need to use subsets of
publicly available schemas.
For instance, to model contacts information I'm using xCIL
however xCIL has a very large range of formats, for instance
one of the immediate children the CustomerDetails element can
be either OrganisationInfo or PersonInfo. My system, however,
only wants to process PersonInfo elements and never
OrganisationInfo so, do I -
a) create a more specific schema using the xCIL namespace (!)
(if so, should I then validate it twice - once against xCIL
and then against my more specific schema)
b) XML.com has this article - Designing a New Schema with XML
Design Patterns -
http://www.xml.com/pub/a/2003/06/04/patterns.html - which
would seem to suggest selectively reusing types and global
elements from other namespaces, are there any problems with
this approach?
c) is the schema just a contract and I should use something
else again for validation?
Is this a dumb question or has anybody else come across this
issue and if so how have they approached it?
Cheers,
Fraser
Attention:
This email may contain information intended for the sole use
of the original recipient. Please respect this when sharing
or disclosing this email's contents with any third party. If
you believe you have received this email in error, please
delete it and notify the sender or
postmaster@s... as soon as possible. The
content of this email does not necessarily reflect the views
of SolNet Solutions Ltd.
-----------------------------------------------------------------
The xml-dev list is sponsored by XML.org
http://www.xml.org, an initiative of OASIS
http://www.oasis-open.org
The list archives are at http://lists.xml.org/archives/xml-dev/
To subscribe or unsubscribe from this list use the subscription
manager: http://www.oasis-open.org/mlmanage/index.php
-----------------------------------------------------------------
The xml-dev list is sponsored by XML.org http://www.xml.org, an
initiative of OASIS http://www.oasis-open.org
The list archives are at http://lists.xml.org/archives/xml-dev/
To subscribe or unsubscribe from this list use the subscription
manager: http://www.oasis-open.org/mlmanage/index.php
--
Fraser Crichton
XML Developer
SolNet Solutions Limited
L12, SolNet House, 70 The Terrace
PO Box 397, Wellington, Aotearoa / New Zealand
www.solnetsolutions.co.nz
DDI: 04-462-5078
Mob: 027-278-3392
Fax: 04-462-5011
email: fraser.crichton@s...
Attention:
This email may contain information intended for the sole use of
the original recipient. Please respect this when sharing or
disclosing this email's contents with any third party. If you
believe you have received this email in error, please delete it
and notify the sender or postmaster@s... as
soon as possible. The content of this email does not necessarily
reflect the views of SolNet Solutions Ltd.
|
|
PURCHASE STYLUS STUDIO ONLINE TODAY!
Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!
Download The World's Best XML IDE!
Accelerate XML development with our award-winning XML IDE - Download a free trial today!
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.
|
|