Completed
Pull Request — master (#89)
by
unknown
02:20
created

StartGreeter::onApplicationStop()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 0
cts 3
cp 0
rs 10
c 0
b 0
f 0
cc 1
eloc 1
nc 1
nop 0
crap 2
1
<?php
2
3
namespace eXpansion\Framework\Core\Plugins;
4
5
use eXpansion\Framework\Core\DataProviders\Listener\ListenerInterfaceExpApplication;
6
use eXpansion\Framework\Core\Helpers\ChatNotification;
7
use eXpansion\Framework\Core\Services\Application\AbstractApplication;
8
9
class StartGreeter implements ListenerInterfaceExpApplication
10
{
11
    /**
12
     * @var ChatNotification
13
     */
14
    private $chatNotification;
15
16
    /**
17
     * StartGreeter constructor.
18
     * @param ChatNotification $chatNotification
19
     */
20
    public function __construct(ChatNotification $chatNotification)
21
    {
22
        $this->chatNotification = $chatNotification;
23
    }
24
25
    /**
26
     * called at eXpansion init
27
     *
28
     * @return void
29
     */
30
    public function onApplicationInit()
31
    {
32
33
    }
34
35
    /**
36
     * called when init is done and callbacks are enabled
37
     *
38
     * @return void
39
     */
40
    public function onApplicationReady()
41
    {
42
        $this->chatNotification->sendMessage("");
43
        $this->chatNotification->sendMessage("");
44
        $this->chatNotification->sendMessage('$z$fff$s       -  -   –    –     —     —    –    –   -   -');
45
        $this->chatNotification->sendMessage('$z$s$w$i$fff       e X p a n s i o n ²', null, []);
46
        $this->chatNotification->sendMessage(
47
            '$z$o$000                version$o '.AbstractApplication::EXPANSION_VERSION, null, []);
48
49
        $this->chatNotification->sendMessage('$z$s$fff                 —————————— ');
50
        $this->chatNotification->sendMessage("");
51
    }
52
53
    /**
54
     * called when requesting application stop
55
     *
56
     * @return void
57
     */
58
    public function onApplicationStop()
59
    {
60
61
    }
62
}
63