Ifd:addContextOwners

From dev.ifd-library.org

Jump to: navigation, search

API version 2

Function public IfdUser [] addContextOwners (
                                                        String context_guid,
                                                        String[] owner_guids,
                                                        String session_id )
                                  throws IfdServerException


Express heading

QUERY_FUNCTION addContextOwners( context_guid : STRING ;
                                                    owners : LIST OF IfdUser) :  LIST OF IfdUser;


Function to add new owners to a context. Only a context owner can add users to a context. If there are no owners anyone can add a new owner. The current user is automatically added as new owner.

Input:

  • string context_guid - the GUID of the context that the owners should be added to
  • String [] owner_guids - An array of global unique identifiers for all owners to be added as context users. The current user will be added as owner regardless if it is in the list or not.
  • session_id - the session id for the current user

Return:

  • IfdUser [] - An array containing the updated list of all owners for the given context.

API version 3

Function public IfdUser [] addContextOwners (
                                                        String session_id,
                                                        String context_guid,
                                                        String[] owner_guids)
                                  throws IfdServerException

Express heading

QUERY_FUNCTION addContextOwners(
                      context_guid : STRING ;
                      owners : LIST OF IfdUser) :  LIST OF IfdUser;

The function adds more owners to the context, granting them access rights to modify content of the specified context (add new and removing new relationships between concepts).

Input:

  • session_id - the session id for the current user
  • string context_guid - global unique id of the target context;
  • String [] owner_guids - list of user global unique id-s to become owners of the specified context

Return:

  • IfdUser [] - List of fully specified users – owners of the specified context (see getContextOwners output), not only just added

Difference with v.2.00

  • (27) For contexts without owners the function allows to add new owners only to database superuser. In v.2.00 the function allows to add specified owners to any logged IFD user (adding him to owners of the context at first)


Back to the API

Comments: