@prisma-next/framework-components 0.5.0-dev.7 → 0.5.0-dev.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -10,6 +10,7 @@ Framework component types, authoring logic, control stack assembly, and emission
10
10
 
11
11
  - **Component types** (`./components`): Base descriptor and instance interfaces for framework components (family, target, adapter, driver, extension), pack refs, and type renderer system
12
12
  - **Authoring types** (`./authoring`): Declarative authoring contribution types, template resolution, and validation for type constructors and field presets
13
+ - **Codec base interface** (`./codec`): The cross-family `Codec` base type that SQL `Codec` and Mongo `MongoCodec` extend
13
14
  - **Control stack** (`./control`): Assembly functions that combine component descriptors into a unified `ControlStack` with derived state (codec imports, renderers, authoring contributions)
14
15
  - **Emission SPI** (`./emission`): Types for the emission pipeline — `TargetFamilyHook`, `ValidationContext`, `GenerateContractTypesOptions`, `TypeRenderEntry`, `TypeRenderer`, `ParameterizedCodecDescriptor`, and related types
15
16
  - **Execution types** (`./execution`): Execution-plane stack and instance interfaces
@@ -19,10 +20,20 @@ Framework component types, authoring logic, control stack assembly, and emission
19
20
  ```typescript
20
21
  import { ComponentMetadata, FamilyDescriptor, normalizeRenderer } from '@prisma-next/framework-components/components';
21
22
  import { AuthoringContributions, instantiateAuthoringTypeConstructor } from '@prisma-next/framework-components/authoring';
23
+ import type { Codec } from '@prisma-next/framework-components/codec';
22
24
  import { createControlStack, ControlStack } from '@prisma-next/framework-components/control';
23
25
  import type { EmissionSpi } from '@prisma-next/framework-components/emission';
24
26
  ```
25
27
 
28
+ ## `Codec` interface
29
+
30
+ The base `Codec` interface lands on the seam between **query-time** methods (per-row, IO-relevant) and **build-time** methods (per-contract-load):
31
+
32
+ - Query-time: `encode(value): Promise<TWire>` and `decode(wire): Promise<TInput>` are required and **Promise-returning at the public boundary**, regardless of whether the codec body is synchronous or asynchronous. Family factories (`codec()` for SQL, `mongoCodec()` for Mongo) accept either sync or async author functions and lift sync ones to Promise-shaped methods, so authors write whichever shape is natural per method without annotations.
33
+ - Build-time: `encodeJson`, `decodeJson`, and the optional `renderOutputType` are **synchronous** so `validateContract` and client construction stay synchronous.
34
+
35
+ There is no `runtime` / `kind` / equivalent async marker on the interface and no `TRuntime` generic. The runtime always awaits the query-time methods. See [ADR 204 — Single-Path Async Codec Runtime](../../../../../docs/architecture%20docs/adrs/ADR%20204%20-%20Single-Path%20Async%20Codec%20Runtime.md) for the full design.
36
+
26
37
  ## Why SPI types live here (dependency inversion)
27
38
 
28
39
  This package sits in the **core** layer — below the tooling layer where family-specific emitters and control implementations live. SPI interfaces like `EmissionSpi` define the contract between framework orchestration code (control-plane emission, CLI) and family-specific implementations (SQL emitter, Mongo emitter).
@@ -0,0 +1,58 @@
1
+ import { JsonValue } from "@prisma-next/contract/types";
2
+
3
+ //#region src/codec-types.d.ts
4
+ type CodecTrait = 'equality' | 'order' | 'boolean' | 'numeric' | 'textual';
5
+ /**
6
+ * A codec is the contract between an application value and its on-wire and
7
+ * on-contract-disk representations.
8
+ *
9
+ * The author's mental model is two JS-side types — `TInput` (the
10
+ * application JS type) and `TWire` (the database driver wire format) —
11
+ * plus `JsonValue` for build-time contract artifacts. The codec translates
12
+ * `TInput` to `TWire` on writes and back on reads, and to/from `JsonValue`
13
+ * during contract emission and loading.
14
+ *
15
+ * Three representations participate:
16
+ * - **Input** (`TInput`): the JS type at the application boundary.
17
+ * - **Wire** (`TWire`): the format exchanged with the database driver.
18
+ * - **JSON** (`JsonValue`): a JSON-safe form used in contract artifacts.
19
+ *
20
+ * Codec methods split into two groups:
21
+ *
22
+ * - **Query-time** methods (`encode`, `decode`) run per row/parameter at the
23
+ * IO boundary; they are required and Promise-returning. The per-family
24
+ * codec factory accepts sync or async author functions and lifts sync
25
+ * ones to Promise-shaped methods automatically.
26
+ * - **Build-time** methods (`encodeJson`, `decodeJson`, `renderOutputType`)
27
+ * run when the contract is serialized, loaded, or when client types are
28
+ * emitted. They stay synchronous so contract validation and client
29
+ * construction are synchronous.
30
+ *
31
+ * Target-family codec interfaces extend this base with target-shaped
32
+ * metadata.
33
+ */
34
+ interface Codec<Id extends string = string, TTraits extends readonly CodecTrait[] = readonly CodecTrait[], TWire = unknown, TInput = unknown> {
35
+ /** Unique codec identifier in `namespace/name@version` format (e.g. `pg/timestamptz@1`). */
36
+ readonly id: Id;
37
+ /** Database-native type names this codec handles (e.g. `['timestamptz']`). */
38
+ readonly targetTypes: readonly string[];
39
+ /** Semantic traits for operator gating (e.g. equality, order, numeric). */
40
+ readonly traits?: TTraits;
41
+ /** Converts a JS value to the wire format expected by the database driver. Always Promise-returning at the boundary. */
42
+ encode(value: TInput): Promise<TWire>;
43
+ /** Converts a wire value from the database driver into the JS application type. Always Promise-returning at the boundary. */
44
+ decode(wire: TWire): Promise<TInput>;
45
+ /** Converts a JS value to a JSON-safe representation for contract serialization. Synchronous; called during contract emission. */
46
+ encodeJson(value: TInput): JsonValue;
47
+ /** Converts a JSON representation back to the JS input type. Synchronous; called during contract loading via `validateContract`. */
48
+ decodeJson(json: JsonValue): TInput;
49
+ /** Produces the TypeScript output type expression for a field given its `typeParams`. Synchronous; used during contract.d.ts emission. */
50
+ renderOutputType?(typeParams: Record<string, unknown>): string | undefined;
51
+ }
52
+ interface CodecLookup {
53
+ get(id: string): Codec | undefined;
54
+ }
55
+ declare const emptyCodecLookup: CodecLookup;
56
+ //#endregion
57
+ export { emptyCodecLookup as i, CodecLookup as n, CodecTrait as r, Codec as t };
58
+ //# sourceMappingURL=codec-types-DQ1Agjom.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"codec-types-DQ1Agjom.d.mts","names":[],"sources":["../src/codec-types.ts"],"sourcesContent":[],"mappings":";;;KAEY,UAAA;;AAAZ;AA+BA;;;;;;;;;;;;;;;;;AAwBA;AAIA;;;;;;;;;UA5BiB,2DAEU,wBAAwB;;eAKpC;;;;oBAIK;;gBAEJ,SAAS,QAAQ;;eAElB,QAAQ,QAAQ;;oBAEX,SAAS;;mBAEV,YAAY;;gCAEC;;UAGf,WAAA;mBACE;;cAGN,kBAAkB"}
package/dist/codec.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- import { i as emptyCodecLookup, n as CodecLookup, r as CodecTrait, t as Codec } from "./codec-types-B58nCJiu.mjs";
1
+ import { i as emptyCodecLookup, n as CodecLookup, r as CodecTrait, t as Codec } from "./codec-types-DQ1Agjom.mjs";
2
2
  export { type Codec, type CodecLookup, type CodecTrait, emptyCodecLookup };
