Link

Link (short cut) is a relationship between a node and another node or some attached file in another node.

link_list_types

returns list of acceptable link types for the specified node

QUERY_FUNCTION link_list_types(id: INTEGER): LIST OF STRING

Parameter:
id (optional) assigning node instance id

link_create

put link to a node or file to specified target node in current state of pbs according to the input

To call the query logged in user shall be associated with a person granted with writer privileges over target node (EDITOR_TYPE, ADMIN_TYPE for the person or group where the person is registered)

QUERY_FUNCTION link_create(subj: v_link): v_link

Parameter:
subj input for the assignment, see v_link
the following attributes are mandatory:
  • subject.domain - hosting node instance id
  • subject.link - instance id of file or node to be referenced
some attributes of the input are ignored, like the following:
  • subject.item.instance_id - generated
  • subject.item.cancelled - set to FALSE
  • subject.item.creator - set to logged in user
  • subject.item.last_changed - set to date/time of the call
  • subject.item.last_editor - set to logged in user
  • subject.item.comments - unset
  • subject.item.events - is populated with a creation event

Returns actual attributes of the newly created link (see v_link)

link_get

gets data of a link specified by its instance id

To call the query logged in user shall be associated with a person granted with reader privileges over subject node (READER_TYPE, EDITOR_TYPE, ADMIN_TYPE for the person or group where the person is registered)

QUERY_FUNCTION link_get(id: INTEGER): v_link

Parameter:
id id of the link instance

Returns actual data of the required link (see v_link)


link_list

lists data of links specified by list of their instance id-s. Normally source of the the list is v_node returned by node_get

To call the query logged in user shall be associated with a person granted with reader privileges in subject node (READER_TYPE, EDITOR_TYPE, ADMIN_TYPE for the person or group where the person is registered)

QUERY_FUNCTION link_list(ids: LIST OF INTEGER): LIST OF v_link

Parameter:
ids list of interesting link instance id-s

Returns list of actual data of the required links (see v_link)


link_select

assigned properties search is not implemented in current realize
QUERY_FUNCTION link_select(
      node,
      file,
      creator           : INTEGER;
      file_type,
      link_type         : STRING)  :  LIST OF v_link
Parameters:
node (optional) instance id of linked node
file (optional) instance id of linked file
creator (optional) instance id of simdm person who introduced the link
file_type (optional) type of referred file
link_type (optional) type of link

Returns list of found links (see v_link)


link_update

updates data of the link. The updated link is specified by its instance id

To call the query logged in user shall be associated with a person granted with writer privileges in target node (EDITOR_TYPE, ADMIN_TYPE for the person or group where the person is registered)

QUERY_FUNCTION link_update(subject: v_link): v_link

Parameter:
subject updated data of the link to be updated in model (see v_link)
Target instance is specified by subject.item.instance_id

The following attributes are ignored:

  • subject.domain - is leaved in parent node
  • subject.item.introduced - is leaved as before
  • subject.item.creator - is leaved as before
  • subject.item.last_changed - set to current date/time
  • subject.item.last_editor - set to calling user
  • subject.item.comments - is leaved as before
  • subject.item.event - is added with update event

Returns actual data of the updated the updated link (see v_link)


link_delete

removes link specified by its instance id from the current state of pbs

To call the query logged in user shall be associated with a person granted with writer privileges in target node (EDITOR_TYPE, ADMIN_TYPE for the person or group where the person is registered)

QUERY_FUNCTION link_delete(id: INTEGER): v_link

Parameter:
id instance id of the assignment to be removed

Returns TRUE

Back to Home page