ILIAS
release_6 Revision v6.24-5-g0c8bfefb3b8
◀ 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
s
t
w
+
Functions
_
a
b
c
f
g
h
i
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
ContextStack.php
Go to the documentation of this file.
1
<?php
namespace
ILIAS\GlobalScreen\ScreenContext\Stack
;
2
3
use
ILIAS\GlobalScreen\ScreenContext\ScreenContext
;
4
10
class
ContextStack
11
{
12
16
protected
$stack
= [];
17
18
22
public
function
push
(
ScreenContext
$context
)
23
{
24
if
(in_array($context, $this->stack)) {
25
throw
new \LogicException(
"A context can only be claimed once"
);
26
}
27
array_push($this->stack, $context);
28
}
29
30
34
public
function
getLast
() :
ScreenContext
35
{
36
return
end($this->stack);
37
}
38
39
43
public
function
getStack
() : array
44
{
45
return
$this->stack
;
46
}
47
48
49
public
function
getStackAsArray
() : array
50
{
51
$return = [];
52
foreach
($this->stack as $item) {
53
$return[] = $item->getUniqueContextIdentifier();
54
}
55
56
return
$return;
57
}
58
}
ILIAS\GlobalScreen\ScreenContext\Stack\ContextStack\getStackAsArray
getStackAsArray()
Definition:
ContextStack.php:49
$context
$context
Definition:
webdav.php:26
ILIAS\GlobalScreen\ScreenContext\Stack\ContextStack
Class ContextStack.
Definition:
ContextStack.php:10
ILIAS\GlobalScreen\ScreenContext\Stack\ContextStack\$stack
$stack
Definition:
ContextStack.php:16
ScreenContext
ILIAS\GlobalScreen\ScreenContext\Stack\ContextStack\getStack
getStack()
Definition:
ContextStack.php:43
ILIAS\GlobalScreen\ScreenContext\Stack\ContextStack\push
push(ScreenContext $context)
Definition:
ContextStack.php:22
ILIAS\GlobalScreen\ScreenContext\Stack\ContextStack\getLast
getLast()
Definition:
ContextStack.php:34
ILIAS\GlobalScreen\ScreenContext\Stack
Definition:
CalledContexts.php:1
ILIAS\GlobalScreen\ScreenContext\ScreenContext
Interface ScreenContext.
Definition:
ScreenContext.php:11
src
GlobalScreen
ScreenContext
Stack
ContextStack.php
Generated on Mon Apr 7 2025 20:01:34 for ILIAS by
1.8.13 (using
Doxyfile
)