1 | <?php |
||
12 | class ACValidationConfig |
||
13 | { |
||
14 | /** |
||
15 | * Certification path of the AC holder. |
||
16 | * |
||
17 | * @var CertificationPath |
||
18 | */ |
||
19 | protected $_holderPath; |
||
20 | |||
21 | /** |
||
22 | * Certification path of the AC issuer. |
||
23 | * |
||
24 | * @var CertificationPath |
||
25 | */ |
||
26 | protected $_issuerPath; |
||
27 | |||
28 | /** |
||
29 | * Evaluation reference time. |
||
30 | * |
||
31 | * @var \DateTimeImmutable |
||
32 | */ |
||
33 | protected $_evalTime; |
||
34 | |||
35 | /** |
||
36 | * Permitted targets. |
||
37 | * |
||
38 | * @var Target[] |
||
39 | */ |
||
40 | protected $_targets; |
||
41 | |||
42 | /** |
||
43 | * Constructor. |
||
44 | * |
||
45 | * @param CertificationPath $holder_path |
||
46 | * @param CertificationPath $issuer_path |
||
47 | */ |
||
48 | public function __construct(CertificationPath $holder_path, |
||
55 | |||
56 | /** |
||
57 | * Get certification path of the AC's holder. |
||
58 | * |
||
59 | * @return CertificationPath |
||
60 | */ |
||
61 | public function holderPath() { |
||
64 | |||
65 | /** |
||
66 | * Get certification path of the AC's issuer. |
||
67 | * |
||
68 | * @return CertificationPath |
||
69 | */ |
||
70 | public function issuerPath() { |
||
73 | |||
74 | /** |
||
75 | * Get self with given evaluation reference time. |
||
76 | * |
||
77 | * @param \DateTimeImmutable $dt |
||
78 | * @return self |
||
79 | */ |
||
80 | public function withEvaluationTime(\DateTimeImmutable $dt) { |
||
85 | |||
86 | /** |
||
87 | * Get the evaluation reference time. |
||
88 | * |
||
89 | * @return \DateTimeImmutable |
||
90 | */ |
||
91 | public function evaluationTime() { |
||
94 | |||
95 | /** |
||
96 | * Get self with permitted targets. |
||
97 | * |
||
98 | * @param Target ...$targets |
||
99 | * @return self |
||
100 | */ |
||
101 | public function withTargets(Target ...$targets) { |
||
106 | |||
107 | /** |
||
108 | * Get array of permitted targets |
||
109 | * |
||
110 | * @return Target[] |
||
111 | */ |
||
112 | public function targets() { |
||
115 | } |
||
116 |