| ILIAS
    Release_4_1_x_branch Revision 61804
    | 
Class ilAccessHandler. More...
 Collaboration diagram for ilAccessHandler:
 Collaboration diagram for ilAccessHandler:| Public Member Functions | |
| ilAccessHandler () | |
| constructor | |
| storeAccessResult ($a_permission, $a_cmd, $a_ref_id, $a_access_granted, $a_user_id="", $a_info="") | |
| store access result | |
| setPreventCachingLastResult ($a_val) | |
| Set prevent caching last result. | |
| getPreventCachingLastResult () | |
| Get prevent caching last result. | |
| getStoredAccessResult ($a_permission, $a_cmd, $a_ref_id, $a_user_id="") | |
| get stored access result | |
| storeCache () | |
| readCache ($a_secs=0) | |
| getResults () | |
| setResults ($a_results) | |
| addInfoItem ($a_type, $a_text, $a_data="") | |
| add an info item to current info object | |
| checkAccess ($a_permission, $a_cmd, $a_ref_id, $a_type="", $a_obj_id="", $a_tree_id="") | |
| check access for an object (provide $a_type and $a_obj_id if available for better performance) | |
| checkAccessOfUser ($a_user_id, $a_permission, $a_cmd, $a_ref_id, $a_type="", $a_obj_id="", $a_tree_id="") | |
| check access for an object (provide $a_type and $a_obj_id if available for better performance) | |
| getInfo () | |
| get last info object | |
| getResultLast () | |
| get last info object | |
| getResultAll ($a_ref_id="") | |
| doCacheCheck ($a_permission, $a_cmd, $a_ref_id, $a_user_id) | |
| look if result for current query is already in cache | |
| doTreeCheck ($a_permission, $a_cmd, $a_ref_id, $a_user_id) | |
| check if object is in tree and not deleted | |
| doRBACCheck ($a_permission, $a_cmd, $a_ref_id, $a_user_id, $a_type) | |
| rbac check for current object -> type should be used for create permission | |
| doPathCheck ($a_permission, $a_cmd, $a_ref_id, $a_user_id, $a_all=false) | |
| check read permission for all parents | |
| doActivationCheck ($a_permission, $a_cmd, $a_ref_id, $a_user_id, $a_all=false) | |
| check for course activation | |
| preloadActivationTimes ($a_ref_ids) | |
| preload activation times of course items loads all required timing data for the given ref ids | |
| doConditionCheck ($a_permission, $a_cmd, $a_ref_id, $a_user_id, $a_obj_id, $a_type) | |
| condition check (currently only implemented for read permission) | |
| doStatusCheck ($a_permission, $a_cmd, $a_ref_id, $a_user_id, $a_obj_id, $a_type) | |
| object type specific check | |
| doLicenseCheck ($a_permission, $a_cmd, $a_ref_id, $a_user_id, $a_obj_id, $a_type) | |
| check for available licenses | |
| clear () | |
| enable ($a_str, $a_bool) | |
| Protected Attributes | |
| $stored_rbac_access = array() | |
Class ilAccessHandler.
Checks access for ILIAS objects
Definition at line 20 of file class.ilAccessHandler.php.
| ilAccessHandler::addInfoItem | ( | $a_type, | |
| $a_text, | |||
| $a_data = "" | |||
| ) | 
add an info item to current info object
Definition at line 189 of file class.ilAccessHandler.php.
| ilAccessHandler::checkAccess | ( | $a_permission, | |
| $a_cmd, | |||
| $a_ref_id, | |||
| $a_type = "", | |||
| $a_obj_id = "", | |||
| $a_tree_id = "" | |||
| ) | 
check access for an object (provide $a_type and $a_obj_id if available for better performance)
| string | $a_permission | |
| string | $a_cmd | |
| int | $a_ref_id | |
| string | $a_type | (optional) | 
| int | $a_obj_id | (optional) | 
| int | $a_tree_id | (optional) | 
Definition at line 206 of file class.ilAccessHandler.php.
References checkAccessOfUser().
 Here is the call graph for this function:
 Here is the call graph for this function:| ilAccessHandler::checkAccessOfUser | ( | $a_user_id, | |
| $a_permission, | |||
| $a_cmd, | |||
| $a_ref_id, | |||
| $a_type = "", | |||
| $a_obj_id = "", | |||
| $a_tree_id = "" | |||
| ) | 
check access for an object (provide $a_type and $a_obj_id if available for better performance)
| integer | $a_user_id | |
| string | $a_permission | |
| string | $a_cmd | |
| int | $a_ref_id | |
| string | $a_type | (optional) | 
| int | $a_obj_id | (optional) | 
| int | $a_tree_id | (optional) | 
Definition at line 226 of file class.ilAccessHandler.php.
References $ilBench, $lng, ilObject\_lookupObjId(), ilObject\_lookupType(), doCacheCheck(), doConditionCheck(), doLicenseCheck(), doPathCheck(), doRBACCheck(), doStatusCheck(), doTreeCheck(), IL_NO_PERMISSION, setPreventCachingLastResult(), and storeAccessResult().
Referenced by checkAccess(), doActivationCheck(), doConditionCheck(), and doPathCheck().
 Here is the call graph for this function:
 Here is the call graph for this function: Here is the caller graph for this function:
 Here is the caller graph for this function:| ilAccessHandler::clear | ( | ) | 
