ILIAS
release_7 Revision v7.30-3-g800a261c036
◀ ilDoc Overview
Main Page
Related Pages
Modules
+
Namespaces
Namespace List
+
Namespace Members
+
All
$
_
a
b
c
d
e
f
g
h
i
j
l
m
p
r
s
t
w
+
Functions
_
a
b
c
f
g
h
i
r
s
t
w
+
Variables
$
c
d
e
f
g
h
j
l
m
p
s
t
+
Data Structures
Data Structures
Data Structure Index
Class Hierarchy
+
Data Fields
+
All
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Variables
$
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Files
File List
+
Globals
+
All
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
+
Functions
_
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
w
x
+
Variables
$
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Examples
•
All
Data Structures
Namespaces
Files
Functions
Variables
Modules
Pages
class.ilObjFileServicesAccess.php
Go to the documentation of this file.
1
<?php
2
7
class
ilObjFileServicesAccess
extends
ilObjectAccess
8
{
12
private
$http
;
16
private
$rbacsystem
;
17
21
public
function
__construct
()
22
{
23
global
$DIC
;
24
$this->rbacsystem = $DIC->rbac()->system();
25
$this->
http
= $DIC->http();
26
}
27
32
public
function
checkAccessAndThrowException
(
string
$permission) : void
33
{
34
if
(!$this->
hasUserPermissionTo
($permission)) {
35
throw
new
ilException
(
'Permission denied'
);
36
}
37
}
38
43
public
function
hasUserPermissionTo
(
string
$permission) : bool
44
{
45
return
(
bool
) $this->rbacsystem->checkAccess($permission, $this->
http
->request()->getQueryParams()[
'ref_id'
]);
46
}
47
48
}
ilException
ilObjectAccess
ilObjFileServicesAccess\checkAccessAndThrowException
checkAccessAndThrowException(string $permission)
Definition:
class.ilObjFileServicesAccess.php:32
ilObjFileServicesAccess
Class ilObjFileServicesAccess.
Definition:
class.ilObjFileServicesAccess.php:7
ILIAS\FileDelivery\http
static http()
Fetches the global http state from ILIAS.
Definition:
HttpServiceAware.php:36
ilObjFileServicesAccess\$rbacsystem
$rbacsystem
Definition:
class.ilObjFileServicesAccess.php:16
ilObjFileServicesAccess\__construct
__construct()
ilObjFileServicesAccess constructor.
Definition:
class.ilObjFileServicesAccess.php:21
$DIC
global $DIC
Definition:
goto.php:24
ilObjFileServicesAccess\$http
$http
Definition:
class.ilObjFileServicesAccess.php:12
ilObjFileServicesAccess\hasUserPermissionTo
hasUserPermissionTo(string $permission)
Definition:
class.ilObjFileServicesAccess.php:43
Services
FileServices
classes
class.ilObjFileServicesAccess.php
Generated on Mon Apr 7 2025 21:01:34 for ILIAS by
1.8.13 (using
Doxyfile
)