2016-12-30 18:41:14 +01:00
|
|
|
<?php
|
|
|
|
namespace Psalm\Storage;
|
|
|
|
|
2017-02-08 06:28:26 +01:00
|
|
|
use Psalm\CodeLocation;
|
2016-12-30 18:41:14 +01:00
|
|
|
use Psalm\Type;
|
|
|
|
|
|
|
|
class ClassLikeStorage
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
* A lookup table for public class constants
|
|
|
|
*
|
|
|
|
* @var array<string, Type\Union>
|
|
|
|
*/
|
|
|
|
public $public_class_constants = [];
|
|
|
|
|
|
|
|
/**
|
|
|
|
* A lookup table for protected class constants
|
|
|
|
*
|
|
|
|
* @var array<string, Type\Union>
|
|
|
|
*/
|
|
|
|
public $protected_class_constants = [];
|
|
|
|
|
|
|
|
/**
|
|
|
|
* A lookup table for private class constants
|
|
|
|
*
|
|
|
|
* @var array<string, Type\Union>
|
|
|
|
*/
|
|
|
|
public $private_class_constants = [];
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @var bool
|
|
|
|
*/
|
2017-07-25 22:11:02 +02:00
|
|
|
public $populated = false;
|
2016-12-30 18:41:14 +01:00
|
|
|
|
2018-02-01 05:27:25 +01:00
|
|
|
/**
|
|
|
|
* @var bool
|
|
|
|
*/
|
|
|
|
public $stubbed = false;
|
|
|
|
|
2017-01-02 21:31:18 +01:00
|
|
|
/**
|
2017-07-09 03:19:16 +02:00
|
|
|
* @var bool
|
|
|
|
*/
|
|
|
|
public $all_properties_set_in_constructor = false;
|
|
|
|
|
|
|
|
/**
|
2017-02-10 02:35:17 +01:00
|
|
|
* @var bool
|
|
|
|
*/
|
|
|
|
public $deprecated = false;
|
|
|
|
|
2017-11-17 02:47:58 +01:00
|
|
|
/**
|
|
|
|
* @var bool
|
|
|
|
*/
|
|
|
|
public $sealed_properties = false;
|
|
|
|
|
2018-04-22 06:40:30 +02:00
|
|
|
/**
|
|
|
|
* @var bool
|
|
|
|
*/
|
|
|
|
public $sealed_methods = false;
|
|
|
|
|
2017-09-13 17:32:13 +02:00
|
|
|
/**
|
|
|
|
* @var array<int, string>
|
|
|
|
*/
|
|
|
|
public $suppressed_issues = [];
|
|
|
|
|
2017-02-10 02:35:17 +01:00
|
|
|
/**
|
|
|
|
* @var string
|
2017-01-02 21:31:18 +01:00
|
|
|
*/
|
2017-02-08 06:28:26 +01:00
|
|
|
public $name;
|
2017-01-02 21:31:18 +01:00
|
|
|
|
2016-12-30 18:41:14 +01:00
|
|
|
/**
|
|
|
|
* Is this class user-defined
|
|
|
|
*
|
|
|
|
* @var bool
|
|
|
|
*/
|
2017-01-18 06:33:48 +01:00
|
|
|
public $user_defined = false;
|
2016-12-30 18:41:14 +01:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Interfaces this class implements
|
|
|
|
*
|
2017-07-25 22:11:02 +02:00
|
|
|
* @var array<string, string>
|
2016-12-30 18:41:14 +01:00
|
|
|
*/
|
|
|
|
public $class_implements = [];
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Parent interfaces
|
|
|
|
*
|
2017-07-25 22:11:02 +02:00
|
|
|
* @var array<string, string>
|
2016-12-30 18:41:14 +01:00
|
|
|
*/
|
|
|
|
public $parent_interfaces = [];
|
|
|
|
|
2017-01-02 21:31:18 +01:00
|
|
|
/**
|
2018-02-19 19:06:35 +01:00
|
|
|
* Parent classes
|
2017-01-02 21:31:18 +01:00
|
|
|
*
|
2018-02-04 00:52:35 +01:00
|
|
|
* @var array<string, string>
|
2017-01-02 21:31:18 +01:00
|
|
|
*/
|
|
|
|
public $parent_classes = [];
|
|
|
|
|
2016-12-30 18:41:14 +01:00
|
|
|
/**
|
2017-02-08 06:28:26 +01:00
|
|
|
* @var CodeLocation|null
|
2016-12-30 18:41:14 +01:00
|
|
|
*/
|
2017-02-08 06:28:26 +01:00
|
|
|
public $location;
|
2017-01-20 05:45:21 +01:00
|
|
|
|
2017-01-20 06:10:10 +01:00
|
|
|
/**
|
|
|
|
* @var bool
|
|
|
|
*/
|
|
|
|
public $abstract = false;
|
|
|
|
|
2017-11-30 05:46:56 +01:00
|
|
|
/**
|
|
|
|
* @var bool
|
|
|
|
*/
|
|
|
|
public $final = false;
|
|
|
|
|
2016-12-30 18:41:14 +01:00
|
|
|
/**
|
2017-07-25 22:11:02 +02:00
|
|
|
* @var array<string, string>
|
2016-12-30 18:41:14 +01:00
|
|
|
*/
|
|
|
|
public $used_traits = [];
|
2016-12-30 21:53:35 +01:00
|
|
|
|
2017-07-25 22:11:02 +02:00
|
|
|
/**
|
|
|
|
* @var array<string, string>
|
|
|
|
*/
|
|
|
|
public $trait_alias_map = [];
|
|
|
|
|
2017-06-30 07:24:45 +02:00
|
|
|
/**
|
|
|
|
* @var bool
|
|
|
|
*/
|
|
|
|
public $is_trait = false;
|
|
|
|
|
2018-02-19 06:27:39 +01:00
|
|
|
/**
|
|
|
|
* @var bool
|
|
|
|
*/
|
|
|
|
public $is_interface = false;
|
|
|
|
|
2016-12-30 21:53:35 +01:00
|
|
|
/**
|
|
|
|
* @var array<string, MethodStorage>
|
|
|
|
*/
|
|
|
|
public $methods = [];
|
|
|
|
|
2018-04-22 04:13:10 +02:00
|
|
|
/**
|
|
|
|
* @var array<string, FunctionLikeStorage>
|
|
|
|
*/
|
|
|
|
public $pseudo_methods = [];
|
|
|
|
|
2016-12-30 21:53:35 +01:00
|
|
|
/**
|
|
|
|
* @var array<string, string>
|
|
|
|
*/
|
|
|
|
public $declaring_method_ids = [];
|
|
|
|
|
2016-12-31 17:49:04 +01:00
|
|
|
/**
|
|
|
|
* @var array<string, string>
|
|
|
|
*/
|
|
|
|
public $appearing_method_ids = [];
|
|
|
|
|
2016-12-30 21:53:35 +01:00
|
|
|
/**
|
|
|
|
* @var array<string, array<string>>
|
|
|
|
*/
|
|
|
|
public $overridden_method_ids = [];
|
2017-01-02 01:09:17 +01:00
|
|
|
|
2018-01-26 17:50:29 +01:00
|
|
|
/**
|
|
|
|
* @var array<string, array<string>>
|
|
|
|
*/
|
|
|
|
public $interface_method_ids = [];
|
|
|
|
|
2017-11-09 03:27:23 +01:00
|
|
|
/**
|
|
|
|
* @var array<string, string>
|
|
|
|
*/
|
|
|
|
public $inheritable_method_ids = [];
|
|
|
|
|
2017-01-02 01:09:17 +01:00
|
|
|
/**
|
|
|
|
* @var array<string, PropertyStorage>
|
|
|
|
*/
|
|
|
|
public $properties = [];
|
|
|
|
|
2017-05-05 00:35:05 +02:00
|
|
|
/**
|
|
|
|
* @var array<string, Type\Union>
|
|
|
|
*/
|
2017-05-05 17:20:05 +02:00
|
|
|
public $pseudo_property_set_types = [];
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @var array<string, Type\Union>
|
|
|
|
*/
|
|
|
|
public $pseudo_property_get_types = [];
|
2017-05-05 00:35:05 +02:00
|
|
|
|
2017-01-02 01:09:17 +01:00
|
|
|
/**
|
|
|
|
* @var array<string, string>
|
|
|
|
*/
|
|
|
|
public $declaring_property_ids = [];
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @var array<string, string>
|
|
|
|
*/
|
|
|
|
public $appearing_property_ids = [];
|
2017-01-19 19:11:45 +01:00
|
|
|
|
|
|
|
/**
|
|
|
|
* @var array<string, string>
|
|
|
|
*/
|
|
|
|
public $inheritable_property_ids = [];
|
2017-02-10 02:35:17 +01:00
|
|
|
|
2018-03-04 18:24:50 +01:00
|
|
|
/**
|
|
|
|
* @var array<string, array<string>>
|
|
|
|
*/
|
|
|
|
public $overridden_property_ids = [];
|
|
|
|
|
2017-02-10 02:35:17 +01:00
|
|
|
/**
|
|
|
|
* @var array<string, string>|null
|
|
|
|
*/
|
|
|
|
public $template_types;
|
2017-02-27 05:09:18 +01:00
|
|
|
|
2018-05-28 23:26:43 +02:00
|
|
|
/**
|
|
|
|
* @var array<string, string>|null
|
|
|
|
*/
|
|
|
|
public $template_parents;
|
|
|
|
|
2017-02-27 05:09:18 +01:00
|
|
|
/**
|
2017-02-28 00:24:20 +01:00
|
|
|
* @var array<string, array<int, CodeLocation>>|null
|
2017-02-27 05:09:18 +01:00
|
|
|
*/
|
|
|
|
public $referencing_locations;
|
2017-12-27 12:27:59 +01:00
|
|
|
|
|
|
|
/**
|
|
|
|
* @var array<string, bool>
|
|
|
|
*/
|
|
|
|
public $initialized_properties = [];
|
2018-02-14 19:34:16 +01:00
|
|
|
|
|
|
|
/**
|
|
|
|
* @var array<string>
|
|
|
|
*/
|
|
|
|
public $invalid_dependencies = [];
|
2018-02-19 06:27:39 +01:00
|
|
|
|
|
|
|
/**
|
|
|
|
* A hash of the source file's name, contents, and this file's modified on date
|
|
|
|
*
|
|
|
|
* @var string
|
|
|
|
*/
|
|
|
|
public $hash = '';
|
2018-05-03 17:38:27 +02:00
|
|
|
|
|
|
|
/**
|
|
|
|
* @param string $name
|
|
|
|
*/
|
|
|
|
public function __construct($name)
|
|
|
|
{
|
|
|
|
$this->name = $name;
|
|
|
|
}
|
2016-12-30 18:41:14 +01:00
|
|
|
}
|