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

Re: What is Tag Soup?


grammar based tagging

> >>>From: "Sean McGrath" <sean.mcgrath@p...>
> >>> Schemas have entropy - a tendancy towards disorder - disorder the grows
> >>> over time as the schema is modified....

> >>[Rick Jelliffe]
> >>I wonder how much is this actually a problem with
>
> >>1) Using content models, rather than systems that allow partial orderings
> >>to be declared (i.e.,  "bib should come before bub and to hell wit the 
> rest")?

[Michael Sperberq-McQueen]
 >I'm confused here: you seem to be saying that you don't think
 >content models, or more generally formal grammars as defined by
 >Chomsky, can express the constraint "bib should come before bub
 >and anything else can occur in any order".  Surely you can't
 >believe that.

Here is what happens in my experience:

Constraint: "bib must occur before bub and then anything can occur in any 
order"

Developer: "This is manageable in a number of grammar based schema languages.
For example,...yada, yada..."

Time moves on, the constraint changes:

Constraint: "bib must occur before bub and then anything can occur in any 
order unless there
if a bab in there somewhere."

Developer: "Oh dear. If it can be done at all, it will make the model a lot 
more complex....
How about this? "(bib|bub|...)*"

Simply put, my experience has been that as soon as grammar based 
constraints start to
stretch a grammar based schema language, the content models embark on a 
slippery slope towards
"everything optional, anything in any order" In SGML, advanced cases of 
this phenomenon
took the form

<!ELEMENT foo (A|B|C...)* + (i1,i2,i3...)>

(Note to non-SGML people: the weird bit on the end is called "inclusion 
exceptions". Buy an
old-timer a beer for more details:-)

In XML DTDs, its a bit simpler but still pretty horrid:
<!ELEMENT foo (A|B|C...)*>

I think this is one of the reasons why WF XML ended up fitting some SGML 
systems
in industry quite well. Over time, the schemas had become less and less potent
anyway to the point what all they were really doing was checking that all
elements used were declared in the "tag bag" DTD :-/

I think Rick's thinking (and I agree with it) is that rule based validation 
constraints
that concentrate on constraining aspects of the structure rather than the
whole structure, do not "degrade" as extra constraints need to be added
into the validation.

The theoretical expressibility of constraints in either grammer or rule
based systems in not the central concern here. The concern is how
robust the two approaches are in the face of (inevitable) real world
change.

Sean




http://seanmcgrath.blogspot.com



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.