@@ -1 +1 @@
1
- {"version":3,"file":"codec.mjs","names":["emptyCodecLookup: CodecLookup"],"sources":["../src/codec-types.ts"],"sourcesContent":["import type { JsonValue } from '@prisma-next/contract/types';\n\nexport type CodecTrait = 'equality' | 'order' | 'boolean' | 'numeric' | 'textual';\n\n/**\n * Base codec interface for all target families.\n *\n * A codec maps between three representations of a value:\n * - **JS** (`TJs`): the JavaScript type used in application code\n * - **Wire** (`TWire`): the format sent to/from the database driver\n * - **JSON** (`JsonValue`): the JSON-safe form stored in contract artifacts\n *\n * Family-specific codec interfaces (SQL `Codec`, Mongo `MongoCodec`) extend\n * this base to add family-specific metadata.\n */\nexport interface Codec<\n Id extends string = string,\n TTraits extends readonly CodecTrait[] = readonly CodecTrait[],\n TWire = unknown,\n TJs = unknown,\n> {\n /** Unique codec identifier in `namespace/name@version` format (e.g. `pg/timestamptz@1`). */\n readonly id: Id;\n /** Database-native type names this codec handles (e.g. `['timestamptz']`). */\n readonly targetTypes: readonly string[];\n /** Semantic traits for operator gating (e.g. equality, order, numeric). */\n readonly traits?: TTraits;\n /** Converts a JS value to the wire format expected by the database driver. Optional when the driver accepts the JS type directly. */\n encode?(value: TJs): TWire;\n /** Converts a wire value from the database driver into the JS type. */\n decode(wire: TWire): TJs;\n /** Converts a JS value to a JSON-safe representation for contract serialization. Called during contract emission. */\n encodeJson(value: TJs): JsonValue;\n /** Converts a JSON representation back to the JS type. Called during contract loading via `validateContract`. */\n decodeJson(json: JsonValue): TJs;\n /** Produces the TypeScript output type expression for a field given its `typeParams`. Used during contract.d.ts emission. */\n renderOutputType?(typeParams: Record<string, unknown>): string | undefined;\n}\n\nexport interface CodecLookup {\n get(id: string): Codec | undefined;\n}\n\nexport const emptyCodecLookup: CodecLookup = {\n get: () => undefined,\n};\n"],"mappings":";AA2CA,MAAaA,mBAAgC,EAC3C,WAAW,QACZ"}
1
+ {"version":3,"file":"codec.mjs","names":["emptyCodecLookup: CodecLookup"],"sources":["../src/codec-types.ts"],"sourcesContent":["import type { JsonValue } from '@prisma-next/contract/types';\n\nexport type CodecTrait = 'equality' | 'order' | 'boolean' | 'numeric' | 'textual';\n\n/**\n * A codec is the contract between an application value and its on-wire and\n * on-contract-disk representations.\n *\n * The author's mental model is two JS-side types — `TInput` (the\n * application JS type) and `TWire` (the database driver wire format) —\n * plus `JsonValue` for build-time contract artifacts. The codec translates\n * `TInput` to `TWire` on writes and back on reads, and to/from `JsonValue`\n * during contract emission and loading.\n *\n * Three representations participate:\n * - **Input** (`TInput`): the JS type at the application boundary.\n * - **Wire** (`TWire`): the format exchanged with the database driver.\n * - **JSON** (`JsonValue`): a JSON-safe form used in contract artifacts.\n *\n * Codec methods split into two groups:\n *\n * - **Query-time** methods (`encode`, `decode`) run per row/parameter at the\n * IO boundary; they are required and Promise-returning. The per-family\n * codec factory accepts sync or async author functions and lifts sync\n * ones to Promise-shaped methods automatically.\n * - **Build-time** methods (`encodeJson`, `decodeJson`, `renderOutputType`)\n * run when the contract is serialized, loaded, or when client types are\n * emitted. They stay synchronous so contract validation and client\n * construction are synchronous.\n *\n * Target-family codec interfaces extend this base with target-shaped\n * metadata.\n */\nexport interface Codec<\n Id extends string = string,\n TTraits extends readonly CodecTrait[] = readonly CodecTrait[],\n TWire = unknown,\n TInput = unknown,\n> {\n /** Unique codec identifier in `namespace/name@version` format (e.g. `pg/timestamptz@1`). */\n readonly id: Id;\n /** Database-native type names this codec handles (e.g. `['timestamptz']`). */\n readonly targetTypes: readonly string[];\n /** Semantic traits for operator gating (e.g. equality, order, numeric). */\n readonly traits?: TTraits;\n /** Converts a JS value to the wire format expected by the database driver. Always Promise-returning at the boundary. */\n encode(value: TInput): Promise<TWire>;\n /** Converts a wire value from the database driver into the JS application type. Always Promise-returning at the boundary. */\n decode(wire: TWire): Promise<TInput>;\n /** Converts a JS value to a JSON-safe representation for contract serialization. Synchronous; called during contract emission. */\n encodeJson(value: TInput): JsonValue;\n /** Converts a JSON representation back to the JS input type. Synchronous; called during contract loading via `validateContract`. */\n decodeJson(json: JsonValue): TInput;\n /** Produces the TypeScript output type expression for a field given its `typeParams`. Synchronous; used during contract.d.ts emission. */\n renderOutputType?(typeParams: Record<string, unknown>): string | undefined;\n}\n\nexport interface CodecLookup {\n get(id: string): Codec | undefined;\n}\n\nexport const emptyCodecLookup: CodecLookup = {\n get: () => undefined,\n};\n"],"mappings":";AA6DA,MAAaA,mBAAgC,EAC3C,WAAW,QACZ"}
@@ -1,2 +1,2 @@
1
- import { S as checkContractComponentRequirements, _ as PackRefBase, a as ComponentMetadata, b as TargetInstance, c as DriverDescriptor, d as ExtensionDescriptor, f as ExtensionInstance, g as FamilyPackRef, h as FamilyInstance, i as ComponentDescriptor, l as DriverInstance, m as FamilyDescriptor, n as AdapterInstance, o as ContractComponentRequirementsCheckInput, p as ExtensionPackRef, r as AdapterPackRef, s as ContractComponentRequirementsCheckResult, t as AdapterDescriptor, u as DriverPackRef, v as TargetBoundComponentDescriptor, x as TargetPackRef, y as TargetDescriptor } from "./framework-components-EJXe-pum.mjs";
1
+ import { S as checkContractComponentRequirements, _ as PackRefBase, a as ComponentMetadata, b as TargetInstance, c as DriverDescriptor, d as ExtensionDescriptor, f as ExtensionInstance, g as FamilyPackRef, h as FamilyInstance, i as ComponentDescriptor, l as DriverInstance, m as FamilyDescriptor, n as AdapterInstance, o as ContractComponentRequirementsCheckInput, p as ExtensionPackRef, r as AdapterPackRef, s as ContractComponentRequirementsCheckResult, t as AdapterDescriptor, u as DriverPackRef, v as TargetBoundComponentDescriptor, x as TargetPackRef, y as TargetDescriptor } from "./framework-components-DFZMi2h7.mjs";
2
2
  export { type AdapterDescriptor, type AdapterInstance, type AdapterPackRef, type ComponentDescriptor, type ComponentMetadata, type ContractComponentRequirementsCheckInput, type ContractComponentRequirementsCheckResult, type DriverDescriptor, type DriverInstance, type DriverPackRef, type ExtensionDescriptor, type ExtensionInstance, type ExtensionPackRef, type FamilyDescriptor, type FamilyInstance, type FamilyPackRef, type PackRefBase, type TargetBoundComponentDescriptor, type TargetDescriptor, type TargetInstance, type TargetPackRef, checkContractComponentRequirements };
@@ -1,6 +1,6 @@
1
1
  import { a as AuthoringFieldNamespace, d as AuthoringTypeNamespace, i as AuthoringContributions } from "./framework-authoring-D1-JZ37B.mjs";
2
- import { n as CodecLookup } from "./codec-types-B58nCJiu.mjs";
3
- import { A as LoweredDefaultResult, C as ControlMutationDefaultEntry, D as DefaultFunctionLoweringHandler, E as DefaultFunctionLoweringContext, F as SourceSpan, M as MutationDefaultGeneratorDescriptor, N as ParsedDefaultFunctionCall, O as DefaultFunctionRegistry, P as SourceDiagnostic, T as ControlMutationDefaults, a as ComponentMetadata, b as TargetInstance, c as DriverDescriptor, d as ExtensionDescriptor, f as ExtensionInstance, h as FamilyInstance, j as LoweredDefaultValue, k as DefaultFunctionRegistryEntry, l as DriverInstance, m as FamilyDescriptor, n as AdapterInstance, t as AdapterDescriptor, v as TargetBoundComponentDescriptor, w as ControlMutationDefaultRegistry, y as TargetDescriptor } from "./framework-components-EJXe-pum.mjs";
2
+ import { n as CodecLookup } from "./codec-types-DQ1Agjom.mjs";
3
+ import { A as LoweredDefaultResult, C as ControlMutationDefaultEntry, D as DefaultFunctionLoweringHandler, E as DefaultFunctionLoweringContext, F as SourceSpan, M as MutationDefaultGeneratorDescriptor, N as ParsedDefaultFunctionCall, O as DefaultFunctionRegistry, P as SourceDiagnostic, T as ControlMutationDefaults, a as ComponentMetadata, b as TargetInstance, c as DriverDescriptor, d as ExtensionDescriptor, f as ExtensionInstance, h as FamilyInstance, j as LoweredDefaultValue, k as DefaultFunctionRegistryEntry, l as DriverInstance, m as FamilyDescriptor, n as AdapterInstance, t as AdapterDescriptor, v as TargetBoundComponentDescriptor, w as ControlMutationDefaultRegistry, y as TargetDescriptor } from "./framework-components-DFZMi2h7.mjs";
4
4
  import { t as TypesImportSpec } from "./types-import-spec-C4sc7wbb.mjs";
5
5
  import { t as EmissionSpi } from "./emission-types-BPAALJbF.mjs";
6
6
  import { Contract, ContractMarkerRecord } from "@prisma-next/contract/types";
