2016-12-30 18:41:14 +01:00
|
|
|
<?php
|
|
|
|
namespace Psalm\Storage;
|
|
|
|
|
2019-06-30 03:32:26 +02:00
|
|
|
use Psalm\Aliases;
|
|
|
|
|
2016-12-30 18:41:14 +01:00
|
|
|
class FileStorage
|
|
|
|
{
|
2019-02-24 22:21:28 +01:00
|
|
|
use CustomMetadataTrait;
|
|
|
|
|
2016-12-30 18:41:14 +01:00
|
|
|
/**
|
2020-02-15 02:54:26 +01:00
|
|
|
* @var array<lowercase-string, string>
|
2016-12-30 18:41:14 +01:00
|
|
|
*/
|
2018-02-19 06:27:39 +01:00
|
|
|
public $classlikes_in_file = [];
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @var array<string>
|
|
|
|
*/
|
|
|
|
public $referenced_classlikes = [];
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @var array<string>
|
|
|
|
*/
|
|
|
|
public $required_classes = [];
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @var array<string>
|
|
|
|
*/
|
|
|
|
public $required_interfaces = [];
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @var bool
|
|
|
|
*/
|
|
|
|
public $has_trait = false;
|
2016-12-31 00:08:07 +01:00
|
|
|
|
2017-07-25 22:11:02 +02:00
|
|
|
/** @var string */
|
|
|
|
public $file_path;
|
|
|
|
|
2016-12-31 00:08:07 +01:00
|
|
|
/**
|
2017-07-28 16:42:30 +02:00
|
|
|
* @var array<string, FunctionLikeStorage>
|
2016-12-31 00:08:07 +01:00
|
|
|
*/
|
|
|
|
public $functions = [];
|
2017-07-25 22:11:02 +02:00
|
|
|
|
|
|
|
/** @var array<string, string> */
|
|
|
|
public $declaring_function_ids = [];
|
|
|
|
|
2017-07-28 16:42:30 +02:00
|
|
|
/**
|
|
|
|
* @var array<string, \Psalm\Type\Union>
|
|
|
|
*/
|
|
|
|
public $constants = [];
|
|
|
|
|
|
|
|
/** @var array<string, string> */
|
|
|
|
public $declaring_constants = [];
|
|
|
|
|
2017-07-25 22:11:02 +02:00
|
|
|
/** @var array<string, string> */
|
2018-05-30 18:23:53 +02:00
|
|
|
public $required_file_paths = [];
|
|
|
|
|
|
|
|
/** @var array<string, string> */
|
|
|
|
public $required_by_file_paths = [];
|
2017-07-25 22:11:02 +02:00
|
|
|
|
|
|
|
/** @var bool */
|
|
|
|
public $populated = false;
|
2018-02-19 06:27:39 +01:00
|
|
|
|
|
|
|
/** @var bool */
|
|
|
|
public $deep_scan = false;
|
|
|
|
|
2018-05-23 05:38:27 +02:00
|
|
|
/** @var bool */
|
|
|
|
public $has_extra_statements = false;
|
|
|
|
|
2018-02-19 06:27:39 +01:00
|
|
|
/**
|
|
|
|
* @var string
|
|
|
|
*/
|
|
|
|
public $hash = '';
|
2018-05-03 17:38:27 +02:00
|
|
|
|
2018-05-29 16:13:26 +02:00
|
|
|
/**
|
|
|
|
* @var bool
|
|
|
|
*/
|
|
|
|
public $has_visitor_issues = false;
|
|
|
|
|
2018-11-01 22:03:08 +01:00
|
|
|
/**
|
|
|
|
* @var bool
|
|
|
|
*/
|
|
|
|
public $has_docblock_issues = false;
|
|
|
|
|
2018-09-24 19:08:23 +02:00
|
|
|
/**
|
2019-06-23 05:30:40 +02:00
|
|
|
* @var array<string, array<int, array{0: string, 1: int}>>
|
2018-09-24 19:08:23 +02:00
|
|
|
*/
|
|
|
|
public $type_aliases = [];
|
|
|
|
|
2018-11-29 06:46:34 +01:00
|
|
|
/**
|
2020-02-15 02:54:26 +01:00
|
|
|
* @var array<lowercase-string, string>
|
2018-11-29 06:46:34 +01:00
|
|
|
*/
|
|
|
|
public $classlike_aliases = [];
|
|
|
|
|
2019-06-30 03:32:26 +02:00
|
|
|
/** @var ?Aliases */
|
|
|
|
public $aliases;
|
|
|
|
|
|
|
|
/** @var Aliases[] */
|
|
|
|
public $namespace_aliases = [];
|
|
|
|
|
2018-05-03 17:38:27 +02:00
|
|
|
/**
|
|
|
|
* @param string $file_path
|
|
|
|
*/
|
|
|
|
public function __construct($file_path)
|
|
|
|
{
|
|
|
|
$this->file_path = $file_path;
|
|
|
|
}
|
2016-12-30 18:41:14 +01:00
|
|
|
}
|