[Date Prev]
| [Thread Prev]
| [Thread Next]
| [Date Next]
--
[Date Index]
| [Thread Index]
Re: [xml-dev] Quiz: what's the value space of the <Publisher> element?
- From: Frank Manola <fmanola@acm.org>
- To: "Costello, Roger L." <costello@mitre.org>
- Date: Mon, 22 Jun 2009 12:09:06 -0400
Roger--
Your claim seems to be along the lines of "the sky is falling". Just
because the legal values can't be determined "in isolation" doesn't
make instance-document-generator tools "impossible", or even
"extraordinarily difficult". It just means the tools may to look at
more of the schema. If what you say were true, it would be impossible
to use "assert" to enforce constraints at all, since one (inefficient)
way of implementing your instance-document-generator tool would be to
implement a tool that generated instances using the element
declarations in isolation, and then run the resulting instances
through an "assert-constraint-checker" and throw out the bad ones. If
such a constraint-checker can't be built, "assert" hasn't been
specified properly.
--Frank
On Jun 22, 2009, at 11:47 AM, Costello, Roger L. wrote:
> SO WHAT?
>
> What this means is that an element declaration cannot be understood
> on its own, in isolation.
>
> To understand an element you must understand all possible ancestors
> of the element.
>
> Want to create a tool that automatically generates sample instance
> values for each element declared in the schema? That's relatively
> straightforward in XML Schema 1.0 because you can understand each
> element declaration in isolation. In XML Schema 1.1, as the above
> example illustrates, an element's value cannot be determined in
> isolation. So, instance-document-generator tools become impossible.
> (If not impossible, it will certainly be extraordinarily difficult)
>
> Want to create a tool that does automated analysis of element
> declarations? That's intractable. (If not intractable, it will
> certainly be extraordinarily difficult)
>
>
> Comments?
>
> /Roge
[Date Prev]
| [Thread Prev]
| [Thread Next]
| [Date Next]
--
[Date Index]
| [Thread Index]