Definition at line 797 of file class.ilAccessHandler.php.
| ilAccessHandler::doActivationCheck | ( | $a_permission, | |
| $a_cmd, | |||
| $a_ref_id, | |||
| $a_user_id, | |||
| $a_all = false | |||
| ) | 
check for course activation
Definition at line 567 of file class.ilAccessHandler.php.
References $ilBench, $ilLog, ilCourseItems\_readActivationTimes(), checkAccessOfUser(), IL_CRS_TIMINGS_ACTIVATION, and preloadActivationTimes().
Referenced by doPathCheck().
 Here is the call graph for this function:
 Here is the call graph for this function: Here is the caller graph for this function:
 Here is the caller graph for this function:| ilAccessHandler::doCacheCheck | ( | $a_permission, | |
| $a_cmd, | |||
| $a_ref_id, | |||
| $a_user_id | |||
| ) | 
look if result for current query is already in cache
Definition at line 375 of file class.ilAccessHandler.php.
References $ilBench, and getStoredAccessResult().
Referenced by checkAccessOfUser().
 Here is the call graph for this function:
 Here is the call graph for this function: Here is the caller graph for this function:
 Here is the caller graph for this function:| ilAccessHandler::doConditionCheck | ( | $a_permission, | |
| $a_cmd, | |||
| $a_ref_id, | |||
| $a_user_id, | |||
| $a_obj_id, | |||
| $a_type | |||
| ) | 
condition check (currently only implemented for read permission)
Definition at line 675 of file class.ilAccessHandler.php.
References $ilBench, $lng, ilConditionHandler\_checkAllConditionsOfTarget(), ilConditionHandler\_getConditionsOfTarget(), ilObject\_lookupTitle(), checkAccessOfUser(), and IL_MISSING_PRECONDITION.
Referenced by checkAccessOfUser().
 Here is the call graph for this function:
 Here is the call graph for this function: Here is the caller graph for this function:
 Here is the caller graph for this function:| ilAccessHandler::doLicenseCheck | ( | $a_permission, | |
| $a_cmd, | |||
| $a_ref_id, | |||
| $a_user_id, | |||
| $a_obj_id, | |||
| $a_type | |||
| ) | 
check for available licenses
Definition at line 750 of file class.ilAccessHandler.php.
References $lng, ilLicenseAccess\_checkAccess(), ilLicenseAccess\_isEnabled(), IL_NO_LICENSE, and storeAccessResult().
Referenced by checkAccessOfUser().
 Here is the call graph for this function:
 Here is the call graph for this function: Here is the caller graph for this function:
 Here is the caller graph for this function:| ilAccessHandler::doPathCheck | ( | $a_permission, | |
| $a_cmd, | |||
| $a_ref_id, | |||
| $a_user_id, | |||
| $a_all = false | |||
| ) | 
check read permission for all parents
Definition at line 511 of file class.ilAccessHandler.php.
References $ilBench, $lng, $path, checkAccessOfUser(), doActivationCheck(), and IL_NO_PARENT_ACCESS.
Referenced by checkAccessOfUser().
 Here is the call graph for this function:
 Here is the call graph for this function: Here is the caller graph for this function:
 Here is the caller graph for this function:| ilAccessHandler::doRBACCheck | ( | $a_permission, | |
| $a_cmd, | |||
| $a_ref_id, | |||
| $a_user_id, | |||
| $a_type | |||
| ) | 
rbac check for current object -> type should be used for create permission
Definition at line 462 of file class.ilAccessHandler.php.
References $ilBench, $ilErr, $ilLog, $lng, IL_NO_PERMISSION, and storeAccessResult().
Referenced by checkAccessOfUser().
 Here is the call graph for this function:
 Here is the call graph for this function: Here is the caller graph for this function:
 Here is the caller graph for this function:| ilAccessHandler::doStatusCheck | ( | $a_permission, | |
| $a_cmd, | |||
| $a_ref_id, | |||
| $a_user_id, | |||
| $a_obj_id, | |||
| $a_type | |||
| ) | 
object type specific check
Definition at line 708 of file class.ilAccessHandler.php.
References $ilBench, $location, and storeAccessResult().
Referenced by checkAccessOfUser().
 Here is the call graph for this function:
 Here is the call graph for this function: Here is the caller graph for this function:
 Here is the caller graph for this function:| ilAccessHandler::doTreeCheck | ( | $a_permission, | |
| $a_cmd, | |||
| $a_ref_id, | |||
| $a_user_id | |||
| ) | 
check if object is in tree and not deleted
Definition at line 402 of file class.ilAccessHandler.php.
References $ilBench, $lng, IL_DELETED, IL_NO_PERMISSION, and storeAccessResult().
Referenced by checkAccessOfUser().
 Here is the call graph for this function:
 Here is the call graph for this function: Here is the caller graph for this function:
 Here is the caller graph for this function:| ilAccessHandler::enable | ( | $a_str, | |
| $a_bool | |||
| ) | 
Definition at line 804 of file class.ilAccessHandler.php.
| ilAccessHandler::getInfo | ( | ) | 
get last info object
Definition at line 345 of file class.ilAccessHandler.php.
| ilAccessHandler::getPreventCachingLastResult | ( | ) | 
Get prevent caching last result.
Definition at line 104 of file class.ilAccessHandler.php.
Referenced by storeAccessResult().
 Here is the caller graph for this function:
 Here is the caller graph for this function:| ilAccessHandler::getResultAll | ( | $a_ref_id = "" | ) | 
