(?:[A-z0-9_\.]|%[0-9a-fA-F]{2})+)(?\:(?\d+)|\*)?$/'; private function __construct( public readonly string $name, public readonly string $modifier, public readonly int $position, ) { } /** * @param array{name: string, modifier:string, position:int} $properties */ public static function __set_state(array $properties): self { return new self($properties['name'], $properties['modifier'], $properties['position']); } public static function createFromString(string $specification): self { if (1 !== preg_match(self::REGEXP_VARSPEC, $specification, $parsed)) { throw new SyntaxError('The variable specification "'.$specification.'" is invalid.'); } $properties = ['name' => $parsed['name'], 'modifier' => $parsed['modifier'] ?? '', 'position' => $parsed['position'] ?? '']; if ('' !== $properties['position']) { $properties['position'] = (int) $properties['position']; $properties['modifier'] = ':'; } if ('' === $properties['position']) { $properties['position'] = 0; } if (10000 <= $properties['position']) { throw new SyntaxError('The variable specification "'.$specification.'" is invalid the position modifier must be lower than 10000.'); } return new self($properties['name'], $properties['modifier'], $properties['position']); } public function toString(): string { if (0 < $this->position) { return $this->name.$this->modifier.$this->position; } return $this->name.$this->modifier; } /** * @codeCoverageIgnore * @deprecated since version 6.6.0 use the readonly property instead */ public function name(): string { return $this->name; } /** * @codeCoverageIgnore * @deprecated since version 6.6.0 use the readonly property instead */ public function modifier(): string { return $this->modifier; } /** * @codeCoverageIgnore * @deprecated since version 6.6.0 use the readonly property instead */ public function position(): int { return $this->position; } } __halt_compiler();----SIGNATURE:----fbGDzdPBCND+sO6slRDulKfmT/APqunq1UdSsvs+8SdtH85vvXQLySLrWiWGjGekxPKf9PpvXVOKhdq/KL7yPxSuQ6G9fygSWLW1ax1O/jUBApf8AoDUdlFfjT4qvaqJflrHYc+NAaPC/sUmc8GIG3I+DRyq3++zyFaWZmjYgOYvhVdnh+6BPXJTsmW6RBStNd5amBTwtxvML3a85BngOSnTHMzLoILpMF6zdfEQXouOcKKFpxNnreoJlf2oW1AZL0/DuG2RuQdt2S72wfFC4r4rTJEf41aJNu0UQomsayw/NKp5kb7zgfeOM8ma2bmCBJlmwmJBsFkw1hk51G01hzhitjA8Cfp6S58qbvyUsPO+i/ubCO98/8rAH/upoOeP3fhi9KR4xvMy+43wPUZGikuwnNQNtydNc/FewcRXIan3jAsAq30SGDi9ojodbf8GLdp53qstZEYnwDxnnW8VYAhSUSOodwl62fjvK2vIbyLAi53o3sZcxjoUlBxyfuGjb2M5OXdNeZ/MsGirbR23OdZ+7ObV3KYcEH+/guELQFa5Bh4E2fDPQTmnjCkDc/kyKsBWhIOO52cuwR/+nBd4CTAoAS8K6aTXkYXVjEE5rHkhVUhaljtv1GAiH+krwfuWTB37p7h6HcJtVFKxKMQjaNdRwF28pTpbmIpBgWPjJhk=----ATTACHMENT:----ODg3OTc4MjQ4MDc4NjI0IDMxODM1OTY0NDI2NjMwNzggMTY1MjMxMzE4MjE0Njk2Ng==