Re: TMQL: Direct (super|sub)types?

"Andrew S. Townley" <[email protected]>
Newsgroups gmane.text.xml.xtm.general
Message-ID <[email protected]>
Something along these lines would get my vote, and I think it would result in fewer surprises as to the results returned by people used to more traditional type systems.

On 2 Mar 2011, at 09:29 p.m., Patrick Durusau <patrick-Q/[email protected]> wrote:

> Lars,
> 
> On 3/2/2011 7:32 AM, Lars Marius Garshol wrote:
>> * Lars Heuer
>>> Even if I try to restrain me: What are *direct* supertypes/subtypes?
> 
> I assume from what has been said that an "indirect" type would be:
> 
>> Consider a type hierarchy like:
>> 
>>   - organization
>>     - company
>                 - division
>>     - foundation
>> 
> Yes?
> 
>> Now, let's say you want to find those topics which are explicitly marked in the topic map as instances of "organization", so that you can tell people to turn them into instances of one of the subtypes. (For example.)
>> 
>> Similarly for direct-subtype. Let's say you want to visualize the type hierarchy. If querying for the subtypes of A always returns also indirect subtypes, how are you going to do it?
>> 
> 
> Err, isn't "always returns also indirect subtypes" an implementation choice that has to be "fixed" by "direct-subtype?"
> 
> There is a declaration of super-type/sub-type for the relationship to exist at all.
> 
> So what is the difficulty....
> 
> Ah, it is a question of what is the default?
> 
> OK.
> 
> In other words, "sub-type organization" could by *default* return
> 
> company,
> 
> or
> 
> company, division, and foundation.
> 
> If the "default" is only company, then need something like sub-type * organization, to return all the subtypes of organization.
> 
> I would be in favor of the wildcard operator since that is an explicit choice to take the hit on getting all the subtypes (I am sure this will come up in other cases as well) and it leaves a well-defined default if the wildcard is not specified.
> 
>> We included 'direct-instance-of' in tolog and are very glad we did, because while it's quite a bit less common than 'instance-of' it's used quite a bit.
>> 
> 
> If it is used more often than obtaining all the subtypes, let's make it the default position.
> 
> Hope you are having a great day!
> 
> Patrick
> 
> 
>> --Lars M.
>> http://www.garshol.priv.no/tmphoto/
>> http://www.garshol.priv.no/blog/
>> _______________________________________________
>> topicmapmail mailing list
>> topicmapmail-Zo64W7twoUFWk0Htik3J/[email protected]
>> http://www.infoloom.com/mailman/listinfo/topicmapmail
> 
> -- 
> Patrick Durusau
> patrick-Q/[email protected]
> Chair, V1 - US TAG to JTC 1/SC 34
> Convener, JTC 1/SC 34/WG 3 (Topic Maps)
> Editor, OpenDocument Format TC (OASIS), Project Editor ISO/IEC 26300
> Co-Editor, ISO/IEC 13250-1, 13250-5 (Topic Maps)
> 
> Another Word For It (blog): http://tm.durusau.net
> Homepage: http://www.durusau.net
> Twitter: patrickDurusau
> _______________________________________________
> topicmapmail mailing list
> topicmapmail-Zo64W7twoUFWk0Htik3J/[email protected]
> http://www.infoloom.com/mailman/listinfo/topicmapmail
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.