AJAX Interface

Set up the server

The server can be configured via the variables - these URLs are all relative to the used host-name by starting the server with "(rest-interface:start-tm-engine "data_base" :host-name " :port 8000").
The server handles JSON-data - the JSON-model is defined in JSON_model.pdf.

  • rest-interface:*ajax-user-interface-url*
  • rest-interface:*json-get-prefix*
  • rest-interface:*rdf-get-prefix*
  • rest-interface:*json-commit-url*
  • rest-interface:*json-get-all-psis*
  • rest-interface:*json-get-summary-url*
  • rest-interface:*json-get-all-type-psis*
  • rest-interface:*json-get-all-instance-psis*
  • rest-interface:*json-get-topic-stub-prefix*
  • rest-interface:*json-get-type-tmcl-url*
  • rest-interface:*json-get-instance-tmcl-url*
  • rest-interface:*json-get-overview*
  • rest-interface:*ajax-user-interface-css-prefix*
  • rest-interface:*ajax-user-interface-css-directory-path*
    • relative directory path of all css-files (relative to src/)
    • default: ajax/css
  • rest-interface:*ajax-user-interface-file-path*
    • relative file path to the entry-file (isidorus.html) which includes all javascript- and css-files
    • default: ajax/isidorus.html
  • rest-interface:*ajax-javascript-directory-path*
    • relative fiel path to all javascript-files
    • default: ajax/javascripts
  • rest-interface:*ajax-javascript-url-prefix*
    • URL-prefix for all javascript files
    • default: /javascripts
  • rest-interface:*mark-as-deleted-url*
    • URL-suffix to mark the passed object in JSON-notation as deleted
    • default: /mark-as-deleted
  • rest-interface:*sparql-url*
    • URL-suffix to query the TM backend via TM-SPARQL
    • default: /json/tm-sparql

To stop the server you can use the statement "(rest-interface:shutdown-tm-engine)". After the next call the server will shut down.

Set up the client

To configure the client you just need to set the constant HOST_PREF in src/ajax/javascripts/constants.js to the host-name you use. The constants


must be set to the corresponding values explained in "Set up the Server".
Note to be able to create new topic-instances via the client there is needed a TMCL (draft 07.08.2008) template. The lates template is currently not supported.

Topic Maps Overview

topic maps overview

When you call the Isidoprus-page you will see the "home"-section. This section represents a tree-view of all valid- "topic types" and "topic instances".
There can exist more trees, if there is no topictype-constraint - otherwise the topic "topictype" is the single root. So every topic that is not an instance and subtype of any other topic is a root topic. A node containes all PSIs of the representing topic, a link to edit the selected topic, a link to create a new topic-instance for the selected topic-type, sub-nodes with instance and subtypes of the current topic.

By clicking on nodes that contain sub-nodes it's possible to hide/show all sub-nodes of a specific node. After hiding some subnodes the parent-element will be displayed with an orange-color.

Depending on the amount of topics that Isidorus has to handle - it can take a few seconds to load this page.

Search Topics

At the moment, this section is not implemented!

Edit Topcis


First all editable topics have to be requested - so it is possible to select a topic-psi. After selecting a psi the fragment-template will be generated from the requested fragment- and TMCL-data.

All elements that are displayed with an orange colour as default or by hovering them - are able to execute any kind of action. This can be hiding, showing, disabling or enabling something. action

Optional elements like itemIdentifiers are disabled when they own no content. Optionl names and occurrences are also disabled and additionaly minimized. You can maximize/minimize those elements by clicking the ">>"/"<<" buttons. minimize
Elements that owns a bigger range of allowed instances can be added or removed by clicking "+"/"-". But note you are not able to remove all elements, one must stay, you can disable this element by a double click on it.

Name-variants are as deafault always disabled unless they have any content. At the moment it is not possible to set any scope on variants. variants

To check if a fragment is valid you can use the button "validate fragment" or send it directly by clicking on "commit fragment". It will be validated automatically and sent only when the fragment ist valid. commit

Otherwise you will see a message similar to this one.

Create Topics

This section is very similar to "Edit Topics" - the difference is that you choose one or more topics which are valid types. By committing the fragment there won't be edit a topic but created a new instance of the selected types. If there exist any exclusive-instance-constraint the client handles this conflict and displays a message.
The functionality of the fragment-template is the same as explained in "Edit Topics".

Last modified 13 years ago Last modified on 04/18/11 13:34:38

Attachments (8)

Download all attachments as: .zip