Porovnávané verzie

Kľúč

  • Tento riadok sa pridal
  • Riadok je odstránený.
  • Formátovanie sa zmenilo.

%GetAccessLevel function


Function
The function retrieves the access right level to a specified object.
Declaration


Blok kódu
languageesl
themeConfluence
INT %GetAccessLevel(
   HBJ in objectRef
   [, HBJ in accessingObjectRef]
 )
Parameters


objectRef
Reference
A reference to the object
,
you want to detect access rights to.
accessingObjectRef
Reference
A reference to an object of the Process or User
types
type - for which you detect the access rights to the object objectRef.
Description
The function retrieves the access rights of the object specified by the parameter accessingObejctRef to the object objectRef.

If the parameter accessingObjectRef is:
  • object of the Process type - the function returns the access right of the process to the given object
     
  • object of the User type - the function returns the access rights of the user to the given object
     
  • not specified - there are retrieved:
    • the access rights of logged user if the script is running within active picture
    • the access rights of the process D2000 EventHandler process (that one has the administrator rights) if the script is running within object of the Event type
Return value

Return The return values are expressed by the values of the predefined local variables:

  • _ACC_NONE - no access (0)
  • _ACC_READ - read level access (1)
  • _ACC_CONTROL - access to set value (control) (2)
  • _ACC_MODIFY - configuration access (3)

The values are increasing together with access rights.
If the access level is _ACC_CONTROL, then the access levels _ACC_READ is available automatically.
If the access is level _ACC_MODIFY, then the accesses levels _ACC_CONTROL and _ACC_READ are automatically available.