@@ -1 +1 @@
1
- {"version":3,"file":"control.d.mts","names":[],"sources":["../src/control-result-types.ts","../src/control-instances.ts","../src/control-stack.ts","../src/control-descriptors.ts","../src/control-migration-types.ts","../src/control-schema-view.ts","../src/control-capabilities.ts"],"sourcesContent":[],"mappings":";;;;;;;;;cAAa,0BAAA;cACA,yBAAA;cACA,2BAAA;cACA,0BAAA;UAEI,gBAAA;;;kBAGC,SAAS;;AARd,UAWI,oBAAA,CAXsB;EAC1B,SAAA,EAAA,EAAA,OAAA;EACA,SAAA,IAAA,CAAA,EAAA,MAAA;EACA,SAAA,OAAA,EAAA,MAAA;EAEI,SAAA,QAAA,EAAgB;IAMhB,SAAA,WAAoB,EAAA,MAAA;IA2BpB,SAAA,WAAe,CAAA,EAAA,MAAA;EAiCf,CAAA;EAQL,SAAA,MAAW,CAAA,EAAA;IAEN,SAAA,WAAA,CAAsB,EAAA,MAAA;IAYtB,SAAA,WAAA,CAAA,EAAA,MAA0B;EAgC1B,CAAA;EAQA,SAAA,MAAA,EAAA;IAiBA,SAAA,QAAkB,EAAA,MAAA;;;;ECvIlB,SAAA,oBAAqB,CAAA,EAAA,OAAA;EACb,SAAA,IAAA,CAAA,EAAA;IACkB,SAAA,UAAA,CAAA,EAAA,MAAA;IAGA,SAAA,YAAA,EAAA,MAAA;EAAtB,CAAA;EAKP,SAAA,OAAA,EAAA;IAAR,SAAA,KAAA,EAAA,MAAA;EAGqC,CAAA;;AAKoC,UDK9D,eAAA,CCL8D;E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W,uBAChC,2BAA2B,WAAW;UAIlC;ENtBJ,YAAA,CAAA,MAAA,EMuBU,SNvBgB,CAAA,EMuBJ,cNvBI;AACvC;AACa,iBMwBG,aNxBwB,CAAA,kBAAA,MAAA,EAAA,SAAA,CAAA,CAAA,QAAA,EMyB5B,qBNzB4B,CMyBN,SNzBM,EMyBK,SNzBL,CAAA,CAAA,EAAA,QAAA,IM0BzB,qBN1ByB,CM0BH,SN1BG,EM0BQ,SN1BR,CAAA,GM0BqB,iBN1BrB,CM0BuC,SN1BvC,CAAA"}
1
+ {"version":3,"file":"control.d.mts","names":[],"sources":["../src/control-result-types.ts","../src/control-instances.ts","../src/control-stack.ts","../src/control-descriptors.ts","../src/control-migration-types.ts","../src/control-schema-view.ts","../src/control-capabilities.ts"],"sourcesContent":[],"mappings":";;;;;;;;;cAAa,0BAAA;cACA,yBAAA;cACA,2BAAA;cACA,0BAAA;UAEI,gBAAA;;;kBAGC,SAAS;;AARd,UAWI,oBAAA,CAXsB;EAC1B,SAAA,EAAA,EAAA,OAAA;EACA,SAAA,IAAA,CAAA,EAAA,MAAA;EACA,SAAA,OAAA,EAAA,MAAA;EAEI,SAAA,QAAA,EAAgB;IAMhB,SAAA,WAAoB,EAAA,MAAA;IA2BpB,SAAA,WAAe,CAAA,EAAA,MAAA;EAiCf,CAAA;EAQL,SAAA,MAAW,CAAA,EAAA;IAEN,SAAA,WAAA,CAAsB,EAAA,MAAA;IAYtB,SAAA,WAAA,CAAA,EAAA,MAA0B;EAgC1B,CAAA;EAQA,SAAA,MAAA,EAAA;IAiBA,SAAA,QAAkB,EAAA,MAAA;;;;ECvIlB,SAAA,oBAAqB,CAAA,EAAA,OAAA;EACb,SAAA,IAAA,CAAA,EAAA;IACkB,SAAA,UAAA,CAAA,EAAA,MAAA;IAGA,SAAA,YAAA,EAAA,MAAA;EAAtB,CAAA;EAKP,SAAA,OAAA,EAAA;IAAR,SAAA,KAAA,EAAA,MAAA;EAGqC,CAAA;;AAKoC,UDK9D,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ACN,wBAAwB,WAAW,uBAChC,2BAA2B,WAAW;UAIlC;ENtBJ,YAAA,CAAA,MAAA,EMuBU,SNvBgB,CAAA,EMuBJ,cNvBI;AACvC;AACa,iBMwBG,aNxBwB,CAAA,kBAAA,MAAA,EAAA,SAAA,CAAA,CAAA,QAAA,EMyB5B,qBNzB4B,CMyBN,SNzBM,EMyBK,SNzBL,CAAA,CAAA,EAAA,QAAA,IM0BzB,qBN1ByB,CM0BH,SN1BG,EM0BQ,SN1BR,CAAA,GM0BqB,iBN1BrB,CM0BuC,SN1BvC,CAAA"}
@@ -1,4 +1,4 @@
1
- import { b as TargetInstance, c as DriverDescriptor, d as ExtensionDescriptor, f as ExtensionInstance, h as FamilyInstance, l as DriverInstance, m as FamilyDescriptor, n as AdapterInstance, t as AdapterDescriptor, y as TargetDescriptor } from "./framework-components-EJXe-pum.mjs";
1
+ import { b as TargetInstance, c as DriverDescriptor, d as ExtensionDescriptor, f as ExtensionInstance, h as FamilyInstance, l as DriverInstance, m as FamilyDescriptor, n as AdapterInstance, t as AdapterDescriptor, y as TargetDescriptor } from "./framework-components-DFZMi2h7.mjs";
2
2
 
3
3
  //#region src/execution-instances.d.ts
4
4
  interface RuntimeFamilyInstance<TFamilyId extends string> extends FamilyInstance<TFamilyId> {}
@@ -1 +1 @@
1
- {"version":3,"file":"framework-authoring-D1-JZ37B.d.mts","names":[],"sources":["../src/framework-authoring.ts"],"sourcesContent":[],"mappings":";KAEY,eAAA;EAAA,SAAA,IAAA,EAAA,KAAe;EAOf,SAAA,KAAA,EAAA,MAAA;EAKR,SAAA,IAAA,CAAA,EAAA,SAAA,MAAA,EAAA;EACS,SAAA,OAAA,CAAA,EATQ,sBASR;CACiB;AAAsB,KAPxC,sBAAA,GAOwC,MAAA,GAAA,MAAA,GAAA,OAAA,GAAA,IAAA,GAFhD,eAEgD,GAAA,SADvC,sBACuC,EAAA,GAAA;EAE1C,UAAA,GAAA,EAAA,MAAA,CAAA,EAFoB,sBAEa;AAK3C,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iBAAA;EAYA,SAAA,IAAA,CAAA,EAAA,SA3EW,2BA6Ef,EAAA;EAUI,SAAA,MAAA,EAtFG,4BAuFP;AA2GZ;AAuFgB,UAtRC,qCAAA,CAuRH;EAUE,SAAA,IAAA,EAAA,SAAA;kBA/RE;;UAGD,sCAAA;;uBAEM;;KAGX,8BAAA,GACR,wCACA;UAEa,0BAAA,SAAmC;;qBAE/B;8BACS;;;;UAKb,8BAAA;;2BAEU;mBACR;;KAGP,sBAAA;2BACe,qCAAqC;;KAGpD,uBAAA;2BACe,iCAAiC;;UAG3C,sBAAA;kBACC;mBACC;;iBAGH,iBAAA,2BAA4C;iBAkB5C,oCAAA,2BAEJ;iBAUI,gCAAA,2BAEJ;iBAUI,6BAAA,WACJ;iBA2GI,gCAAA,2CAEQ;iBAqFR,mCAAA,aACF;;;wBAKU;;iBAKR,+BAAA,aACF;;;;0BAMY"}
@@ -1,5 +1,5 @@
1
1
  import { i as AuthoringContributions } from "./framework-authoring-D1-JZ37B.mjs";
2
- import { t as Codec } from "./codec-types-B58nCJiu.mjs";
2
+ import { t as Codec } from "./codec-types-DQ1Agjom.mjs";
3
3
  import { t as TypesImportSpec } from "./types-import-spec-C4sc7wbb.mjs";
4
4
  import { ColumnDefault, ExecutionMutationDefaultValue } from "@prisma-next/contract/types";
5
5
 
@@ -421,4 +421,4 @@ interface ExtensionInstance<TFamilyId extends string, TTargetId extends string>
421
421
  }
422
422
  //#endregion
423
423
  export { LoweredDefaultResult as A, ControlMutationDefaultEntry as C, DefaultFunctionLoweringHandler as D, DefaultFunctionLoweringContext as E, SourceSpan as F, MutationDefaultGeneratorDescriptor as M, ParsedDefaultFunctionCall as N, DefaultFunctionRegistry as O, SourceDiagnostic as P, checkContractComponentRequirements as S, ControlMutationDefaults as T, PackRefBase as _, ComponentMetadata as a, TargetInstance as b, DriverDescriptor as c, ExtensionDescriptor as d, ExtensionInstance as f, FamilyPackRef as g, FamilyInstance as h, ComponentDescriptor as i, LoweredDefaultValue as j, DefaultFunctionRegistryEntry as k, DriverInstance as l, FamilyDescriptor as m, AdapterInstance as n, ContractComponentRequirementsCheckInput as o, ExtensionPackRef as p, AdapterPackRef as r, ContractComponentRequirementsCheckResult as s, AdapterDescriptor as t, DriverPackRef as u, TargetBoundComponentDescriptor as v, ControlMutationDefaultRegistry as w, TargetPackRef as x, TargetDescriptor as y };
