classNumberOption
final class NumberOption
implements TableOption
uses Snapshot
Public API: explicitly declared with
@visibility public.A table option whose value is a number, or DEFAULT for the options that accept it.
The equals sign between the option and its value is optional and is not kept. Source: https://dev.mysql.com/doc/refman/8.4/en/create-table.html#create-table-options.
$create = (new \SqlSemantics\Platform\MySql\Semantics())->analyze('CREATE TABLE t (a INT) AUTO_INCREMENT = 100');
$create->statement->options[0] instanceof \SqlSemantics\Platform\MySql\Statement\Table\Option\NumberOption // => trueProperties§
public NumberOptionKind $kindpublic Numeral|null $valueMethods§
public function __construct(public NumberOptionKind $kind, public Numeral|null $value)Parameters
$kind | NumberOptionKind | The option |
$value | Numeral|null | The number; null for DEFAULT |
Calls 2
- static-call Check::input() line 35
- method-call NumberOptionKind::defaultable() line 35
public function render(Output $out): voidWrites the option.
Parameters
$out | Output |
Calls 2
- method-call Output::keyword() line 43
- method-call Output::node() line 47
Test cases 3§
Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.