Definition at line 361 of file class.ilAccessHandler.php.
References $results.
| ilAccessHandler::getResultLast | ( | ) | 
get last info object
Definition at line 356 of file class.ilAccessHandler.php.
| ilAccessHandler::getResults | ( | ) | 
Definition at line 176 of file class.ilAccessHandler.php.
References $results.
| ilAccessHandler::getStoredAccessResult | ( | $a_permission, | |
| $a_cmd, | |||
| $a_ref_id, | |||
| $a_user_id = "" | |||
| ) | 
get stored access result
private
| string | $a_permission | permission | 
| string | $a_cmd | command string | 
| int | $a_ref_id | reference id | 
| int | $a_user_id | user id (if no id passed, current user id) | 
Definition at line 121 of file class.ilAccessHandler.php.
Referenced by doCacheCheck().
 Here is the caller graph for this function:
 Here is the caller graph for this function:| ilAccessHandler::ilAccessHandler | ( | ) | 
constructor
Definition at line 27 of file class.ilAccessHandler.php.
References $lng.
| ilAccessHandler::preloadActivationTimes | ( | $a_ref_ids | ) | 
preload activation times of course items loads all required timing data for the given ref ids
public
| array | array(int) ref_id | 
Definition at line 653 of file class.ilAccessHandler.php.
References $ref_id, and ilCourseItems\_readActivationTimes().
Referenced by doActivationCheck().
 Here is the call graph for this function:
 Here is the call graph for this function: Here is the caller graph for this function:
 Here is the caller graph for this function:| ilAccessHandler::readCache | ( | $a_secs = 0 | ) | 
Definition at line 156 of file class.ilAccessHandler.php.
References $ilDB, $query, and DB_FETCHMODE_ASSOC.
| ilAccessHandler::setPreventCachingLastResult | ( | $a_val | ) | 
Set prevent caching last result.
| boolean | true if last result should not be cached | 
Definition at line 94 of file class.ilAccessHandler.php.
Referenced by checkAccessOfUser().
 Here is the caller graph for this function:
 Here is the caller graph for this function:| ilAccessHandler::setResults | ( | $a_results | ) | 
Definition at line 181 of file class.ilAccessHandler.php.
| ilAccessHandler::storeAccessResult | ( | $a_permission, | |
| $a_cmd, | |||
| $a_ref_id, | |||
| $a_access_granted, | |||
| $a_user_id = "", | |||
| $a_info = "" | |||
| ) | 
store access result
private
| string | $a_permission | permission | 
| string | $a_cmd | command string | 
| int | $a_ref_id | reference id | 
| boolean | $a_access_granted | true if access is granted | 
| int | $a_user_id | user id (if no id passed, current user id) | 
Definition at line 57 of file class.ilAccessHandler.php.
References getPreventCachingLastResult().
Referenced by checkAccessOfUser(), doLicenseCheck(), doRBACCheck(), doStatusCheck(), and doTreeCheck().
 Here is the call graph for this function:
 Here is the call graph for this function: Here is the caller graph for this function:
 Here is the caller graph for this function:| ilAccessHandler::storeCache | ( | ) | 
| 
 | protected | 
Definition at line 22 of file class.ilAccessHandler.php.