2020-06-22 08:10:03 +02:00
|
|
|
<?php
|
|
|
|
|
2020-10-13 22:49:03 +02:00
|
|
|
namespace Psalm\Internal\DataFlow;
|
2020-06-22 08:10:03 +02:00
|
|
|
|
2020-08-25 01:28:53 +02:00
|
|
|
/**
|
|
|
|
* @psalm-immutable
|
|
|
|
*/
|
2020-06-22 08:10:03 +02:00
|
|
|
class Path
|
|
|
|
{
|
|
|
|
public $type;
|
|
|
|
|
|
|
|
public $unescaped_taints;
|
|
|
|
|
|
|
|
public $escaped_taints;
|
|
|
|
|
2020-11-10 18:49:42 +01:00
|
|
|
public $length;
|
|
|
|
|
2020-06-22 08:10:03 +02:00
|
|
|
/**
|
2020-06-26 01:12:30 +02:00
|
|
|
* @param ?array<string> $unescaped_taints
|
|
|
|
* @param ?array<string> $escaped_taints
|
2020-06-22 08:10:03 +02:00
|
|
|
*/
|
2021-03-17 06:10:42 +01:00
|
|
|
public function __construct(
|
|
|
|
string $type,
|
|
|
|
int $length,
|
|
|
|
?array $unescaped_taints = null,
|
|
|
|
?array $escaped_taints = null
|
|
|
|
) {
|
2020-06-22 08:10:03 +02:00
|
|
|
$this->type = $type;
|
2020-11-10 18:49:42 +01:00
|
|
|
$this->length = $length;
|
2020-06-22 08:10:03 +02:00
|
|
|
$this->unescaped_taints = $unescaped_taints;
|
|
|
|
$this->escaped_taints = $escaped_taints;
|
|
|
|
}
|
|
|
|
}
|