424
- //# sourceMappingURL=framework-components-EJXe-pum.d.mts.map
424
+ //# sourceMappingURL=framework-components-DFZMi2h7.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"framework-components-EJXe-pum.d.mts","names":[],"sources":["../src/mutation-default-types.ts","../src/framework-components.ts"],"sourcesContent":[],"mappings":";;;;;;UAEU,cAAA;;;;;AAAA,UAMO,UAAA,CANO;EAMP,SAAA,KAAU,EACT,cAAA;EAID,SAAA,GAAA,EAHD,cAGiB;;AAKN,UALV,gBAAA,CAKU;EAAT,SAAA,IAAA,EAAA,MAAA;EAAQ,SAAA,OAAA,EAAA,MAAA;EAGhB,SAAA,QAAA,CAAA,EAAA,MAAuB;EAKhB,SAAA,IAAA,CAAA,EATC,UASD;EAOA,SAAA,IAAA,CAAA,EAfC,QAeD,CAfU,MAeV,CAAA,MAA8B,EAAA,OAAA,CAAA,CAAA;AAO/C;AAIA,UAvBU,uBAAA,CAuBsB;EAIpB,SAAA,GAAA,EAAA,MAAA;EACK,SAAA,IAAA,EA1BA,UA0BA;;AAEX,UAzBW,yBAAA,CAyBX;EAAoB,SAAA,IAAA,EAAA,MAAA;EAET,SAAA,GAAA,EAAA,MAAA;EAKL,SAAA,IAAA,EAAA,SA7Bc,uBA6BgC,EAAA;EAEzC,SAAA,IAAA,EA9BA,UA8BA;AAejB;AAEmB,UA5CF,8BAAA,CA4CE;EACG,SAAA,QAAA,EAAA,MAAA;EACd,SAAA,SAAA,EAAA,MAAA;EAAoB,SAAA,SAAA,EAAA,MAAA;EAIhB,SAAA,aAAA,CAAA,EAAA,MAAA;AAEZ;KA7CY,mBAAA;;yBAC2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;;;;;;;;;;;;;;UA+BJ,8EACP;;qBAEW;;qBAGA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;UAiCJ,6EACP;;qBAEW;;qBAGA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;UA8BJ,gFACP;;qBAEW;;qBAGA;;;KAIT,qFACR,iBAAiB,WAAW,aAC5B,kBAAkB,WAAW,aAC7B,iBAAiB,WAAW,aAC5B,oBAAoB,WAAW;UAElB;qBACI;;UAGJ;qBACI;qBACA;;UAGJ;qBACI;qBACA;;UAGJ;qBACI;qBACA;;UAGJ;qBACI;qBACA"}
1
+ {"version":3,"file":"framework-components-DFZMi2h7.d.mts","names":[],"sources":["../src/mutation-default-types.ts","../src/framework-components.ts"],"sourcesContent":[],"mappings":";;;;;;UAEU,cAAA;;;;;AAAA,UAMO,UAAA,CANO;EAMP,SAAA,KAAU,EACT,cAAA;EAID,SAAA,GAAA,EAHD,cAGiB;;AAKN,UALV,gBAAA,CAKU;EAAT,SAAA,IAAA,EAAA,MAAA;EAAQ,SAAA,OAAA,EAAA,MAAA;EAGhB,SAAA,QAAA,CAAA,EAAA,MAAuB;EAKhB,SAAA,IAAA,CAAA,EATC,UASD;EAOA,SAAA,IAAA,CAAA,EAfC,QAeD,CAfU,MAeV,CAAA,MAA8B,EAAA,OAAA,CAAA,CAAA;AAO/C;AAIA,UAvBU,uBAAA,CAuBsB;EAIpB,SAAA,GAAA,EAAA,MAAA;EACK,SAAA,IAAA,EA1BA,UA0BA;;AAEX,UAzBW,yBAAA,CAyBX;EAAoB,SAAA,IAAA,EAAA,MAAA;EAET,SAAA,GAAA,EAAA,MAAA;EAKL,SAAA,IAAA,EAAA,SA7Bc,uBA6BgC,EAAA;EAEzC,SAAA,IAAA,EA9BA,UA8BA;AAejB;AAEmB,UA5CF,8BAAA,CA4CE;EACG,SAAA,QAAA,EAAA,MAAA;EACd,SAAA,SAAA,EAAA,MAAA;EAAoB,SAAA,SAAA,EAAA,MAAA;EAIhB,SAAA,aA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ACR;;KAGT,sFAGR,sBAAsB;qBACL;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;UA+BJ,8EACP;;qBAEW;;qBAGA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;UAiCJ,6EACP;;qBAEW;;qBAGA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;UA8BJ,gFACP;;qBAEW;;qBAGA;;;KAIT,qFACR,iBAAiB,WAAW,aAC5B,kBAAkB,WAAW,aAC7B,iBAAiB,WAAW,aAC5B,oBAAoB,WAAW;UAElB;qBACI;;UAGJ;qBACI;qBACA;;UAGJ;qBACI;qBACA;;UAGJ;qBACI;qBACA;;UAGJ;qBACI;qBACA"}
@@ -21,6 +21,13 @@ interface RuntimeErrorEnvelope extends Error {
21
21
  readonly severity: 'error';
22
22
  readonly details?: Record<string, unknown>;
23
23
  }
24
+ /**
25
+ * Type guard for the runtime-error envelope produced by `runtimeError`.
26
+ *
27
+ * Prefer this over duck-typing on `error.code` directly so consumers stay
28
+ * insulated from the envelope's internal shape.
29
+ */
30
+ declare function isRuntimeError(error: unknown): error is RuntimeErrorEnvelope;
24
31
  declare function runtimeError(code: string, message: string, details?: Record<string, unknown>): RuntimeErrorEnvelope;
25
32
  //#endregion
26
33
  //#region src/runtime-middleware.d.ts
@@ -73,5 +80,5 @@ interface RuntimeExecutor<TPlan extends {
73
80
  }
74
81
  declare function checkMiddlewareCompatibility(middleware: RuntimeMiddleware, runtimeFamilyId: string, runtimeTargetId: string): void;
75
82
  //#endregion
76
- export { type AfterExecuteResult, AsyncIterableResult, type RuntimeErrorEnvelope, type RuntimeExecutor, type RuntimeLog, type RuntimeMiddleware, type RuntimeMiddlewareContext, checkMiddlewareCompatibility, runtimeError };
83
+ export { type AfterExecuteResult, AsyncIterableResult, type RuntimeErrorEnvelope, type RuntimeExecutor, type RuntimeLog, type RuntimeMiddleware, type RuntimeMiddlewareContext, checkMiddlewareCompatibility, isRuntimeError, runtimeError };
77
84
  //# sourceMappingURL=runtime.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"runtime.d.mts","names":[],"sources":["../src/async-iterable-result.ts","../src/runtime-error.ts","../src/runtime-middleware.ts"],"sourcesContent":[],"mappings":";;;cAEa,oCAAoC,cAAc,MAAM,YAAY;;;EAApE,QAAA,UAAA;EAAkD,QAAA,oBAAA;EAAkB,WAAA,CAAA,SAAA,EAMxD,cANwD,CAMzC,GANyC,EAAA,IAAA,EAAA,OAAA,CAAA;EAMzC,CAIrC,MAAA,CAAO,aAAA,GAJ8B,EAIZ,aAJY,CAIE,GAJF,CAAA;EAAf,OAAA,CAAA,CAAA,EAuBZ,OAvBY,CAuBJ,GAvBI,EAAA,CAAA;EAIiB,KAAA,CAAA,CAAA,EAkDzB,OAlDyB,CAkDjB,GAlDiB,GAAA,IAAA,CAAA;EAAd,YAAA,CAAA,CAAA,EAuDJ,OAvDI,CAuDI,GAvDJ,CAAA;EAAzB,IAAO,CAAA,WAmEQ,GAnER,EAAA,EAAA,WAAA,KAAA,CAAA,CAAA,WAAA,CAAA,EAAA,CAAA,CAAA,KAAA,EAoEiB,GApEjB,EAAA,EAAA,GAoE2B,QApE3B,GAoEsC,WApEtC,CAoEkD,QApElD,CAAA,CAAA,GAAA,SAAA,GAAA,IAAA,EAAA,UAAA,CAAA,EAAA,CAAA,CAAA,MAAA,EAAA,OAAA,EAAA,GAqE6B,QArE7B,GAqEwC,WArExC,CAqEoD,QArEpD,CAAA,CAAA,GAAA,SAAA,GAAA,IAAA,CAAA,EAsEL,WAtEK,CAsEO,QAtEP,GAsEkB,QAtElB,CAAA;;;;UCZO,oBAAA,SAA6B;;;EDEjC,SAAA,QAAA,EAAA,OAAmB;EAA+B,SAAA,OAAA,CAAA,ECE1C,MDF0C,CAAA,MAAA,EAAA,OAAA,CAAA;;AAMvB,iBCDxB,YAAA,CDCwB,IAAA,EAAA,MAAA,EAAA,OAAA,EAAA,MAAA,EAAA,OAAA,CAAA,ECE5B,MDF4B,CAAA,MAAA,EAAA,OAAA,C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+C,QAzB9B;CAIM,CAAA,CAAA;EAAiB,OAAA,CAAA,GAAA,CAAA,CAAA,IAAA,EAsBpC,KAtBoC,GAAA;IAA2B,SAAA,IAAA,CAAA,EAsBrC,GAtBqC;EAE3E,CAAA,CAAA,EAoB8C,mBApB9C,CAoBkE,GApBlE,CAAA;EACkB,KAAA,EAAA,EAoBhB,OApBgB,CAAA,IAAA,CAAA;;AAEtB,iBAqBW,4BAAA,CArBX,UAAA,EAsBS,iBAtBT,EAAA,eAAA,EAAA,MAAA,EAAA,eAAA,EAAA,MAAA,CAAA,EAAA,IAAA"}
