Labels

Top  Previous  Next

Labels are an extension to the topic maps names mechanism that makes it much easier for topic map creators and consumers to define the string to be used to display the topic for a given language. A Web3 topic label consists of a string value and a language code. The language code is specified as either a two letter ISO language code (e.g. "en") or a two letter ISO language code followed by a dash and a two letter ISO country code (e.g. "en-GB"). This format matches the format used by web browsers to specify their language preferences.

 

Although Web3 supports a large number of different language codes (well over two hundred), the administrator can configure the server to limit the options provided in the editor and other Web3 interfaces to make the editing experience easier.

 

Labels are exported in the XTM representation as topic names with a type that has the subject identifier http://www.networkedplanet.com/psi/web3/core/label, and with a scope that contains a single topic with a subject identifier generated as the concatenation of http://www.topicmaps.org/xtm/language.xtm# and the language code (in lowercase). On import, any topic name that conforms to this format will be imported as a label on the topic. In the RDF representation, labels are exported as an RDF property of the type http://www.networkedplanet.com/psi/web3/core/label with a language specifier on the property value.

 

A topic can only have one label for each language code, so on import if there are multiple topic names that map to a label for the same language code, only one of the values will be stored.