TicketReserved::getPurchaseId()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 1
nc 1
nop 0
dl 0
loc 3
rs 10
c 0
b 0
f 0
1
<?php
2
3
namespace ConferenceTools\Tickets\Domain\Event\Ticket;
4
5
use Carnage\Cqrs\Event\EventInterface;
6
use ConferenceTools\Tickets\Domain\ValueObject\TicketType;
7
use JMS\Serializer\Annotation as Jms;
8
9
class TicketReserved implements EventInterface
10
{
11
    /**
12
     * @Jms\Type("string")
13
     * @var string
14
     */
15
    private $id;
16
17
    /**
18
     * @Jms\Type("ConferenceTools\Tickets\Domain\ValueObject\TicketType")
19
     * @var TicketType
20
     */
21
    private $ticketType;
22
23
    /**
24
     * @Jms\Type("string")
25
     * @var string
26
     */
27
    private $purchaseId;
28
29
    /**
30
     * TicketReserved constructor.
31
     * @param string $id
32
     * @param TicketType $ticketType
33
     * @param string $purchaseId
34
     */
35
    public function __construct(string $id, TicketType $ticketType, string $purchaseId)
36
    {
37
        $this->id = $id;
38
        $this->ticketType = $ticketType;
39
        $this->purchaseId = $purchaseId;
40
    }
41
42
    /**
43
     * @return string
44
     */
45
    public function getId()
46
    {
47
        return $this->id;
48
    }
49
50
    /**
51
     * @return TicketType
52
     */
53
    public function getTicketType()
54
    {
55
        return $this->ticketType;
56
    }
57
58
    /**
59
     * @return string
60
     */
61
    public function getPurchaseId()
62
    {
63
        return $this->purchaseId;
64
    }
65
}