ILIAS
trunk Revision v11.0_alpha-1769-g99a433fe2dc
◀ ilDoc Overview
Main Page
Related Pages
Modules
+
Namespaces
Namespace List
+
Namespace Members
+
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
k
l
m
n
o
p
r
s
t
u
v
w
x
+
Variables
$
c
e
g
h
j
l
m
p
s
t
u
v
+
Enumerations
a
c
e
f
i
j
l
m
n
o
p
r
s
t
u
v
z
+
Enumerator
a
c
d
e
f
g
i
l
m
n
o
p
q
s
t
u
v
y
+
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
Ö
Enumerations
Enumerator
+
Files
File List
+
Globals
+
All
$
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
z
+
Functions
a
b
c
d
e
f
g
h
i
m
n
p
r
s
t
u
v
+
Variables
$
a
c
e
g
h
i
m
n
o
p
r
s
t
u
v
z
Enumerations
Enumerator
Examples
•
All
Data Structures
Namespaces
Files
Functions
Variables
Enumerations
Enumerator
Modules
Pages
ilObjectPropertyIsOnline.php
Go to the documentation of this file.
1
<?php
2
19
declare(strict_types=1);
20
21
use
ILIAS\UI\Component\Input\Field\Checkbox
;
22
use
ILIAS\UI\Component\Input\Field\Factory
as
FieldFactory
;
23
use
ILIAS\Refinery\Factory
as
Refinery
;
24
28
class
ilObjectPropertyIsOnline
implements
ilObjectProperty
29
{
30
private
const
DEFAULT_IS_ONLINE
=
false
;
31
private
const
INPUT_LABEL
=
'online'
;
32
private
const
INPUT_BYLINE
=
'online_input_byline'
;
33
34
public
function
__construct
(
35
private
bool
$is_online = self::DEFAULT_IS_ONLINE
36
) {
37
}
38
39
public
function
getIsOnline
(): bool
40
{
41
return
$this->is_online;
42
}
43
44
public
function
withOnline
(): self
45
{
46
$clone = clone $this;
47
$clone->is_online =
true
;
48
return
$clone;
49
}
50
51
public
function
withOffline
(): self
52
{
53
$clone = clone $this;
54
$clone->is_online =
false
;
55
return
$clone;
56
}
57
58
public
function
toForm
(
59
\
ilLanguage
$language,
60
FieldFactory
$field_factory,
61
Refinery
$refinery
62
):
Checkbox
{
63
$trafo = $refinery->custom()->transformation(
64
function
($v):
ilObjectProperty
{
65
return
new
ilObjectPropertyIsOnline
($v);
66
}
67
);
68
return
$field_factory->checkbox($language->
txt
(self::INPUT_LABEL))
69
->withByline($language->
txt
(self::INPUT_BYLINE))
70
->
withAdditionalTransformation
($trafo)
71
->withValue($this->
getIsOnline
());
72
}
73
}
Checkbox
ILIAS\UI\examples\Layout\Page\Standard\$refinery
$refinery
Definition:
ui.php:137
ilLanguage
ilObjectPropertyIsOnline
Definition:
ilObjectPropertyIsOnline.php:28
ilLanguage\txt
txt(string $a_topic, string $a_default_lang_fallback_mod="")
gets the text for a given topic if the topic is not in the list, the topic itself with "-" will be re...
Definition:
class.ilLanguage.php:170
ilObjectPropertyIsOnline\getIsOnline
getIsOnline()
Definition:
ilObjectPropertyIsOnline.php:39
ILIAS\UI\Component\Input\Field\Checkbox
This describes checkbox inputs.
Definition:
Checkbox.php:28
ilObjectPropertyIsOnline\INPUT_BYLINE
const INPUT_BYLINE
Definition:
ilObjectPropertyIsOnline.php:32
ilObjectPropertyIsOnline\withOffline
withOffline()
Definition:
ilObjectPropertyIsOnline.php:51
Factory
ilObjectPropertyIsOnline\DEFAULT_IS_ONLINE
const DEFAULT_IS_ONLINE
Definition:
ilObjectPropertyIsOnline.php:30
ilObjectProperty
Definition:
ilObjectProperty.php:27
ilObjectPropertyIsOnline\withOnline
withOnline()
Definition:
ilObjectPropertyIsOnline.php:44
Factory
ilObjectPropertyIsOnline\toForm
toForm(\ilLanguage $language, FieldFactory $field_factory, Refinery $refinery)
Definition:
ilObjectPropertyIsOnline.php:58
ILIAS\UI\Implementation\Component\Input\ViewControl\withAdditionalTransformation
withAdditionalTransformation(Transformation $trafo)
Definition:
GroupDecorator.php:57
ilObjectPropertyIsOnline\__construct
__construct(private bool $is_online=self::DEFAULT_IS_ONLINE)
Definition:
ilObjectPropertyIsOnline.php:34
ilObjectPropertyIsOnline\INPUT_LABEL
const INPUT_LABEL
Definition:
ilObjectPropertyIsOnline.php:31
components
ILIAS
ILIASObject
classes
Properties
CoreProperties
ilObjectPropertyIsOnline.php
Generated on Sun Apr 13 2025 23:03:07 for ILIAS by
1.8.13 (using
Doxyfile
)