classOnceSchedule
final class OnceSchedule
implements Schedule
uses Snapshot
Public API: explicitly declared with
@visibility public.The schedule AT timestamp: the event runs once.
Source: https://dev.mysql.com/doc/refman/8.4/en/create-event.html.
$create = (new \SqlSemantics\Platform\MySql\Semantics())->analyze("CREATE EVENT e ON SCHEDULE AT '2030-01-01 00:00:00' DO SELECT 1");
$create->statement->schedule->at->value() // => '2030-01-01 00:00:00'Properties§
public Scalar $atMethods§
public function __construct(public Scalar $at)Parameters
$at | Scalar | The time the event runs |
public function deriveSchedule(Derivation $derivation, Environment $environment): voidDerives the time expression.
Parameters
$derivation | Derivation | |
$environment | Environment |
Calls 1
- method-call Derivation::scalar() line 39
public function render(Output $out): voidWrites AT and the time.
Parameters
$out | Output |
Test cases 1
Calls 1
- method-call Output::keyword() line 47
Test cases 7§
Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.
Dedicated tests 2
Other tests reaching this symbol 5
EventRuleTest::testCreateLeavesTheOptionalClausesAbsentcallsEventRuleTest::testScheduleLowersAtAndEverycallsCreateEventTest::testAHexadecimalCommentIsRejectedcallsCreateEventTest::testANameWithACatalogIsRejectedcallsScheduleTest::providerDeriveScheduleIsImplementedByTheOneTimeAndTheRecurringSchedulecalls