classServerOption
final class ServerOption
implements Node
uses Snapshot
Public API: explicitly declared with
@visibility public.One option of CREATE SERVER or ALTER SERVER: USER 'name', PORT 3306, ….
Source: https://dev.mysql.com/doc/refman/8.4/en/create-server.html.
$option = new \SqlSemantics\Platform\MySql\Statement\Server\ForeignServer\ServerOption(\SqlSemantics\Platform\MySql\Statement\Server\ForeignServer\ServerOptionKind::Port, new \SqlSemantics\Platform\MySql\Statement\Literal\Numeral('3307'));
$option->value instanceof \SqlSemantics\Platform\MySql\Statement\Literal\Numeral // => trueProperties§
public ServerOptionKind $kindMethods§
public function __construct(public ServerOptionKind $kind, public Text|Numeral $value)Parameters
$kind | ServerOptionKind | The option |
$value | Text|Numeral | A number for PORT, a string for the other options |
Throws
InvalidConstruction When the value does not fit the optionCalls 2
- static-call Check::input() line 36
- class-const ServerOptionKind::Port() line 36
public function render(Output $out): voidTest cases 1§
Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.
Dedicated tests 1
ServerOptionTestcalls
Relations§
Instantiated in 1
Constant reads 2
- class-const SqlSemantics\Platform\MySql\Statement\Server\ForeignServer\AlterServer::__construct() packages/sql-semantics-mysql/src/Statement/Server/ForeignServer/AlterServer.php:44
- class-const SqlSemantics\Platform\MySql\Statement\Server\ForeignServer\CreateServer::__construct() packages/sql-semantics-mysql/src/Statement/Server/ForeignServer/CreateServer.php:49