[topicmapmail] Re: Topic Map - scope

Thomas B. Passin tpassin@comcast.net
Tue, 14 Oct 2003 09:36:54 -0400


Dichev, Christo wrote:

It would be better if you explained what you want to achieve before 
writing some XTM.  What you present seems a bit confusing.  You seem to 
want to assign occurrences to associations, which is not kosher.  You 
would assign those occurrences to a topic, whose subject is the 
association in question, not to the instanceOf topic.

In your example, you have said that the same topic (unit-1) is the type 
of the association, and also is a role-playing topic in the association. 
  Your roles are the same type as the occurrence types.  Neither of 
these makes much sense to me.

Scopes work fine for interactive filtering, but you have to decide what 
you want to accomplish.

How you represent your units depends on how you view them and how they 
all fit together.  If you want to express that a unit uses different web 
pages for average and good students, you can do that using scopes as 
youhave, without messing with an association.

Alternatively, you could decide to link the unit with the web pages 
using an association - then the unit topic would not also have them as 
occurrences.

Or you could decide that there are really two units one for average and 
one for good students, and link them using an association.

You cannot necessarily expect a general-purpose UI to display these 
alternatives exactly the way you would like, though.  It might or might 
not.  For example, one of my standard UIs can filter topic names or 
associations by scope, but not occurrences.

Your phrse "to filter some information (ignore irrelevant occurrences, 
roles) based on the user interaction with a topic map" does not explain 
enough about what you want.

Cheers,

Tom P

> <topic id="unit-1">
>   <instanceOf><topicRef xlink:href="#leson"/></instanceOf>
>   <baseName>
>     <baseNameString> First Unit</baseNameString>
>   </baseName>
> <baseName>
>       <scope>
>         <topicRef xlink:href="#average-student"/>
>       </scope>
>       <baseNameString>Unit for average</baseNameString>
>     </baseName>
>   <occurrence>
>    <scope><topicRef xlink:href="#average-student"/></scope>
>     <instanceOf><topicRef xlink:href="#webpage"/></instanceOf>
>     <resourceRef 
> xlink:href="http://wssu.edu/faculty/dichevc/ex/sect1.htm"/>
>   </occurrence>
> <baseName>
>       <scope>
>         <topicRef xlink:href="#good-student"/>
>       </scope>
>       <baseNameString>Unit for good</baseNameString>
>     </baseName>
>   <occurrence>
>     <scope><topicRef xlink:href="#good-student"/></scope>
>     <instanceOf><topicRef xlink:href="#webpage"/></instanceOf>
>     <resourceRef 
> xlink:href="http://wssu.edu/faculty/dichevc/ex/sect2.html"/>
>   </occurrence>
> </topic>
> 
> Now given that topic to use it to type an association, i.e.
> 
> <association>
>     <instanceOf>
>       <topicRef xlink:href="#unit-1"/>
>     </instanceOf>
>     <member>
>   <scope><topicRef xlink:href="#average-student"/></scope>
>       <roleSpec>
>         <topicRef xlink:href="#average-student"/>
>       </roleSpec>
>    <topicRef xlink:href="#unit-1"/>
>     </member>
>     <member>
>   <scope><topicRef xlink:href="#good-student"/></scope>
>       <roleSpec>
>         <topicRef xlink:href="#good-student"/>
>       </roleSpec>
>    <topicRef xlink:href="#unit-1"/>
>     </member>
>   </association>
> 
> so that the Omnigator displays different occurrences depending on
> the context, say based on the "current topic". May be this is a
> wrong approach. My intention is construct an example that is able
> to filter some information (ignore irrelevant occurrences, roles)
> based on the user interaction with a topic map.
> 
> Any help in this direction will be appreciated.
> 
> Thank you,
> Christo
> 
> 
> Hi Christo,
> 
> * Christo Dichev
> |
> | However I can't generate simple and meaningful examples to start up.
> | For instance, I can not figure out how can the resources in the
> | following topic be displayed depending on the context
> | ("average-student" or "good-student").
> 
> Not sure what you mean here. Your XTM snippets look perfectly OK with
> me, so I'm not sure what the problem is.
> 
> If you want to try them out, just load the topic map in the Omnigator,
> then click on the "Filter" link near the top. You can select your
> preferred scope there, and the Omnigator will automatically start
> filtering. Was that what you wanted to know, or did I completely
> misunderstand your question?
> 
> -- 
> Lars Marius Garshol, Ontopian         <URL: http://www.ontopia.net >
> GSM: +47 98 21 55 50                  <URL: http://www.garshol.priv.no >
> 
> _______________________________________________
> topicmapmail mailing list
> topicmapmail@infoloom.com
> http://www.infoloom.com/mailman/listinfo/topicmapmail
>