packages/sql-semantics-mysql/resources/models/Choice/TrgEventChoice_c6bd7e6b.php

1<?php
2
3declare(strict_types=1);
4
5namespace SqlSemantics\Statement\Model\MySql\Choice;
6
7/**
8 * The trg_event SQL value; generated by bin/build-models.php.
9 *
10 * @visibility public
11 * @example Accept a structured SQL value
12 *     $write = static fn (\SqlSemantics\Statement\Model\MySql\Choice\TrgEventChoice_c6bd7e6b $value): string => \SqlSemantics\Statement\Writer::render($value);
13 *     $write instanceof \Closure // => true
14 */
15enum TrgEventChoice_c6bd7e6b: string implements \SqlSemantics\Statement\Model\MySql\Role\TrgEventForm
16{
17    case UseInsert_014413c2 = 'INSERT';
18    case UseUpdate_6cb78ab1 = 'UPDATE';
19    case UseDelete_65daeb37 = 'DELETE';
20
21    /**
22     * Writes the selected SQL option.
23     */
24    public function write(\SqlSemantics\Statement\Writer $writer): void
25    {
26        foreach (explode(' ', $this->value) as $word) {
27            $writer->append($word);
28        }
29    }
30}
31