ClassLikeStorage
in package
implements
HasAttributesInterface
uses
CustomMetadataTrait, UnserializeMemoryUsageSuppressionTrait
Table of Contents
Interfaces
Properties
- $abstract : bool
- $aliases : Aliases|null
- Aliases to help Psalm understand constant refs
- $appearing_method_ids : array<lowercase-string, MethodIdentifier>
- $appearing_property_ids : array<string, string>
- $attributes : array<int, AttributeStorage>
- $class_implements : array<lowercase-string, string>
- Interfaces this class implements explicitly and implicitly
- $constants : array<string, ClassConstantStorage>
- $custom_metadata : array<string, _MetadataEntry>
- $declaring_method_ids : array<lowercase-string, MethodIdentifier>
- $declaring_property_ids : array<string, string>
- $declaring_pseudo_method_ids : array<lowercase-string, MethodIdentifier>
- Maps pseudo method names to the original declaring method identifier The key is the method name in lowercase, and the value is the original `MethodIdentifier` instance
- $declaring_yield_fqcn : string|null
- $dependent_classlikes : array<lowercase-string, bool>
- $deprecated : bool
- $description : string|null
- $direct_class_interfaces : array<lowercase-string, string>
- Interfaces this class implements directly
- $direct_interface_parents : array<lowercase-string, string>
- Parent interfaces listed explicitly
- $docblock_issues : array<int, CodeIssue>
- $documenting_method_ids : array<lowercase-string, MethodIdentifier>
- $enforce_template_inheritance : bool
- $enum_cases : array<string, EnumCaseStorage>
- $enum_type : "int"|"string"|null
- $extension_requirement : string|null
- $external_mutation_free : bool
- $final : bool
- $final_from_docblock : bool
- $has_visitor_issues : bool
- $hash : string
- A hash of the source file's name, contents, and this file's modified on date
- $implementation_requirements : array<int, string>
- $inheritable_method_ids : array<lowercase-string, MethodIdentifier>
- $inheritable_property_ids : array<string, string>
- $inheritors : Union|null
- $initialized_properties : array<string, bool>
- $internal : array<int, non-empty-string>
- $invalid_dependencies : array<string, true>
- $is_enum : bool
- $is_interface : bool
- $is_trait : bool
- $location : CodeLocation|null
- $methods : array<lowercase-string, MethodStorage>
- $mixin_declaring_fqcln : string|null
- $mutation_free : bool
- $name : string
- $namedMixins : array<int, TNamedObject>
- $namespace_name_location : CodeLocation|null
- $overridden_method_ids : array<lowercase-string, array<string, MethodIdentifier>>
- Map from lowercase method name to list of declarations in order from parent, to grandparent, to great-grandparent, etc **including traits and interfaces**. Ancestors that don't have their own declaration are skipped.
- $overridden_property_ids : array<string, array<string|int, string>>
- $override_method_visibility : bool
- $override_property_visibility : bool
- $parent_class : string|null
- There can only be one direct parent class
- $parent_classes : array<lowercase-string, string>
- Parent classes
- $parent_interfaces : array<lowercase-string, string>
- Parent interfaces
- $populated : bool
- $potential_declaring_method_ids : array<lowercase-string, array<string, bool>>
- $preserve_constructor_signature : bool
- $properties : array<string, PropertyStorage>
- $pseudo_methods : array<lowercase-string, MethodStorage>
- $pseudo_property_get_types : array<string, Union>
- $pseudo_property_set_types : array<string, Union>
- $pseudo_static_methods : array<lowercase-string, MethodStorage>
- $public_api : bool
- $readonly : bool
- $sealed_methods : bool|null
- $sealed_properties : bool|null
- $specialize_instance : bool
- $stmt_location : CodeLocation|null
- $stubbed : bool
- $suppressed_issues : array<int, string>
- $template_covariants : array<int, bool>|null
- $template_extended_params : array<string, array<string, Union>>|null
- A map of which generic classlikes are extended or implemented by this class or interface.
- $template_type_extends_count : array<string, int>|null
- $template_type_implements_count : array<string, int>|null
- $template_type_uses_count : array<string, int>|null
- $template_types : array<string|int, mixed>|null
- An array holding the class template "as" types.
- $templatedMixins : array<string|int, TTemplateParam>
- $trait_alias_map : array<lowercase-string, lowercase-string>
- $trait_alias_map_cased : array<string, string>
- $trait_final_map : array<lowercase-string, bool>
- $trait_visibility_map : array<string, ClassLikeAnalyzer::VISIBILITY_*>
- $type_aliases : array<string, ClassTypeAlias>
- $used_traits : array<lowercase-string, string>
- $user_defined : bool
- Is this class user-defined
- $yield : Union|null
Methods
- __construct() : mixed
- __unserialize() : void
- getAttributeStorages() : array<int, AttributeStorage>
- Returns a list of AttributeStorages with the same order they appear in the AttributeGroups they come from.
- getClassTemplateTypes() : array<int, Union>
- Get the template constraint types for the class.
- getSuppressedIssuesForTemplateExtendParams() : array<int, string>
- hasAttributeIncludingParents() : bool
- hasSealedMethods() : bool
- hasSealedProperties() : bool
- hasAttribute() : bool
Properties
$abstract
public
bool
$abstract
= false
$aliases
Aliases to help Psalm understand constant refs
public
Aliases|null
$aliases
= null
$appearing_method_ids
public
array<lowercase-string, MethodIdentifier>
$appearing_method_ids
= []
$appearing_property_ids
public
array<string, string>
$appearing_property_ids
= []
$attributes
public
array<int, AttributeStorage>
$attributes
= []
$class_implements
Interfaces this class implements explicitly and implicitly
public
array<lowercase-string, string>
$class_implements
= []
$constants
public
array<string, ClassConstantStorage>
$constants
= []
$custom_metadata
public
array<string, _MetadataEntry>
$custom_metadata
= []
$declaring_method_ids
public
array<lowercase-string, MethodIdentifier>
$declaring_method_ids
= []
$declaring_property_ids
public
array<string, string>
$declaring_property_ids
= []
$declaring_pseudo_method_ids
Maps pseudo method names to the original declaring method identifier The key is the method name in lowercase, and the value is the original `MethodIdentifier` instance
public
array<lowercase-string, MethodIdentifier>
$declaring_pseudo_method_ids
= []
This property contains all pseudo methods declared on ancestors.
$declaring_yield_fqcn
public
string|null
$declaring_yield_fqcn
= null
$dependent_classlikes
public
array<lowercase-string, bool>
$dependent_classlikes
= []
$deprecated
public
bool
$deprecated
= false
$description
public
string|null
$description
= null
$direct_class_interfaces
Interfaces this class implements directly
public
array<lowercase-string, string>
$direct_class_interfaces
= []
$direct_interface_parents
Parent interfaces listed explicitly
public
array<lowercase-string, string>
$direct_interface_parents
= []
$docblock_issues
public
array<int, CodeIssue>
$docblock_issues
= []
$documenting_method_ids
public
array<lowercase-string, MethodIdentifier>
$documenting_method_ids
= []
$enforce_template_inheritance
public
bool
$enforce_template_inheritance
= false
$enum_cases
public
array<string, EnumCaseStorage>
$enum_cases
= []
$enum_type
public
"int"|"string"|null
$enum_type
= null
$extension_requirement
public
string|null
$extension_requirement
= null
$external_mutation_free
public
bool
$external_mutation_free
= false
$final
public
bool
$final
= false
$final_from_docblock
public
bool
$final_from_docblock
= false
$has_visitor_issues
public
bool
$has_visitor_issues
= false
$hash
A hash of the source file's name, contents, and this file's modified on date
public
string
$hash
= ''
$implementation_requirements
public
array<int, string>
$implementation_requirements
= []
$inheritable_method_ids
public
array<lowercase-string, MethodIdentifier>
$inheritable_method_ids
= []
$inheritable_property_ids
public
array<string, string>
$inheritable_property_ids
= []
$inheritors
public
Union|null
$inheritors
= null
$initialized_properties
public
array<string, bool>
$initialized_properties
= []
$internal
public
array<int, non-empty-string>
$internal
= []
$invalid_dependencies
public
array<string, true>
$invalid_dependencies
= []
$is_enum
public
bool
$is_enum
= false
$is_interface
public
bool
$is_interface
= false
$is_trait
public
bool
$is_trait
= false
$location
public
CodeLocation|null
$location
= null
$methods
public
array<lowercase-string, MethodStorage>
$methods
= []
$mixin_declaring_fqcln
public
string|null
$mixin_declaring_fqcln
= null
$mutation_free
public
bool
$mutation_free
= false
$name
public
string
$name
$namedMixins
public
array<int, TNamedObject>
$namedMixins
= []
$namespace_name_location
public
CodeLocation|null
$namespace_name_location
= null
$overridden_method_ids
Map from lowercase method name to list of declarations in order from parent, to grandparent, to great-grandparent, etc **including traits and interfaces**. Ancestors that don't have their own declaration are skipped.
public
array<lowercase-string, array<string, MethodIdentifier>>
$overridden_method_ids
= []
$overridden_property_ids
public
array<string, array<string|int, string>>
$overridden_property_ids
= []
$override_method_visibility
public
bool
$override_method_visibility
= false
$override_property_visibility
public
bool
$override_property_visibility
= false
$parent_class
There can only be one direct parent class
public
string|null
$parent_class
= null
$parent_classes
Parent classes
public
array<lowercase-string, string>
$parent_classes
= []
$parent_interfaces
Parent interfaces
public
array<lowercase-string, string>
$parent_interfaces
= []
$populated
public
bool
$populated
= false
$potential_declaring_method_ids
public
array<lowercase-string, array<string, bool>>
$potential_declaring_method_ids
= []
$preserve_constructor_signature
public
bool
$preserve_constructor_signature
= false
$properties
public
array<string, PropertyStorage>
$properties
= []
$pseudo_methods
public
array<lowercase-string, MethodStorage>
$pseudo_methods
= []
$pseudo_property_get_types
public
array<string, Union>
$pseudo_property_get_types
= []
$pseudo_property_set_types
public
array<string, Union>
$pseudo_property_set_types
= []
$pseudo_static_methods
public
array<lowercase-string, MethodStorage>
$pseudo_static_methods
= []
$public_api
public
bool
$public_api
= false
$readonly
public
bool
$readonly
= false
$sealed_methods
public
bool|null
$sealed_methods
= null
$sealed_properties
public
bool|null
$sealed_properties
= null
$specialize_instance
public
bool
$specialize_instance
= false
$stmt_location
public
CodeLocation|null
$stmt_location
= null
$stubbed
public
bool
$stubbed
= false
$suppressed_issues
public
array<int, string>
$suppressed_issues
= []
$template_covariants
public
array<int, bool>|null
$template_covariants
= null
$template_extended_params
A map of which generic classlikes are extended or implemented by this class or interface.
public
array<string, array<string, Union>>|null
$template_extended_params
= null
The annotation "@extends Traversable<SomeClass, SomeOtherClass>" would generate an entry of
[ "Traversable" => [ "TKey" => new Union([new TNamedObject("SomeClass")]), "TValue" => new Union([new TNamedObject("SomeOtherClass")]) ] ]
$template_type_extends_count
public
array<string, int>|null
$template_type_extends_count
= null
$template_type_implements_count
public
array<string, int>|null
$template_type_implements_count
= null
$template_type_uses_count
public
array<string, int>|null
$template_type_uses_count
= null
$template_types
An array holding the class template "as" types.
public
array<string|int, mixed>|null
$template_types
= null
It's the de-facto list of all templates on a given class.
The name of the template is the first key. The nested array is keyed by the defining class (i.e. the same as the class name). This allows operations with the same-named template defined across multiple classes to not run into trouble.
$templatedMixins
public
array<string|int, TTemplateParam>
$templatedMixins
= []
$trait_alias_map
public
array<lowercase-string, lowercase-string>
$trait_alias_map
= []
$trait_alias_map_cased
public
array<string, string>
$trait_alias_map_cased
= []
$trait_final_map
public
array<lowercase-string, bool>
$trait_final_map
= []
$trait_visibility_map
public
array<string, ClassLikeAnalyzer::VISIBILITY_*>
$trait_visibility_map
= []
$type_aliases
public
array<string, ClassTypeAlias>
$type_aliases
= []
$used_traits
public
array<lowercase-string, string>
$used_traits
= []
$user_defined
Is this class user-defined
public
bool
$user_defined
= false
$yield
public
Union|null
$yield
= null
Methods
__construct()
public
__construct(string $name) : mixed
Parameters
- $name : string
__unserialize()
public
__unserialize(array<string|int, mixed> $properties) : void
Parameters
- $properties : array<string|int, mixed>
getAttributeStorages()
Returns a list of AttributeStorages with the same order they appear in the AttributeGroups they come from.
public
getAttributeStorages() : array<int, AttributeStorage>
Return values
array<int, AttributeStorage>getClassTemplateTypes()
Get the template constraint types for the class.
public
getClassTemplateTypes() : array<int, Union>
Return values
array<int, Union>getSuppressedIssuesForTemplateExtendParams()
public
getSuppressedIssuesForTemplateExtendParams() : array<int, string>
Return values
array<int, string>hasAttributeIncludingParents()
public
hasAttributeIncludingParents(string $fq_class_name, Codebase $codebase) : bool
Parameters
- $fq_class_name : string
- $codebase : Codebase
Return values
boolhasSealedMethods()
public
hasSealedMethods(Config $config) : bool
Parameters
- $config : Config
Return values
boolhasSealedProperties()
public
hasSealedProperties(Config $config) : bool
Parameters
- $config : Config
Return values
boolhasAttribute()
private
hasAttribute(string $fq_class_name) : bool
Parameters
- $fq_class_name : string