Completed
Push — master ( 481a61...7844f4 )
by
unknown
02:07 queued 49s
created

ThirdParty::isRecruiter()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 1
c 1
b 0
f 0
nc 1
nop 0
dl 0
loc 3
rs 10
1
<?php
2
3
declare(strict_types=1);
4
5
/* For licensing terms, see /license.txt */
6
7
namespace Chamilo\CoreBundle\Entity;
8
9
use ApiPlatform\Metadata\ApiResource;
10
use Doctrine\ORM\Mapping as ORM;
11
use Symfony\Component\Serializer\Attribute\Groups;
12
use Symfony\Component\Validator\Constraints as Assert;
13
14
#[ApiResource(
15
    normalizationContext: ['groups' => ['third_party:read']],
16
    denormalizationContext: ['groups' => ['third_party:write']],
17
    paginationEnabled: false
18
)]
19
#[ORM\Table(name: 'third_party')]
20
#[ORM\Entity]
21
class ThirdParty
22
{
23
    #[Groups(['third_party:read'])]
24
    #[ORM\Id]
25
    #[ORM\GeneratedValue]
26
    #[ORM\Column(type: 'integer')]
27
    protected ?int $id = null;
28
29
    #[Groups(['third_party:read', 'third_party:write'])]
30
    #[Assert\NotBlank]
31
    #[ORM\Column(type: 'text')]
32
    protected string $name;
33
34
    #[Groups(['third_party:read', 'third_party:write'])]
35
    #[ORM\Column(type: 'text', nullable: true)]
36
    protected ?string $description = null;
37
38
    #[Groups(['third_party:read', 'third_party:write'])]
39
    #[ORM\Column(type: 'text', nullable: true)]
40
    protected ?string $address = null;
41
42
    #[Groups(['third_party:read', 'third_party:write'])]
43
    #[ORM\Column(type: 'text', nullable: true)]
44
    protected ?string $website = null;
45
46
    #[Groups(['third_party:read', 'third_party:write'])]
47
    #[ORM\Column(type: 'boolean')]
48
    protected bool $dataExchangeParty = false;
49
50
    #[Groups(['third_party:read', 'third_party:write'])]
51
    #[ORM\Column(type: 'boolean')]
52
    protected bool $recruiter = false;
53
54
    public function getId(): ?int
55
    {
56
        return $this->id;
57
    }
58
59
    public function getName(): string
60
    {
61
        return $this->name;
62
    }
63
64
    public function setName(string $name): static
65
    {
66
        $this->name = $name;
67
68
        return $this;
69
    }
70
71
    public function getDescription(): ?string
72
    {
73
        return $this->description;
74
    }
75
76
    public function setDescription(?string $description): static
77
    {
78
        $this->description = $description;
79
80
        return $this;
81
    }
82
83
    public function getAddress(): ?string
84
    {
85
        return $this->address;
86
    }
87
88
    public function setAddress(?string $address): static
89
    {
90
        $this->address = $address;
91
92
        return $this;
93
    }
94
95
    public function getWebsite(): ?string
96
    {
97
        return $this->website;
98
    }
99
100
    public function setWebsite(?string $website): static
101
    {
102
        $this->website = $website;
103
104
        return $this;
105
    }
106
107
    public function isDataExchangeParty(): bool
108
    {
109
        return $this->dataExchangeParty;
110
    }
111
112
    public function setDataExchangeParty(bool $value): static
113
    {
114
        $this->dataExchangeParty = $value;
115
116
        return $this;
117
    }
118
119
    public function isRecruiter(): bool
120
    {
121
        return $this->recruiter;
122
    }
123
124
    public function setRecruiter(bool $value): static
125
    {
126
        $this->recruiter = $value;
127
128
        return $this;
129
    }
130
}
131