[topicmapmail] Any semantic order to repeatable "or" groups of
constructs in XTM?
Kal Ahmed
kal@techquila.com
20 Mar 2003 09:11:50 +0000
Hi Ken,
As you probably guessed, there are two answers to your question about
whether ordering matters to the end user: Yes, and No ;-)
More precisely, if you are building an *XTM* authoring environment, then
I think that you will find that ordering, comments etc. are important. A
user working that closely with the syntax would not expect the
application they are using to rearrange their content or to reorder it -
from their perspective, the XTM syntax is the content, and the
application should not interfere with it. I suspect that if this is the
case, what you really need is an XML editing environment with "topic map
smarts" - perhaps with shortcuts to insert
topicRefs/subjectIndicatorRefs and with tools for validating/presenting
the topic map information separately from the XTM syntax.
If, on the other hand you are building a topic map authoring
environment, the application should keep the author insulated from the
syntax as much as possible. In this case, I think that it is valid for
the authoring tool to deal with the syntax in anyway it sees fit -
including stripping out XML comments. Rather than use XML comments, the
application should make use of topic map constructs to record
notes/comments made by the author. I have started to do this for
documenting the topic map ontologies that I create, and I find it
incredibly useful, because the documentation can be processed by topic
map tools.
Of course, this is not a black-and-white division, there is an area of
grey where it can be argued that some topic map creators might want the
convenience of an authoring environment that hides the syntax along with
the ability to round-trip their XTM syntax files without modification.
In this case, I think that I would tend toward the former approach
rather than the latter.=20
Cheers,
Kal
On Thu, 2003-03-20 at 02:47, G. Ken Holman wrote:
> I wanted to confirm my own understanding that there is no semantic to the=
=20
> ordering of repeatable "or" groups in the XTM document model ... that the=
se=20
> are a mere authoring convenience.
>=20
> There are a number of places in XTM where repeatable "or" groups allow th=
e=20
> authored instance to include constructs in an arbitrary order:
>=20
> ( topic | association | mergeMap )*
> ( topicRef | resourceRef | subjectIndicatorRef )*
> ( baseName | occurrence )*
> ( topicRef | subjectIndicatorRef )*
>=20
> So, the question arises ... would an XTM user ever want the authored=20
> ordering of the repeatable "or" groups preserved? If anyone thinks so,=20
> please speak up.
>=20
> Also, I'm writing some SAX code to read and write XTM, and SAX doesn't gi=
ve=20
> me any comments. I can imagine an XTM author might want comments=20
> preserved, but is this na=C3=AFve?
>=20
> By "preserved" I mean "round-tripping" a topic map expression from XTM in=
to=20
> a topic map engine and back out to XTM again, where the XTM out is as clo=
se=20
> as possible syntactically (group order, comments, etc.) to what went in=20
> (the semantics of the underlying topic map expressed by the XTM would=20
> assumedly be preserved).
>=20
> Since the "best" way to look at a topic map is *always* through a topic m=
ap=20
> engine and *not* through XTM syntax, is it such a crime to not preserve=20
> group order, top-level construct order or authored comments found in an X=
TM=20
> file? I hope I can ignore these with impunity.
>=20
> I would appreciate anyone expressing their opinion on my assumptions.
>=20
> Thanks!
>=20
> ................. Ken
>=20
> --
> Upcoming hands-on in-depth XSLT/XPath and/or XSL-FO
> North America: June 16-20, 2003
>=20
> G. Ken Holman mailto:gkholman@CraneSoftwrights.com
> Crane Softwrights Ltd. http://www.CraneSoftwrights.com/t/
> Box 266, Kars, Ontario CANADA K0A-2E0 +1(613)489-0999 (F:-0995)
> ISBN 0-13-065196-6 Definitive XSLT and XPath
> ISBN 0-13-140374-5 Definitive XSL-FO
> ISBN 1-894049-08-X Practical Transformation Using XSLT and XPath
> ISBN 1-894049-10-1 Practical Formatting Using XSL-FO
> Male Breast Cancer Awareness http://www.CraneSoftwrights.com/t/bc
>=20
> _______________________________________________
> topicmapmail mailing list
> topicmapmail@infoloom.com
> http://www.infoloom.com/mailman/listinfo/topicmapmail
>=20