Total Complexity | 7 |
Total Lines | 81 |
Duplicated Lines | 0 % |
Coverage | 75% |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
14 | class GeneralizedTime implements TaggableElement |
||
15 | { |
||
16 | use TaggableElementTrait; |
||
17 | |||
18 | /** |
||
19 | * @var \DateTimeImmutable |
||
20 | */ |
||
21 | private $value; |
||
22 | |||
23 | /** |
||
24 | * Create a new instance. |
||
25 | * |
||
26 | * @param \DateTimeImmutable $value |
||
27 | * |
||
28 | * @return static |
||
29 | */ |
||
30 | 2 | public static function create(DateTimeImmutable $value) |
|
35 | } |
||
36 | |||
37 | /** |
||
38 | * {@inheritdoc} |
||
39 | * |
||
40 | * @see \Ocsp\Asn1\Element::getClass() |
||
41 | */ |
||
42 | 2 | public function getClass() |
|
45 | } |
||
46 | |||
47 | /** |
||
48 | * {@inheritdoc} |
||
49 | * |
||
50 | * @see \Ocsp\Asn1\Element::getTypeID() |
||
51 | */ |
||
52 | 2 | public function getTypeID() |
|
55 | } |
||
56 | |||
57 | /** |
||
58 | * {@inheritdoc} |
||
59 | * |
||
60 | * @see \Ocsp\Asn1\Element::isConstructed() |
||
61 | */ |
||
62 | public function isConstructed() |
||
63 | { |
||
64 | return false; |
||
65 | } |
||
66 | |||
67 | /** |
||
68 | * @return \DateTimeImmutable |
||
69 | */ |
||
70 | 2 | public function getValue() |
|
71 | { |
||
72 | 2 | return $this->value; |
|
73 | } |
||
74 | |||
75 | /** |
||
76 | * @param \DateTimeImmutable $value |
||
77 | * |
||
78 | * @return $this |
||
79 | */ |
||
80 | 2 | public function setValue(DateTimeImmutable $value) |
|
81 | { |
||
82 | 2 | $this->value = $value; |
|
83 | |||
84 | 2 | return $this; |
|
85 | } |
||
86 | |||
87 | /** |
||
88 | * {@inheritdoc} |
||
89 | * |
||
90 | * @see \Ocsp\Asn1\Element::getEncodedValue() |
||
91 | */ |
||
92 | public function getEncodedValue(Encoder $encoder) |
||
95 | } |
||
96 | } |
||
97 |