Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
100.00% covered (success)
100.00%
5 / 5
100.00% covered (success)
100.00%
5 / 5
CRAP
100.00% covered (success)
100.00%
1 / 1
Room
100.00% covered (success)
100.00%
5 / 5
100.00% covered (success)
100.00%
5 / 5
5
100.00% covered (success)
100.00%
1 / 1
 __construct
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 getName
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 getEvents
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setEvents
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 getGuid
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
1<?php
2
3declare(strict_types=1);
4
5namespace Engelsystem\Helpers\Schedule;
6
7class Room extends ScheduleData
8{
9    /**
10     * @param Event[] $events
11     * @param ?string $guid Globally unique id
12     */
13    public function __construct(
14        protected string $name,
15        protected ?string $guid = null,
16        protected array $events = []
17    ) {
18    }
19
20    public function getName(): string
21    {
22        return $this->name;
23    }
24
25    /**
26     * @return Event[]
27     */
28    public function getEvents(): array
29    {
30        return $this->events;
31    }
32
33    /**
34     * @param Event[] $events
35     */
36    public function setEvents(array $events): void
37    {
38        $this->events = $events;
39    }
40
41    public function getGuid(): ?string
42    {
43        return $this->guid;
44    }
45}