ILIAS  release_5-2 Revision v5.2.25-18-g3f80b828510
class.ilFileSystemStorageWebAccessChecker.php
Go to the documentation of this file.
1 <?php
2 /* Copyright (c) 1998-2009 ILIAS open source, Extended GPL, see docs/LICENSE */
3 
4 include_once "Services/WebAccessChecker/interfaces/interface.ilComponentWebAccessChecker.php";
5 
16 {
17  protected $object_id; // [int]
18 
19  public function isValidPath(array $a_path)
20  {
21  // last element is file
22  array_pop($a_path);
23 
24  // 2nd to last: directory with object id
25  $dir = array_pop($a_path);
26 
27  // extract id from directory title
28  $obj_id = (int)array_pop(explode("_", $dir));
29  if((int)$obj_id)
30  {
31  $this->object_id = $obj_id;
32  return true;
33  }
34  }
35 
36  public function getRepositoryObjectId()
37  {
38  return $this->object_id;
39  }
40 
41  public function checkAccess(array $a_user_ids)
42  {
43 
44  }
45 }
getRepositoryObjectId()
Get repository object id from path if any.
isValidPath(array $a_path)
Check if current (image) path is valid.
checkAccess(array $a_user_ids)
Custom access method.
Create styles array
The data for the language used.
interface for modular web access checker