Package dev.frostlake.executor
Class ConditionalDdlOutcome
java.lang.Object
dev.frostlake.executor.ConditionalDdlOutcome
The conditional branch the CURRENT statement's DDL handler took, reported by the handler itself:
the status sentence for
CREATE … IF NOT EXISTS that found its object, and for
DROP … IF EXISTS that did not, depends on what the catalog held a moment BEFORE — a fact
only the handler's own skip branch knows. Held in a ThreadLocal and consumed per statement,
following StatementClock's pattern: one engine serves many sessions, so this must not be
a process-wide setting.-
Method Summary
Modifier and TypeMethodDescriptionstatic voidclear()Clear whatever an earlier statement may have left, before a statement runs.static voidRecord that CREATE … IF NOT EXISTS found the object and created nothing.static voidRecord that DROP … IF EXISTS found nothing to drop.static ConditionalDdlBranchtake()The branch the statement just executed took, consumed — null when it took neither.
-
Method Details
-
createSkipped
public static void createSkipped()Record that CREATE … IF NOT EXISTS found the object and created nothing. -
dropSkipped
public static void dropSkipped()Record that DROP … IF EXISTS found nothing to drop. -
clear
public static void clear()Clear whatever an earlier statement may have left, before a statement runs. -
take
The branch the statement just executed took, consumed — null when it took neither.
-