ILIAS  release_5-1 Revision 5.0.0-5477-g43f3e3fab5f
ilObjItemGroupAccess Class Reference

Item group access class. More...

+ Inheritance diagram for ilObjItemGroupAccess:
+ Collaboration diagram for ilObjItemGroupAccess:

Public Member Functions

 _checkAccess ($a_cmd, $a_permission, $a_ref_id, $a_obj_id, $a_user_id="")
 
 _checkGoto ($a_target)
 check whether goto script will succeed More...
 
- Public Member Functions inherited from ilObjectAccess
 _checkAccess ($a_cmd, $a_permission, $a_ref_id, $a_obj_id, $a_user_id="")
 Checks wether a user may invoke a command or not (this method is called by ilAccessHandler::checkAccess) More...
 
 _checkCondition ($a_obj_id, $a_operator, $a_value, $a_usr_id)
 check condition More...
 
 _getCommands ()
 get commands More...
 
 _checkGoto ($a_target)
 check whether goto script will succeed More...
 
 _preloadData ($a_obj_ids, $a_ref_ids)
 Preload data. More...
 

Static Public Member Functions

 _getCommands ()
 get list of command/permission combinations More...
 
- Static Public Member Functions inherited from ilObjectAccess
static _isOffline ($a_obj_id)
 Type-specific implementation of general status, has to be overwritten. More...
 

Detailed Description

Item group access class.

Author
Alex Killing alex..nosp@m.kill.nosp@m.ing@g.nosp@m.mx.d.nosp@m.e
Version
$Id$

Definition at line 15 of file class.ilObjItemGroupAccess.php.

Member Function Documentation

◆ _checkAccess()

ilObjItemGroupAccess::_checkAccess (   $a_cmd,
  $a_permission,
  $a_ref_id,
  $a_obj_id,
  $a_user_id = "" 
)
checks wether a user may invoke a command or not

(this method is called by ilAccessHandler::checkAccess)

@param      string          $a_cmd          command (not permission!)
@param      string          $a_permission   permission
@param      int                     $a_ref_id       reference id
@param      int                     $a_obj_id       object id
@param      int                     $a_user_id      user id (if not provided, current user is taken)

@return     boolean         true, if everything is ok

Reimplemented from ilObjectAccess.

Definition at line 49 of file class.ilObjItemGroupAccess.php.

50 {
51 global $ilUser, $lng, $rbacsystem, $ilAccess;
52
53 $a_user_id = $a_user_id ? $a_user_id : $ilUser->getId();
54 return true;
55 }
global $lng
Definition: privfeed.php:40
global $ilUser
Definition: imgupload.php:15

References $ilUser, and $lng.

◆ _checkGoto()

ilObjItemGroupAccess::_checkGoto (   $a_target)

check whether goto script will succeed

Reimplemented from ilObjectAccess.

Definition at line 61 of file class.ilObjItemGroupAccess.php.

62 {
63 global $ilAccess;
64
65 $t_arr = explode("_", $a_target);
66
67 if ($t_arr[0] != "itgr" || ((int) $t_arr[1]) <= 0)
68 {
69 return false;
70 }
71
72 if($ilAccess->checkAccess("read", "", $t_arr[1]))
73 {
74 return true;
75 }
76 return false;
77 }

◆ _getCommands()

ilObjItemGroupAccess::_getCommands ( )
static

get list of command/permission combinations

@access public

Returns
array

Reimplemented from ilObjectAccess.

Definition at line 25 of file class.ilObjItemGroupAccess.php.

26 {
27 $commands = array
28 (
29 array("permission" => "read", "cmd" => "gotoParent", "lang_var" => "", "default" => true),
30 array("permission" => "write", "cmd" => "listMaterials", "lang_var" => "edit_content", "default" => false),
31 array("permission" => "write", "cmd" => "edit", "lang_var" => "settings", "default" => false)
32 );
33
34 return $commands;
35 }

Referenced by ilObjItemGroupListGUI\init().

+ Here is the caller graph for this function:

The documentation for this class was generated from the following file: