1: <?php declare(strict_types = 1);
2:
3: namespace PHPStan\Node;
4:
5: use Override;
6: use PhpParser\NodeAbstract;
7: use PHPStan\Analyser\StatementExitPoint;
8:
9: /**
10: * @api
11: */
12: final class FinallyExitPointsNode extends NodeAbstract implements VirtualNode
13: {
14:
15: /**
16: * @param StatementExitPoint[] $finallyExitPoints
17: * @param StatementExitPoint[] $tryCatchExitPoints
18: */
19: public function __construct(private array $finallyExitPoints, private array $tryCatchExitPoints)
20: {
21: parent::__construct([]);
22: }
23:
24: /**
25: * @return StatementExitPoint[]
26: */
27: public function getFinallyExitPoints(): array
28: {
29: return $this->finallyExitPoints;
30: }
31:
32: /**
33: * @return StatementExitPoint[]
34: */
35: public function getTryCatchExitPoints(): array
36: {
37: return $this->tryCatchExitPoints;
38: }
39:
40: #[Override]
41: public function getType(): string
42: {
43: return 'PHPStan_Node_FinallyExitPointsNode';
44: }
45:
46: /**
47: * @return string[]
48: */
49: #[Override]
50: public function getSubNodeNames(): array
51: {
52: return [];
53: }
54:
55: }
56: