ILIAS
release_8 Revision v8.19-1-g4e8f2f9140c
◀ 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
n
o
p
r
s
t
u
v
w
x
+
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
j
l
m
p
s
t
u
+
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
r
s
t
u
v
w
x
z
+
Functions
_
a
b
c
d
e
g
h
i
m
n
p
r
s
t
u
v
x
+
Variables
$
a
c
d
e
f
g
h
i
j
k
l
m
n
o
p
r
s
t
u
v
w
z
Examples
•
All
Data Structures
Namespaces
Files
Functions
Variables
Modules
Pages
ilForumRequestTrait.php
Go to the documentation of this file.
1
<?php
2
19
declare(strict_types=1);
20
21
use
ILIAS\HTTP\Wrapper\ArrayBasedRequestWrapper
;
22
23
trait
ilForumRequestTrait
24
{
25
private
function
retrieveIntOrZeroFrom(
ArrayBasedRequestWrapper
$wrapper,
string
$param
):
int
26
{
27
$value = 0;
28
if
($wrapper->
has
($param)) {
29
$value = $wrapper->
retrieve
(
30
$param,
31
$this->
refinery
->byTrying([
32
$this->refinery->kindlyTo()->int(),
33
$this->
refinery
->custom()->transformation(
static
function
($value):
int
{
34
if
($value ===
''
) {
35
return
0;
36
}
37
38
return
$value;
39
})
40
])
41
);
42
}
43
44
return
$value;
45
}
46
}
ILIAS\Repository\refinery
refinery()
Definition:
trait.GlobalDICDomainServices.php:71
ArrayBasedRequestWrapper
$param
$param
Definition:
xapitoken.php:46
ILIAS\HTTP\Wrapper\ArrayBasedRequestWrapper\has
has(string $key)
Definition:
ArrayBasedRequestWrapper.php:57
ilForumRequestTrait
ILIAS\Repository\int
int(string $key)
Definition:
trait.BaseGUIRequest.php:61
ILIAS\HTTP\Wrapper\ArrayBasedRequestWrapper\retrieve
retrieve(string $key, Transformation $transformation)
Definition:
ArrayBasedRequestWrapper.php:48
Modules
Forum
classes
Request
ilForumRequestTrait.php
Generated on Wed Apr 23 2025 22:01:25 for ILIAS by
1.8.13 (using
Doxyfile
)