Class PHPStan\Type\Accessory\AccessoryDecimalIntegerStringType

implements CompoundType, AccessoryType
uses NonArrayTypeTrait, NonObjectTypeTrait, NonIterableTypeTrait, UndecidedComparisonCompoundTypeTrait, NonGenericTypeTrait, NonRemoveableTypeTrait

This accessory type is coupled with Type::isDecimalIntegerString() method. When inverse=false, this represents strings containing decimal integers. These are guaranteed to be cast to an integer in an array key. Examples of constant values covered by this type: "0", "1", "1234", "-1" When inverse=true, this represents strings containing non-decimal integers and other text. These are guaranteed to stay as string in an array key. Examples of constant values covered by this type: "+1", "00", "18E+3", "1.2", "1,3", "foo"

Methods