final class Numeral
    implements Node
    uses Snapshot
Public API: explicitly declared with @visibility public.

A number at a position that is not an expression: an option value, a count, a size, an identifier of a thread or server.

The digits are kept exactly. The grammar also accepts a hexadecimal literal at these positions, and at some of them a decimal or floating number that the server then rejects; each is kept as written. Source: https://dev.mysql.com/doc/refman/8.4/en/number-literals.html.

Holding the exact text of a numberdoctest
$number = new \SqlSemantics\Platform\MySql\Statement\Literal\Numeral('007');
    [$number->text, $number->hexadecimal] // => ['007', false]

Properties§

public string $text
public bool $hexadecimal = false

Methods§

public function __construct(public string $text, public bool $hexadecimal = false)

Parameters

$textstringThe number exactly as written, or the digits of a hexadecimal literal
$hexadecimalboolWhether the text is the digits of a hexadecimal literal
Calls 2
public function render(Output $out): void

Test cases 57§

Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.

Dedicated tests 6
Other tests reaching this symbol 51

Relations§

Instantiated in 2
Constant reads 2
Type checks 3
Type declarations 77