1
+ {"version":3,"file":"runtime.d.mts","names":[],"sources":["../src/async-iterable-result.ts","../src/runtime-error.ts","../src/runtime-middleware.ts"],"sourcesContent":[],"mappings":";;;cAEa,oCAAoC,cAAc,MAAM,YAAY;;;EAApE,QAAA,UAAA;EAAkD,QAAA,oBAAA;EAAkB,WAAA,CAAA,SAAA,EAMxD,cANwD,CAMzC,GANyC,EAAA,IAAA,EAAA,OAAA,CAAA;EAMzC,CAIrC,MAAA,CAAO,aAAA,GAJ8B,EAIZ,aAJY,CAIE,GAJF,CAAA;EAAf,OAAA,CAAA,CAAA,EAuBZ,OAvBY,CAuBJ,GAvBI,EAAA,CAAA;EAIiB,KAAA,CAAA,CAAA,EAkDzB,OAlDyB,CAkDjB,GAlDiB,GAAA,IAAA,CAAA;EAAd,YAAA,CAAA,CAAA,EAuDJ,OAvDI,CAuDI,GAvDJ,CAAA;EAAzB,IAAO,CAAA,WAmEQ,GAnER,EAAA,EAAA,WAAA,KAAA,CAAA,CAAA,WAAA,CAAA,EAAA,CAAA,CAAA,KAAA,EAoEiB,GApEjB,EAAA,EAAA,GAoE2B,QApE3B,GAoEsC,WApEtC,CAoEkD,QApElD,CAAA,CAAA,GAAA,SAAA,GAAA,IAAA,EAAA,UAAA,CAAA,EAAA,CAAA,CAAA,MAAA,EAAA,OAAA,EAAA,GAqE6B,QArE7B,GAqEwC,WArExC,CAqEoD,QArEpD,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wC,wBFsDxC,CAAA,EEtDmE,OFsDnE,CAAA,IAAA,CAAA;EAAW,KAAA,EAAA,GAAA,EEpDnB,MFoDmB,CAAA,MAAA,EAAA,OAAA,CAAA,EAAA,IAAA,EAAA;IAAvB,SAAA,IAAA,EEnDsB,QFmDtB;EAhF4C,CAAA,EAAA,GAAA,EE8BxC,wBF9BwC,CAAA,EE+B5C,OF/B4C,CAAA,IAAA,CAAA;EAAoB,YAAA,EAAA,IAAA,EAAA;IAAW,SAAA,IAAA,EEiCrD,QFjCqD;aEkCpE,yBACH,2BACJ;;;ADtCL;AAaA;AAUA;;;;ACnBA;AAOiB,UAsCA,eAtCwB,CAAA,cAIzB;EAGC,SAAA,IAAA,EA+B+C,QA/B7B;AAMnC,CAAA,CAAA,CAAA;EAIwC,OAAA,CAAA,GAAA,CAAA,CAAA,IAAA,EAsBnB,KAtBmB,GAAA;IAAiB,SAAA,IAAA,CAAA,EAsBV,GAtBU;EAA2B,CAAA,CAAA,EAsB7B,mBAtB6B,CAsBT,GAtBS,CAAA;EAE3E,KAAA,EAAA,EAqBE,OArBF,CAAA,IAAA,CAAA;;AAEA,iBAsBO,4BAAA,CAtBP,UAAA,EAuBK,iBAvBL,EAAA,eAAA,EAAA,MAAA,EAAA,eAAA,EAAA,MAAA,CAAA,EAAA,IAAA"}
package/dist/runtime.mjs CHANGED
@@ -1,4 +1,13 @@
1
1
  //#region src/runtime-error.ts
