[sc34wg3] CTM / TMCL Issue: Wildcards - Do we need them?
Graham Moore
gra at networkedplanet.com
Mon May 26 00:51:40 EDT 2008
Yes, I think we can ditch the ? for the []. I'll try it out.
graham
--------------------------------------------
Graham Moore, Director, Networked Planet Limited
Editor XTM 1.0, ISO13250 (TopicMaps) -2,-3, TMCL
e: graham.moore at networkedplanet.com
w: www.networkedplanet.com
t: +44 1865 811131
m: +44 7769658611 (UK)
m: +47 45271713 (Norway)
Networked Planet Limited is registered in England and Wales, no. 5273377
-----Original Message-----
From: sc34wg3-bounces at isotopicmaps.org
[mailto:sc34wg3-bounces at isotopicmaps.org] On Behalf Of Lars Heuer
Sent: 25 May 2008 18:24
To: Discussion of ISO/IEC 13250 Topic Maps
Subject: [sc34wg3] CTM / TMCL Issue: Wildcards - Do we need them?
Hi all, especially TMCL-editors,
The current CTM draft contains *three* mechanisms to create topics
with an automatically generated item identifier.
The anonymous wildcard and the named wildcard were introduced because
TMCL needed them. In Oslo this year we introduced a new notation to
embed topics:
[-"Topic with an autogenerated iid"]
Now, I took a look at the TMCL draft dtd. 2007-12-08 and I wonder if
we need the "?" and "?foo" notation at all; it seems that the []
notation is enough.
A random example from TMCL:
def AssociationTypeConstraint()
?atc1 isa associationtype-constraint
AddConstraintToSchema(?atc1)
end
which can replaced by:
def AssociationTypeConstraint()
AddConstraintToSchema([isa associationtype-constraint])
end
Another example:
def isAbstract($topictype)
?attc1 isa abstract-topictype-constraint
applies-to(*attc1 : constraint-role, $topictype : topictype-role)
AddConstraintToSchema(?attc1)
end
Replacement:
def applies-to($role, $topic)
applies-to(constraint-role: $role, topictype-role: $topic)
end
def isAbstract($topictype)
AddConstraintToSchema([isa abstract-topictype-constraint;
applies-to($topictype)
]
)
end
It seems that every ?foo is replaceable with [] since [] allows a more
complete topic definition.
If ?foo and ? is not needed for TMCL (anymore), I'd be more than happy
if we can remove them from CTM. That would simplify CTM a bit.
Best regards,
Lars
--
Semagia
<http://www.semagia.com>
_______________________________________________
sc34wg3 mailing list
sc34wg3 at isotopicmaps.org
http://www.isotopicmaps.org/mailman/listinfo/sc34wg3
More information about the sc34wg3
mailing list