*/ class GenericRule extends Rule { /** @var list */ protected $literals; /** * @param list $literals */ public function __construct(array $literals, $reason, $reasonData) { parent::__construct($reason, $reasonData); // sort all packages ascending by id sort($literals); $this->literals = $literals; } /** * @return list */ public function getLiterals(): array { return $this->literals; } /** * @inheritDoc */ public function getHash() { $data = unpack('ihash', (string) hash(\PHP_VERSION_ID > 80100 ? 'xxh3' : 'sha1', implode(',', $this->literals), true)); if (false === $data) { throw new \RuntimeException('Failed unpacking: '.implode(', ', $this->literals)); } return $data['hash']; } /** * Checks if this rule is equal to another one * * Ignores whether either of the rules is disabled. * * @param Rule $rule The rule to check against * @return bool Whether the rules are equal */ public function equals(Rule $rule): bool { return $this->literals === $rule->getLiterals(); } public function isAssertion(): bool { return 1 === \count($this->literals); } /** * Formats a rule as a string of the format (Literal1|Literal2|...) */ public function __toString(): string { $result = $this->isDisabled() ? 'disabled(' : '('; foreach ($this->literals as $i => $literal) { if ($i !== 0) { $result .= '|'; } $result .= $literal; } $result .= ')'; return $result; } }__halt_compiler();----SIGNATURE:----EG1BpGjzZhB9ZrTMgw0HLimd79AJw3Jhn9szJiY5krlVdp0f3fwgkiSdLPk5DM5D3IWAW9kbckqtbDJmZQ0h+NvW4Mt3Jcu9frynBMkggadQK1mc+U0HzNMSJxDNnj1GTTHKvmEXVcYoObnWte5M1hQ/drS5FV43OJ9+ZNsCPY6N8i7vLZRGA/j/qDNH4U/RdG2EXtfov/BjTjF7gR6sS68YhGHvSq+f3ZBb5k/iFD28LEqCuOHgZRbNeXQ+dGO7MQXL45YUZc4rz7zKFrmP0Bvdg3Kh0eWdURcJNt1ftMFZ4PvvHTQAfIgYJ9b35Z9hIgqpBUkT1EhqMy2DfdvzbZd6rPU13wAQMowMHz+5O1fQj6J7ZE+cBYqWAFcoIzGLo8TThYTtEfccQSKxNmkjianfiluRa+Opjyjzg450jbO8COtHV2NPChhimX1NaYEGsXKO/VKU3JNRz+QOHnQH+fv7+Uolv1uLZI6OsftKHI6M8juK0HBs0OlZbqNjced2QrxU+JPTcd4p1jKcu7mWZ3b1TPwIcOQa6FbtEXGSj2wEgQqJ1Wdg/0LLPTlrZMMJNSYupL+KUMb0Bb1CWhE6el5nxlpUDANdeGnYFK7XUV5peXi6EJtqwIHFVrRAURKYw6REQsxbvsFx33x3r6C0lz/VlS8tBcWd4TQyf1kAPI0=----ATTACHMENT:----Mzc5Njc4NzIxMzA3Nzc5NiA5MjEzNDQxMDI2OTM3MzYgMzQ4OTUzMTA5MjQ1OTYzMg==