2
+ /**
3
+ * Type guard for the runtime-error envelope produced by `runtimeError`.
4
+ *
5
+ * Prefer this over duck-typing on `error.code` directly so consumers stay
6
+ * insulated from the envelope's internal shape.
7
+ */
8
+ function isRuntimeError(error) {
9
+ return error instanceof Error && "code" in error && typeof error.code === "string" && "category" in error && "severity" in error;
10
+ }
2
11
  function runtimeError(code, message, details) {
3
12
  const error = new Error(message);
4
13
  Object.defineProperty(error, "name", {
@@ -91,5 +100,5 @@ function checkMiddlewareCompatibility(middleware, runtimeFamilyId, runtimeTarget
91
100
  }
92
101
 
93
102
  //#endregion
94
- export { AsyncIterableResult, checkMiddlewareCompatibility, runtimeError };
103
+ export { AsyncIterableResult, checkMiddlewareCompatibility, isRuntimeError, runtimeError };
95
104
  //# sourceMappingURL=runtime.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"runtime.mjs","names":["out: Row[]"],"sources":["../src/runtime-error.ts","../src/async-iterable-result.ts","../src/runtime-middleware.ts"],"sourcesContent":["export interface RuntimeErrorEnvelope extends Error {\n readonly code: string;\n readonly category: 'PLAN' | 'CONTRACT' | 'LINT' | 'BUDGET' | 'RUNTIME';\n readonly severity: 'error';\n readonly details?: Record<string, unknown>;\n}\n\nexport function runtimeError(\n code: string,\n message: string,\n details?: Record<string, unknown>,\n): RuntimeErrorEnvelope {\n const error = new Error(message) as RuntimeErrorEnvelope;\n Object.defineProperty(error, 'name', {\n value: 'RuntimeError',\n configurable: true,\n });\n\n return Object.assign(error, {\n code,\n category: resolveCategory(code),\n severity: 'error' as const,\n message,\n details,\n });\n}\n\nfunction resolveCategory(code: string): RuntimeErrorEnvelope['category'] {\n const prefix = code.split('.')[0] ?? 'RUNTIME';\n switch (prefix) {\n case 'PLAN':\n case 'CONTRACT':\n case 'LINT':\n case 'BUDGET':\n return prefix;\n default:\n return 'RUNTIME';\n }\n}\n","import { runtimeError } from './runtime-error';\n\nexport class AsyncIterableResult<Row> implements AsyncIterable<Row>, PromiseLike<Row[]> {\n private readonly generator: AsyncGenerator<Row, void, unknown>;\n private consumed = false;\n private consumedBy: 'bufferedArray' | 'iterator' | undefined;\n private bufferedArrayPromise: Promise<Row[]> | undefined;\n\n constructor(generator: AsyncGenerator<Row, void, unknown>) {\n this.generator = generator;\n }\n\n [Symbol.asyncIterator](): AsyncIterator<Row> {\n if (this.consumed) {\n throw runtimeError(\n 'RUNTIME.ITERATOR_CONSUMED',\n `AsyncIterableResult iterator has already been consumed via ${this.consumedBy === 'bufferedArray' ? 'toArray()/then()' : 'for-await loop'}. Each AsyncIterableResult can only be iterated once.`,\n {\n consumedBy: this.consumedBy,\n suggestion:\n this.consumedBy === 'bufferedArray'\n ? 'If you need to iterate multiple times, store the results from toArray() in a variable and reuse that.'\n : 'If you need to iterate multiple times, use toArray() to collect all results first.',\n },\n );\n }\n this.consumed = true;\n this.consumedBy = 'iterator';\n return this.generator;\n }\n\n toArray(): Promise<Row[]> {\n if (this.consumedBy === 'iterator') {\n return Promise.reject(\n runtimeError(\n 'RUNTIME.ITERATOR_CONSUMED',\n 'AsyncIterableResult iterator has already been consumed via for-await loop. Each AsyncIterableResult can only be iterated once.',\n {\n consumedBy: this.consumedBy,\n suggestion:\n 'The iterator was already consumed by a for-await loop. Use toArray() or await the result before iterating.',\n },\n ),\n );\n }\n\n if (this.bufferedArrayPromise) {\n return this.bufferedArrayPromise;\n }\n\n this.consumed = true;\n this.consumedBy = 'bufferedArray';\n this.bufferedArrayPromise = (async () => {\n const out: Row[] = [];\n for await (const item of this.generator) {\n out.push(item);\n }\n return out;\n })();\n return this.bufferedArrayPromise;\n }\n\n async first(): Promise<Row | null> {\n const rows = await this.toArray();\n return rows[0] ?? null;\n }\n\n async firstOrThrow(): Promise<Row> {\n const row = await this.first();\n if (row === null)\n throw runtimeError(\n 'RUNTIME.NO_ROWS',\n 'Expected at least one row, but none were returned',\n {},\n );\n return row;\n }\n\n // biome-ignore lint/suspicious/noThenProperty: PromiseLike implementation is intentional for await support.\n then<TResult1 = Row[], TResult2 = never>(\n onfulfilled?: ((value: Row[]) => TResult1 | PromiseLike<TResult1>) | undefined | null,\n onrejected?: ((reason: unknown) => TResult2 | PromiseLike<TResult2>) | undefined | null,\n ): PromiseLike<TResult1 | TResult2> {\n return this.toArray().then(onfulfilled, onrejected);\n }\n}\n","import type { PlanMeta } from '@prisma-next/contract/types';\nimport type { AsyncIterableResult } from './async-iterable-result';\nimport { runtimeError } from './runtime-error';\n\nexport interface RuntimeLog {\n info(event: unknown): void;\n warn(event: unknown): void;\n error(event: unknown): void;\n debug?(event: unknown): void;\n}\n\nexport interface RuntimeMiddlewareContext {\n readonly contract: unknown;\n readonly mode: 'strict' | 'permissive';\n readonly now: () => number;\n readonly log: RuntimeLog;\n}\n\nexport interface AfterExecuteResult {\n readonly rowCount: number;\n readonly latencyMs: number;\n readonly completed: boolean;\n}\n\nexport interface RuntimeMiddleware {\n readonly name: string;\n readonly familyId?: string;\n readonly targetId?: string;\n beforeExecute?(plan: { readonly meta: PlanMeta }, ctx: RuntimeMiddlewareContext): Promise<void>;\n onRow?(\n row: Record<string, unknown>,\n plan: { readonly meta: PlanMeta },\n ctx: RuntimeMiddlewareContext,\n ): Promise<void>;\n afterExecute?(\n plan: { readonly meta: PlanMeta },\n result: AfterExecuteResult,\n ctx: RuntimeMiddlewareContext,\n ): Promise<void>;\n}\n\n/**\n * Cross-family SPI for any runtime that can execute plans and be shut down.\n * Each family runtime (SQL, Mongo) satisfies this interface — SQL nominally,\n * Mongo structurally (due to its phantom Row parameter using a unique symbol).\n *\n * The `_row` intersection on `execute` connects the `Row` type parameter to the\n * plan, mirroring how `ExecutionPlan<Row>` carries a phantom `_row?: Row`.\n */\nexport interface RuntimeExecutor<TPlan extends { readonly meta: PlanMeta }> {\n execute<Row>(plan: TPlan & { readonly _row?: Row }): AsyncIterableResult<Row>;\n close(): Promise<void>;\n}\n\nexport function checkMiddlewareCompatibility(\n middleware: RuntimeMiddleware,\n runtimeFamilyId: string,\n runtimeTargetId: string,\n): void {\n if (middleware.targetId !== undefined && middleware.familyId === undefined) {\n throw runtimeError(\n 'RUNTIME.MIDDLEWARE_INCOMPATIBLE',\n `Middleware '${middleware.name}' specifies targetId '${middleware.targetId}' without familyId`,\n { middleware: middleware.name, targetId: middleware.targetId },\n );\n }\n\n if (middleware.familyId !== undefined && middleware.familyId !== runtimeFamilyId) {\n throw runtimeError(\n 'RUNTIME.MIDDLEWARE_FAMILY_MISMATCH',\n `Middleware '${middleware.name}' requires family '${middleware.familyId}' but the runtime is configured for family '${runtimeFamilyId}'`,\n { middleware: middleware.name, middlewareFamilyId: middleware.familyId, runtimeFamilyId },\n );\n }\n\n if (middleware.targetId !== undefined && middleware.targetId !== runtimeTargetId) {\n throw runtimeError(\n 'RUNTIME.MIDDLEWARE_TARGET_MISMATCH',\n `Middleware '${middleware.name}' requires target '${middleware.targetId}' but the runtime is configured for target '${runtimeTargetId}'`,\n { middleware: middleware.name, middlewareTargetId: middleware.targetId, runtimeTargetId },\n );\n }\n}\n"],"mappings":";AAOA,SAAgB,aACd,MACA,SACA,SACsB;CACtB,MAAM,QAAQ,IAAI,MAAM,QAAQ;AAChC,QAAO,eAAe,OAAO,QAAQ;EACnC,OAAO;EACP,cAAc;EACf,CAAC;AAEF,QAAO,OAAO,OAAO,OAAO;EAC1B;EACA,UAAU,gBAAgB,KAAK;EAC/B,UAAU;EACV;EACA;EACD,CAAC;;AAGJ,SAAS,gBAAgB,MAAgD;CACvE,MAAM,SAAS,KAAK,MAAM,IAAI,CAAC,MAAM;AACrC,SAAQ,QAAR;EACE,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK,SACH,QAAO;EACT,QACE,QAAO;;;;;;AClCb,IAAa,sBAAb,MAAwF;CACtF,AAAiB;CACjB,AAAQ,WAAW;CACnB,AAAQ;CACR,AAAQ;CAER,YAAY,WAA+C;AACzD,OAAK,YAAY;;CAGnB,CAAC,OAAO,iBAAqC;AAC3C,MAAI,KAAK,SACP,OAAM,aACJ,6BACA,8DAA8D,KAAK,eAAe,kBAAkB,qBAAqB,iBAAiB,wDAC1I;GACE,YAAY,KAAK;GACjB,YACE,KAAK,eAAe,kBAChB,0GACA;GACP,CACF;AAEH,OAAK,WAAW;AAChB,OAAK,aAAa;AAClB,SAAO,KAAK;;CAGd,UAA0B;AACxB,MAAI,KAAK,eAAe,WACtB,QAAO,QAAQ,OACb,aACE,6BACA,kIACA;GACE,YAAY,KAAK;GACjB,YACE;GACH,CACF,CACF;AAGH,MAAI,KAAK,qBACP,QAAO,KAAK;AAGd,OAAK,WAAW;AAChB,OAAK,aAAa;AAClB,OAAK,wBAAwB,YAAY;GACvC,MAAMA,MAAa,EAAE;AACrB,cAAW,MAAM,QAAQ,KAAK,UAC5B,KAAI,KAAK,KAAK;AAEhB,UAAO;MACL;AACJ,SAAO,KAAK;;CAGd,MAAM,QAA6B;AAEjC,UADa,MAAM,KAAK,SAAS,EACrB,MAAM;;CAGpB,MAAM,eAA6B;EACjC,MAAM,MAAM,MAAM,KAAK,OAAO;AAC9B,MAAI,QAAQ,KACV,OAAM,aACJ,mBACA,qDACA,EAAE,CACH;AACH,SAAO;;CAIT,KACE,aACA,YACkC;AAClC,SAAO,KAAK,SAAS,CAAC,KAAK,aAAa,WAAW;;;;;;AC7BvD,SAAgB,6BACd,YACA,iBACA,iBACM;AACN,KAAI,WAAW,aAAa,UAAa,WAAW,aAAa,OAC/D,OAAM,aACJ,mCACA,eAAe,WAAW,KAAK,wBAAwB,WAAW,SAAS,qBAC3E;EAAE,YAAY,WAAW;EAAM,UAAU,WAAW;EAAU,CAC/D;AAGH,KAAI,WAAW,aAAa,UAAa,WAAW,aAAa,gBAC/D,OAAM,aACJ,sCACA,eAAe,WAAW,KAAK,qBAAqB,WAAW,SAAS,8CAA8C,gBAAgB,IACtI;EAAE,YAAY,WAAW;EAAM,oBAAoB,WAAW;EAAU;EAAiB,CAC1F;AAGH,KAAI,WAAW,aAAa,UAAa,WAAW,aAAa,gBAC/D,OAAM,aACJ,sCACA,eAAe,WAAW,KAAK,qBAAqB,WAAW,SAAS,8CAA8C,gBAAgB,IACtI;EAAE,YAAY,WAAW;EAAM,oBAAoB,WAAW;EAAU;EAAiB,CAC1F"}
1
+ {"version":3,"file":"runtime.mjs","names":["out: Row[]"],"sources":["../src/runtime-error.ts","../src/async-iterable-result.ts","../src/runtime-middleware.ts"],"sourcesContent":["export interface RuntimeErrorEnvelope extends Error {\n readonly code: string;\n readonly category: 'PLAN' | 'CONTRACT' | 'LINT' | 'BUDGET' | 'RUNTIME';\n readonly severity: 'error';\n readonly details?: Record<string, unknown>;\n}\n\n/**\n * Type guard for the runtime-error envelope produced by `runtimeError`.\n *\n * Prefer this over duck-typing on `error.code` directly so consumers stay\n * insulated from the envelope's internal shape.\n */\nexport function isRuntimeError(error: unknown): error is RuntimeErrorEnvelope {\n return (\n error instanceof Error &&\n 'code' in error &&\n typeof (error as { code?: unknown }).code === 'string' &&\n 'category' in error &&\n 'severity' in error\n );\n}\n\nexport function runtimeError(\n code: string,\n message: string,\n details?: Record<string, unknown>,\n): RuntimeErrorEnvelope {\n const error = new Error(message) as RuntimeErrorEnvelope;\n Object.defineProperty(error, 'name', {\n value: 'RuntimeError',\n configurable: true,\n });\n\n return Object.assign(error, {\n code,\n category: resolveCategory(code),\n severity: 'error' as const,\n message,\n details,\n });\n}\n\nfunction resolveCategory(code: string): RuntimeErrorEnvelope['category'] {\n const prefix = code.split('.')[0] ?? 'RUNTIME';\n switch (prefix) {\n case 'PLAN':\n case 'CONTRACT':\n case 'LINT':\n case 'BUDGET':\n return prefix;\n default:\n return 'RUNTIME';\n }\n}\n","import { runtimeError } from './runtime-error';\n\nexport class AsyncIterableResult<Row> implements AsyncIterable<Row>, PromiseLike<Row[]> {\n private readonly generator: AsyncGenerator<Row, void, unknown>;\n private consumed = false;\n private consumedBy: 'bufferedArray' | 'iterator' | undefined;\n private bufferedArrayPromise: Promise<Row[]> | undefined;\n\n constructor(generator: AsyncGenerator<Row, void, unknown>) {\n this.generator = generator;\n }\n\n [Symbol.asyncIterator](): AsyncIterator<Row> {\n if (this.consumed) {\n throw runtimeError(\n 'RUNTIME.ITERATOR_CONSUMED',\n `AsyncIterableResult iterator has already been consumed via ${this.consumedBy === 'bufferedArray' ? 'toArray()/then()' : 'for-await loop'}. Each AsyncIterableResult can only be iterated once.`,\n {\n consumedBy: this.consumedBy,\n suggestion:\n this.consumedBy === 'bufferedArray'\n ? 'If you need to iterate multiple times, store the results from toArray() in a variable and reuse that.'\n : 'If you need to iterate multiple times, use toArray() to collect all results first.',\n },\n );\n }\n this.consumed = true;\n this.consumedBy = 'iterator';\n return this.generator;\n }\n\n toArray(): Promise<Row[]> {\n if (this.consumedBy === 'iterator') {\n return Promise.reject(\n runtimeError(\n 'RUNTIME.ITERATOR_CONSUMED',\n 'AsyncIterableResult iterator has already been consumed via for-await loop. Each AsyncIterableResult can only be iterated once.',\n {\n consumedBy: this.consumedBy,\n suggestion:\n 'The iterator was already consumed by a for-await loop. Use toArray() or await the result before iterating.',\n },\n ),\n );\n }\n\n if (this.bufferedArrayPromise) {\n return this.bufferedArrayPromise;\n }\n\n this.consumed = true;\n this.consumedBy = 'bufferedArray';\n this.bufferedArrayPromise = (async () => {\n const out: Row[] = [];\n for await (const item of this.generator) {\n out.push(item);\n }\n return out;\n })();\n return this.bufferedArrayPromise;\n }\n\n async first(): Promise<Row | null> {\n const rows = await this.toArray();\n return rows[0] ?? null;\n }\n\n async firstOrThrow(): Promise<Row> {\n const row = await this.first();\n if (row === null)\n throw runtimeError(\n 'RUNTIME.NO_ROWS',\n 'Expected at least one row, but none were returned',\n {},\n );\n return row;\n }\n\n // biome-ignore lint/suspicious/noThenProperty: PromiseLike implementation is intentional for await support.\n then<TResult1 = Row[], TResult2 = never>(\n onfulfilled?: ((value: Row[]) => TResult1 | PromiseLike<TResult1>) | undefined | null,\n onrejected?: ((reason: unknown) => TResult2 | PromiseLike<TResult2>) | undefined | null,\n ): PromiseLike<TResult1 | TResult2> {\n return this.toArray().then(onfulfilled, onrejected);\n }\n}\n","import type { PlanMeta } from '@prisma-next/contract/types';\nimport type { AsyncIterableResult } from './async-iterable-result';\nimport { runtimeError } from './runtime-error';\n\nexport interface RuntimeLog {\n info(event: unknown): void;\n warn(event: unknown): void;\n error(event: unknown): void;\n debug?(event: unknown): void;\n}\n\nexport interface RuntimeMiddlewareContext {\n readonly contract: unknown;\n readonly mode: 'strict' | 'permissive';\n readonly now: () => number;\n readonly log: RuntimeLog;\n}\n\nexport interface AfterExecuteResult {\n readonly rowCount: number;\n readonly latencyMs: number;\n readonly completed: boolean;\n}\n\nexport interface RuntimeMiddleware {\n readonly name: string;\n readonly familyId?: string;\n readonly targetId?: string;\n beforeExecute?(plan: { readonly meta: PlanMeta }, ctx: RuntimeMiddlewareContext): Promise<void>;\n onRow?(\n row: Record<string, unknown>,\n plan: { readonly meta: PlanMeta },\n ctx: RuntimeMiddlewareContext,\n ): Promise<void>;\n afterExecute?(\n plan: { readonly meta: PlanMeta },\n result: AfterExecuteResult,\n ctx: RuntimeMiddlewareContext,\n ): Promise<void>;\n}\n\n/**\n * Cross-family SPI for any runtime that can execute plans and be shut down.\n * Each family runtime (SQL, Mongo) satisfies this interface — SQL nominally,\n * Mongo structurally (due to its phantom Row parameter using a unique symbol).\n *\n * The `_row` intersection on `execute` connects the `Row` type parameter to the\n * plan, mirroring how `ExecutionPlan<Row>` carries a phantom `_row?: Row`.\n */\nexport interface RuntimeExecutor<TPlan extends { readonly meta: PlanMeta }> {\n execute<Row>(plan: TPlan & { readonly _row?: Row }): AsyncIterableResult<Row>;\n close(): Promise<void>;\n}\n\nexport function checkMiddlewareCompatibility(\n middleware: RuntimeMiddleware,\n runtimeFamilyId: string,\n runtimeTargetId: string,\n): void {\n if (middleware.targetId !== undefined && middleware.familyId === undefined) {\n throw runtimeError(\n 'RUNTIME.MIDDLEWARE_INCOMPATIBLE',\n `Middleware '${middleware.name}' specifies targetId '${middleware.targetId}' without familyId`,\n { middleware: middleware.name, targetId: middleware.targetId },\n );\n }\n\n if (middleware.familyId !== undefined && middleware.familyId !== runtimeFamilyId) {\n throw runtimeError(\n 'RUNTIME.MIDDLEWARE_FAMILY_MISMATCH',\n `Middleware '${middleware.name}' requires family '${middleware.familyId}' but the runtime is configured for family '${runtimeFamilyId}'`,\n { middleware: middleware.name, middlewareFamilyId: middleware.familyId, runtimeFamilyId },\n );\n }\n\n if (middleware.targetId !== undefined && middleware.targetId !== runtimeTargetId) {\n throw runtimeError(\n 'RUNTIME.MIDDLEWARE_TARGET_MISMATCH',\n `Middleware '${middleware.name}' requires target '${middleware.targetId}' but the runtime is configured for target '${runtimeTargetId}'`,\n { middleware: middleware.name, middlewareTargetId: middleware.targetId, runtimeTargetId },\n );\n }\n}\n"],"mappings":";;;;;;;AAaA,SAAgB,eAAe,OAA+C;AAC5E,QACE,iBAAiB,SACjB,UAAU,SACV,OAAQ,MAA6B,SAAS,YAC9C,cAAc,SACd,cAAc;;AAIlB,SAAgB,aACd,MACA,SACA,SACsB;CACtB,MAAM,QAAQ,IAAI,MAAM,QAAQ;AAChC,QAAO,eAAe,OAAO,QAAQ;EACnC,OAAO;EACP,cAAc;EACf,CAAC;AAEF,QAAO,OAAO,OAAO,OAAO;EAC1B;EACA,UAAU,gBAAgB,KAAK;EAC/B,UAAU;EACV;EACA;EACD,CAAC;;AAGJ,SAAS,gBAAgB,MAAgD;CACvE,MAAM,SAAS,KAAK,MAAM,IAAI,CAAC,MAAM;AACrC,SAAQ,QAAR;EACE,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK,SACH,QAAO;EACT,QACE,QAAO;;;;;;AClDb,IAAa,sBAAb,MAAwF;CACtF,AAAiB;CACjB,AAAQ,WAAW;CACnB,AAAQ;CACR,AAAQ;CAER,YAAY,WAA+C;AACzD,OAAK,YAAY;;CAGnB,CAAC,OAAO,iBAAqC;AAC3C,MAAI,KAAK,SACP,OAAM,aACJ,6BACA,8DAA8D,KAAK,eAAe,kBAAkB,qBAAqB,iBAAiB,wDAC1I;GACE,YAAY,KAAK;GACjB,YACE,KAAK,eAAe,kBAChB,0GACA;GACP,CACF;AAEH,OAAK,WAAW;AAChB,OAAK,aAAa;AAClB,SAAO,KAAK;;CAGd,UAA0B;AACxB,MAAI,KAAK,eAAe,WACtB,QAAO,QAAQ,OACb,aACE,6BACA,kIACA;GACE,YAAY,KAAK;GACjB,YACE;GACH,CACF,CACF;AAGH,MAAI,KAAK,qBACP,QAAO,KAAK;AAGd,OAAK,WAAW;AAChB,OAAK,aAAa;AAClB,OAAK,wBAAwB,YAAY;GACvC,MAAMA,MAAa,EAAE;AACrB,cAAW,MAAM,QAAQ,KAAK,UAC5B,KAAI,KAAK,KAAK;AAEhB,UAAO;MACL;AACJ,SAAO,KAAK;;CAGd,MAAM,QAA6B;AAEjC,UADa,MAAM,KAAK,SAAS,EACrB,MAAM;;CAGpB,MAAM,eAA6B;EACjC,MAAM,MAAM,MAAM,KAAK,OAAO;AAC9B,MAAI,QAAQ,KACV,OAAM,aACJ,mBACA,qDACA,EAAE,CACH;AACH,SAAO;;CAIT,KACE,aACA,YACkC;AAClC,SAAO,KAAK,SAAS,CAAC,KAAK,aAAa,WAAW;;;;;;AC7BvD,SAAgB,6BACd,YACA,iBACA,iBACM;AACN,KAAI,WAAW,aAAa,UAAa,WAAW,aAAa,OAC/D,OAAM,aACJ,mCACA,eAAe,WAAW,KAAK,wBAAwB,WAAW,SAAS,qBAC3E;EAAE,YAAY,WAAW;EAAM,UAAU,WAAW;EAAU,CAC/D;AAGH,KAAI,WAAW,aAAa,UAAa,WAAW,aAAa,gBAC/D,OAAM,aACJ,sCACA,eAAe,WAAW,KAAK,qBAAqB,WAAW,SAAS,8CAA8C,gBAAgB,IACtI;EAAE,YAAY,WAAW;EAAM,oBAAoB,WAAW;EAAU;EAAiB,CAC1F;AAGH,KAAI,WAAW,aAAa,UAAa,WAAW,aAAa,gBAC/D,OAAM,aACJ,sCACA,eAAe,WAAW,KAAK,qBAAqB,WAAW,SAAS,8CAA8C,gBAAgB,IACtI;EAAE,YAAY,WAAW;EAAM,oBAAoB,WAAW;EAAU;EAAiB,CAC1F"}
package/package.json CHANGED
@@ -1,20 +1,20 @@
1
1
  {
2
2
  "name": "@prisma-next/framework-components",
3
- "version": "0.5.0-dev.7",
3
+ "version": "0.5.0-dev.8",
4
4
  "type": "module",
5
5
  "sideEffects": false,
6
6
  "description": "Framework component types, assembly logic, and stack creation for Prisma Next",
7
7
  "dependencies": {
8
- "@prisma-next/contract": "0.5.0-dev.7",
9
- "@prisma-next/operations": "0.5.0-dev.7",
10
- "@prisma-next/utils": "0.5.0-dev.7"
8
+ "@prisma-next/contract": "0.5.0-dev.8",
9
+ "@prisma-next/utils": "0.5.0-dev.8",
10
+ "@prisma-next/operations": "0.5.0-dev.8"
11
11
  },
12
12
  "devDependencies": {
13
13
  "tsdown": "0.18.4",
14
14
  "typescript": "5.9.3",
15
15
  "vitest": "4.0.17",
16
- "@prisma-next/tsdown": "0.0.0",
17
- "@prisma-next/tsconfig": "0.0.0"
16
+ "@prisma-next/tsconfig": "0.0.0",
17
+ "@prisma-next/tsdown": "0.0.0"
18
18
  },
19
19
  "files": [
20
20
  "dist",
@@ -3,21 +3,39 @@ import type { JsonValue } from '@prisma-next/contract/types';
3
3
  export type CodecTrait = 'equality' | 'order' | 'boolean' | 'numeric' | 'textual';
4
4
 
5
5
  /**
6
- * Base codec interface for all target families.
6
+ * A codec is the contract between an application value and its on-wire and
7
+ * on-contract-disk representations.
7
8
  *
8
- * A codec maps between three representations of a value:
9
- * - **JS** (`TJs`): the JavaScript type used in application code
10
- * - **Wire** (`TWire`): the format sent to/from the database driver
11
- * - **JSON** (`JsonValue`): the JSON-safe form stored in contract artifacts
9
+ * The author's mental model is two JS-side types — `TInput` (the
10
+ * application JS type) and `TWire` (the database driver wire format)
11
+ * plus `JsonValue` for build-time contract artifacts. The codec translates
12
+ * `TInput` to `TWire` on writes and back on reads, and to/from `JsonValue`
13
+ * during contract emission and loading.
12
14
  *
13
- * Family-specific codec interfaces (SQL `Codec`, Mongo `MongoCodec`) extend
14
- * this base to add family-specific metadata.
15
+ * Three representations participate:
16
+ * - **Input** (`TInput`): the JS type at the application boundary.
17
+ * - **Wire** (`TWire`): the format exchanged with the database driver.
18
+ * - **JSON** (`JsonValue`): a JSON-safe form used in contract artifacts.
19
+ *
20
+ * Codec methods split into two groups:
21
+ *
22
+ * - **Query-time** methods (`encode`, `decode`) run per row/parameter at the
23
+ * IO boundary; they are required and Promise-returning. The per-family
24
+ * codec factory accepts sync or async author functions and lifts sync
25
+ * ones to Promise-shaped methods automatically.
26
+ * - **Build-time** methods (`encodeJson`, `decodeJson`, `renderOutputType`)
27
+ * run when the contract is serialized, loaded, or when client types are
28
+ * emitted. They stay synchronous so contract validation and client
29
+ * construction are synchronous.
30
+ *
31
+ * Target-family codec interfaces extend this base with target-shaped
32
+ * metadata.
15
33
  */
16
34
  export interface Codec<
17
35
  Id extends string = string,
18
36
  TTraits extends readonly CodecTrait[] = readonly CodecTrait[],
19
37
  TWire = unknown,
20
- TJs = unknown,
38
+ TInput = unknown,
21
39
  > {
22
40
  /** Unique codec identifier in `namespace/name@version` format (e.g. `pg/timestamptz@1`). */
23
41
  readonly id: Id;
@@ -25,15 +43,15 @@ export interface Codec<
25
43
  readonly targetTypes: readonly string[];
26
44
  /** Semantic traits for operator gating (e.g. equality, order, numeric). */
27
45
  readonly traits?: TTraits;
28
- /** Converts a JS value to the wire format expected by the database driver. Optional when the driver accepts the JS type directly. */
29
- encode?(value: TJs): TWire;
30
- /** Converts a wire value from the database driver into the JS type. */
31
- decode(wire: TWire): TJs;
32
- /** Converts a JS value to a JSON-safe representation for contract serialization. Called during contract emission. */
33
- encodeJson(value: TJs): JsonValue;
34
- /** Converts a JSON representation back to the JS type. Called during contract loading via `validateContract`. */
35
- decodeJson(json: JsonValue): TJs;
36
- /** Produces the TypeScript output type expression for a field given its `typeParams`. Used during contract.d.ts emission. */
46
+ /** Converts a JS value to the wire format expected by the database driver. Always Promise-returning at the boundary. */
47
+ encode(value: TInput): Promise<TWire>;
48
+ /** Converts a wire value from the database driver into the JS application type. Always Promise-returning at the boundary. */
49
+ decode(wire: TWire): Promise<TInput>;
50
+ /** Converts a JS value to a JSON-safe representation for contract serialization. Synchronous; called during contract emission. */
51
+ encodeJson(value: TInput): JsonValue;
52
+ /** Converts a JSON representation back to the JS input type. Synchronous; called during contract loading via `validateContract`. */
53
+ decodeJson(json: JsonValue): TInput;
54
+ /** Produces the TypeScript output type expression for a field given its `typeParams`. Synchronous; used during contract.d.ts emission. */
37
55
  renderOutputType?(typeParams: Record<string, unknown>): string | undefined;
38
56
  }
39
57
 
@@ -1,6 +1,6 @@
1
1
  export { AsyncIterableResult } from '../async-iterable-result';
2
2
  export type { RuntimeErrorEnvelope } from '../runtime-error';
3
- export { runtimeError } from '../runtime-error';
3
+ export { isRuntimeError, runtimeError } from '../runtime-error';
4
4
  export type {
5
5
  AfterExecuteResult,
6
6
  RuntimeExecutor,
@@ -5,6 +5,22 @@ export interface RuntimeErrorEnvelope extends Error {
5
5
  readonly details?: Record<string, unknown>;
6
6
  }
7
7
 
8
+ /**
9
+ * Type guard for the runtime-error envelope produced by `runtimeError`.
10
+ *
11
+ * Prefer this over duck-typing on `error.code` directly so consumers stay
12
+ * insulated from the envelope's internal shape.
13
+ */
14
+ export function isRuntimeError(error: unknown): error is RuntimeErrorEnvelope {
15
+ return (
16
+ error instanceof Error &&
17
+ 'code' in error &&
18
+ typeof (error as { code?: unknown }).code === 'string' &&
19
+ 'category' in error &&
20
+ 'severity' in error
21
+ );
22
+ }
23
+
8
24
  export function runtimeError(
9
25
  code: string,
10
26
  message: string,
@@ -1,40 +0,0 @@
1
- import { JsonValue } from "@prisma-next/contract/types";
2
-
3
- //#region src/codec-types.d.ts
4
- type CodecTrait = 'equality' | 'order' | 'boolean' | 'numeric' | 'textual';
5
- /**
6
- * Base codec interface for all target families.
7
- *
8
- * A codec maps between three representations of a value:
9
- * - **JS** (`TJs`): the JavaScript type used in application code
10
- * - **Wire** (`TWire`): the format sent to/from the database driver
11
- * - **JSON** (`JsonValue`): the JSON-safe form stored in contract artifacts
12
- *
13
- * Family-specific codec interfaces (SQL `Codec`, Mongo `MongoCodec`) extend
14
- * this base to add family-specific metadata.
15
- */
16
- interface Codec<Id extends string = string, TTraits extends readonly CodecTrait[] = readonly CodecTrait[], TWire = unknown, TJs = unknown> {
17
- /** Unique codec identifier in `namespace/name@version` format (e.g. `pg/timestamptz@1`). */
18
- readonly id: Id;
19
- /** Database-native type names this codec handles (e.g. `['timestamptz']`). */
20
- readonly targetTypes: readonly string[];
21
- /** Semantic traits for operator gating (e.g. equality, order, numeric). */
22
- readonly traits?: TTraits;
23
- /** Converts a JS value to the wire format expected by the database driver. Optional when the driver accepts the JS type directly. */
24
- encode?(value: TJs): TWire;
25
- /** Converts a wire value from the database driver into the JS type. */
26
- decode(wire: TWire): TJs;
27
- /** Converts a JS value to a JSON-safe representation for contract serialization. Called during contract emission. */
28
- encodeJson(value: TJs): JsonValue;
29
- /** Converts a JSON representation back to the JS type. Called during contract loading via `validateContract`. */
30
- decodeJson(json: JsonValue): TJs;
31
- /** Produces the TypeScript output type expression for a field given its `typeParams`. Used during contract.d.ts emission. */
32
- renderOutputType?(typeParams: Record<string, unknown>): string | undefined;
33
- }
34
- interface CodecLookup {
35
- get(id: string): Codec | undefined;
36
- }
37
- declare const emptyCodecLookup: CodecLookup;
38
- //#endregion
39
- export { emptyCodecLookup as i, CodecLookup as n, CodecTrait as r, Codec as t };
40
- //# sourceMappingURL=codec-types-B58nCJiu.d.mts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"codec-types-B58nCJiu.d.mts","names":[],"sources":["../src/codec-types.ts"],"sourcesContent":[],"mappings":";;;KAEY,UAAA;;AAAZ;AAaA;;;;;;;;;AAiBoB,UAjBH,KAiBG,CAAA,WAAA,MAAA,GAAA,MAAA,EAAA,gBAAA,SAfO,UAeP,EAAA,GAAA,SAf+B,UAe/B,EAAA,EAAA,QAAA,OAAA,EAAA,MAAA,OAAA,CAAA,CAAA;EAAM;EAEP,SAAA,EAAA,EAZJ,EAYI;EAAY;EAEC,SAAA,WAAA,EAAA,SAAA,MAAA,EAAA;EAAM;EAGrB,SAAA,MAAW,CAAA,EAbR,OAcD;EAGN;iBAfI,MAAM;;eAER,QAAQ;;oBAEH,MAAM;;mBAEP,YAAY;;gCAEC;;UAGf,WAAA;mBACE;;cAGN,kBAAkB"}