/
PHPUnitOption.php
58 lines (46 loc) · 1 KB
/
PHPUnitOption.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
<?php
declare(strict_types=1);
namespace Paraunit\Configuration;
class PHPUnitOption
{
/** @var string */
private $name;
/** @var string|null */
private $shortName;
/** @var string|null */
private $value;
/** @var bool */
private $hasValue;
/**
* @param string | null $shortName
*/
public function __construct(string $name, bool $hasValue = true, string $shortName = null)
{
$this->name = $name;
$this->hasValue = $hasValue;
$this->shortName = $shortName;
}
public function getName(): string
{
return $this->name;
}
public function getShortName(): ?string
{
return $this->shortName;
}
/**
* @param string $value
*/
public function setValue(string $value = null): void
{
$this->value = $value;
}
public function getValue(): ?string
{
return $this->value;
}
public function hasValue(): bool
{
return $this->hasValue;
}
}