001package gudusoft.gsqlparser.lineage2.contract;
002
003import gudusoft.gsqlparser.TBaseType;
004
005/**
006 * Version constants of the lineage2 contract (lineage2-contract.md §10).
007 *
008 * <p>Internal API: not part of the public gsqlparser surface.
009 */
010public final class ContractVersions {
011
012    /**
013     * Current semantic-layer contract version. Carries the {@code -draft}
014     * suffix until the end-of-M2 freeze; anything in the semantic layer may
015     * change while drafted.
016     */
017    public static final String CONTRACT_VERSION = "0.9.1-draft";
018
019    /**
020     * The {@code engineVersion} document field: gsqlparser version plus the
021     * lineage2 build (contract §2). Implemented as a method so the value
022     * tracks {@link TBaseType#versionid} at runtime rather than being
023     * compile-time inlined into consumers.
024     */
025    public static String engineVersion() {
026        return TBaseType.versionid + "+lineage2-" + CONTRACT_VERSION;
027    }
028
029    private ContractVersions() {
030        // constants only — no instances
031    }
032}