[tmcl-wg] Topic Map Constraint Language and Schematron
Nikita Ogievetsky
tmcl-wg@isotopicmaps.org
Mon, 12 May 2003 14:41:18 -0800
I think that the Concurrent Characteristics Expressions that we have
presented at XML Europe 2003 is very close to the Schematron in spirit
as I am using them to build validating stylesheets.
If time permits I will release descriptions and tools pretty soon.
Lars Marius Garshol:
> * Rick Jelliffe
> |
> | WG members may be interested in a possible tie-in between Schematron
> | and TMCL.
>
> Indeed, we are. The idea of making TMCL into a simple set of
> (selector, restriction) pairs, where both selector and restriction are
> queries in some topic map query language, has been floating in the
> topic map community for quite a while now, clearly inspired by the
> Schematron. (Not sure who spoke of it first. Quite likely many people
> thought of it independently after the Schematron was published.)
>
> I think the idea is elegant, but I worry that if TMCL is made into a
> simple TMQL "client" in this way we may find that our ability to
> introspect schemas is limited by this approach. (I've discussed this
> with Robert, who does not appear to agree, several times without
> really reaching any conclusion.)
>
> In the same vein I wonder whether you've found that writing a complete
> schema for some vocabulary in this fashion is feasible? To me it seems
> that it may be difficult to cover all corner cases and really describe
> the vocabulary fully with this approach. (I do agree that it is very
> good for expressing the more complicated constraints.)
>
> My feeling so far has been that we would probably be best off if we
> could provide a combination of some more declarative/implicit language
> (like OSL[1] in general approach, if not necessarily in detail). To
> this end I put together a trivial proposal for extending OSL with such
> a capability. Basically the <topic> element would have had two
> additional element(s)
>
> <assert>
> <constraint>...tolog query here...</constraint>
> <message>...error message here...</message>
> </assert>
>
> and a similar <deny> where the former would require at least one match
> to the query and the latter none. These constraints would implicitly
> apply to all topics of the defined class. (One might perhaps also
> allow these elements to appear within the <schema> top-level element.)
>
> That was basically a dump of the contents of my brain relating to this
> subject. Would be interested to hear what anyone thinks of it. :)
Hmmm... error message templates perhaps?
Interesting idea,... but I am not sure that TMCL should be into formatting.
--Nikita.