litedbmodel 2.0.2 → 2.1.0
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/dist/decorators.d.ts.map +1 -1
- package/dist/decorators.js +44 -24
- package/dist/decorators.js.map +1 -1
- package/dist/drivers/mysql.d.ts.map +1 -1
- package/dist/drivers/mysql.js +6 -0
- package/dist/drivers/mysql.js.map +1 -1
- package/dist/drivers/postgres.d.ts.map +1 -1
- package/dist/drivers/postgres.js +7 -0
- package/dist/drivers/postgres.js.map +1 -1
- package/dist/drivers/sqlite.d.ts +2 -0
- package/dist/drivers/sqlite.d.ts.map +1 -1
- package/dist/drivers/sqlite.js +37 -2
- package/dist/drivers/sqlite.js.map +1 -1
- package/dist/scp/authoring.d.ts +66 -3
- package/dist/scp/authoring.d.ts.map +1 -1
- package/dist/scp/authoring.js +194 -5
- package/dist/scp/authoring.js.map +1 -1
- package/dist/scp/catalog.d.ts +2 -1
- package/dist/scp/catalog.d.ts.map +1 -1
- package/dist/scp/catalog.js +12 -1
- package/dist/scp/catalog.js.map +1 -1
- package/dist/scp/codegen.d.ts +43 -31
- package/dist/scp/codegen.d.ts.map +1 -1
- package/dist/scp/codegen.js +279 -95
- package/dist/scp/codegen.js.map +1 -1
- package/dist/scp/coltype.d.ts +83 -0
- package/dist/scp/coltype.d.ts.map +1 -1
- package/dist/scp/coltype.js +220 -0
- package/dist/scp/coltype.js.map +1 -1
- package/dist/scp/guard.d.ts +1 -1
- package/dist/scp/guard.d.ts.map +1 -1
- package/dist/scp/guard.js +6 -0
- package/dist/scp/guard.js.map +1 -1
- package/dist/scp/index.cjs +7149 -9379
- package/dist/scp/index.d.ts +7 -6
- package/dist/scp/index.d.ts.map +1 -1
- package/dist/scp/index.js +21 -6
- package/dist/scp/index.js.map +1 -1
- package/dist/scp/index.mjs +729 -178
- package/dist/scp/makesql/authoring-compile.d.ts.map +1 -1
- package/dist/scp/makesql/authoring-compile.js +11 -0
- package/dist/scp/makesql/authoring-compile.js.map +1 -1
- package/dist/scp/makesql/index.d.ts +2 -3
- package/dist/scp/makesql/index.d.ts.map +1 -1
- package/dist/scp/makesql/index.js +6 -6
- package/dist/scp/makesql/index.js.map +1 -1
- package/dist/scp/makesql/json-batch.d.ts.map +1 -1
- package/dist/scp/makesql/json-batch.js +6 -1
- package/dist/scp/makesql/json-batch.js.map +1 -1
- package/dist/scp/makesql/outtype.d.ts +61 -6
- package/dist/scp/makesql/outtype.d.ts.map +1 -1
- package/dist/scp/makesql/outtype.js +164 -33
- package/dist/scp/makesql/outtype.js.map +1 -1
- package/dist/scp/makesql/pool-executor.d.ts +70 -0
- package/dist/scp/makesql/pool-executor.d.ts.map +1 -1
- package/dist/scp/makesql/pool-executor.js +73 -5
- package/dist/scp/makesql/pool-executor.js.map +1 -1
- package/dist/scp/makesql/static-bundle.d.ts +39 -30
- package/dist/scp/makesql/static-bundle.d.ts.map +1 -1
- package/dist/scp/makesql/static-bundle.js +269 -138
- package/dist/scp/makesql/static-bundle.js.map +1 -1
- package/dist/scp/makesql/writeouttype.d.ts +5 -6
- package/dist/scp/makesql/writeouttype.d.ts.map +1 -1
- package/dist/scp/makesql/writeouttype.js +5 -6
- package/dist/scp/makesql/writeouttype.js.map +1 -1
- package/dist/scp/relation.d.ts +15 -1
- package/dist/scp/relation.d.ts.map +1 -1
- package/dist/scp/relation.js +61 -2
- package/dist/scp/relation.js.map +1 -1
- package/dist/scp/runtime.d.ts +6 -5
- package/dist/scp/runtime.d.ts.map +1 -1
- package/dist/scp/runtime.js +27 -5
- package/dist/scp/runtime.js.map +1 -1
- package/docs/BENCHMARK.md +58 -56
- package/docs/benchmark-chart.svg +166 -166
- package/package.json +8 -2
- package/dist/scp/makesql/ir.d.ts +0 -42
- package/dist/scp/makesql/ir.d.ts.map +0 -1
- package/dist/scp/makesql/ir.js +0 -66
- package/dist/scp/makesql/ir.js.map +0 -1
package/dist/scp/index.d.ts
CHANGED
|
@@ -25,8 +25,8 @@
|
|
|
25
25
|
* remain exported (below) only for the historical WS test-suite; new code must use
|
|
26
26
|
* `./makesql`.
|
|
27
27
|
*/
|
|
28
|
-
export { MAKESQL, makeSqlCatalogEntry, LITEDBMODEL_MAKESQL_CATALOG, isMakeSQL, assembleMakeSQL, composeMakeSQL, renderPlaceholders, renderPorts, makeSqlHandler, makeSqlHandlerSync, compileWhere, whereClause, andTrailing, formatterFor, pgCastFormatter, noCastFormatter, compileSelect as compileSelectMakeSQL, builderFor, compileInsert as compileInsertMakeSQL, compileUpdateMany, compileUpdateSingle, compileDelete as compileDeleteMakeSQL, inferPgArrayType, resolvePgArrayCast, PG_ARRAY_CAST_TOKEN, compileSingleKeyUnlimited, compileSingleKeyLimited, compileCompositeKeyUnlimited, compileCompositeKeyStaticUnlimited, compileCompositeKeyLimited,
|
|
29
|
-
export type { MakeSQL, SqlParam, AssembledSql, Dialect as MakeSQLDialect, SqlExecutor, SqlExecutorSync, SqlExecutorAsync, SelectDesc as MakeSQLSelectDesc, RelationCompileBase, AuthoredMakeSQL, RelationMapInput, StaticBundle, StaticStatement, ValueSpec, ReadGraph, PgPoolLike, MysqlPoolLike, } from './makesql';
|
|
28
|
+
export { MAKESQL, makeSqlCatalogEntry, LITEDBMODEL_MAKESQL_CATALOG, isMakeSQL, assembleMakeSQL, composeMakeSQL, renderPlaceholders, renderPorts, makeSqlHandler, makeSqlHandlerSync, compileWhere, whereClause, andTrailing, formatterFor, pgCastFormatter, noCastFormatter, compileSelect as compileSelectMakeSQL, builderFor, compileInsert as compileInsertMakeSQL, compileUpdateMany, compileUpdateSingle, compileDelete as compileDeleteMakeSQL, inferPgArrayType, resolvePgArrayCast, PG_ARRAY_CAST_TOKEN, compileSingleKeyUnlimited, compileSingleKeyLimited, compileCompositeKeyUnlimited, compileCompositeKeyStaticUnlimited, compileCompositeKeyLimited, compileAuthoredBehavior, compileAuthoredNode, compileRelationMap, compileStaticBundle, compileSelectNode, executeStaticBundle, executeStaticWrite, executeReadBehavior, compileReadGraph, executeReadGraph, executeReadGraphAsync, renderReadPrimary, pgPoolExecutor, mysqlPoolExecutor, configurePgDeboxTypeParsers, mysqlDeboxPoolOptions, pgDeboxExecutor, mysqlDeboxExecutor, } from './makesql';
|
|
29
|
+
export type { MakeSQL, SqlParam, AssembledSql, Dialect as MakeSQLDialect, SqlExecutor, SqlExecutorSync, SqlExecutorAsync, SelectDesc as MakeSQLSelectDesc, RelationCompileBase, AuthoredMakeSQL, RelationMapInput, StaticBundle, StaticStatement, ValueSpec, ReadGraph, PgPoolLike, MysqlPoolLike, PgTypesLike, PgModuleLike, Mysql2ModuleLike, } from './makesql';
|
|
30
30
|
export { LITEDBMODEL_CATALOG, catalogEntry, CATALOG_NAMES, WRITE_CATALOG_NAMES, WRITE_PORT_FAMILIES, assertComponentsInCatalog, deriveContractEffect, } from './catalog';
|
|
31
31
|
export type { CatalogName, ContractEffect } from './catalog';
|
|
32
32
|
export { dialectFor, toDollarPlaceholders, SQLITE, POSTGRES, MYSQL } from './dialect';
|
|
@@ -34,14 +34,14 @@ export type { Dialect, DialectName } from './dialect';
|
|
|
34
34
|
export { assertExprPortable, assertComponentPortable, assertComponentGraphPortable, } from './guard';
|
|
35
35
|
export type { ExprNode } from './guard';
|
|
36
36
|
export { components, publishBehaviors, compileEager, } from './authoring';
|
|
37
|
-
export type { ComponentFns, BehaviorMethodSpec, BehaviorModelContract, PublishBehaviorsOptions, EagerBehavior, Component, ComponentGraphIR, MapNode, ComponentRefNode, } from './authoring';
|
|
37
|
+
export type { ComponentFns, BehaviorMethodSpec, BehaviorModelContract, PublishBehaviorsOptions, ModelColumns, TypedModelClass, EagerBehavior, Component, ComponentGraphIR, MapNode, ComponentRefNode, } from './authoring';
|
|
38
38
|
export { whereEq, whereNe, whereLt, whereLe, whereGt, whereGe, whereIsNull, whereIn, inColumn, whereBetween, whereLike, whereILike, whereCast, whereDynamic, whereImmediate, whereTupleIn, whereInSubquery, whereExists, } from './authoring-sql';
|
|
39
39
|
export { mapSqliteError, SqlFailure } from './errors';
|
|
40
40
|
export type { SqlFailureKind } from './errors';
|
|
41
41
|
export { assertFindFilterFolded, findFilterKeys, FindFilterLeakError } from './find-filter-guard';
|
|
42
42
|
export type { FindFilterSource } from './find-filter-guard';
|
|
43
|
-
export { sqlTypeToBcScalar, parseSchemaColumnTypes, schemaColumnTypeResolver } from './coltype';
|
|
44
|
-
export type { BcScalar, ColumnTypeResolver } from './coltype';
|
|
43
|
+
export { sqlTypeToBcScalar, sqlTypeToMaterializeClass, materializeCell, materializeClassOrUndefined, parseSchemaColumnTypes, schemaColumnTypeResolver, materializeResolverFromColumnMap, failClosedMaterializeResolverFromColumnMap, columnTypeResolverFromColumnMap } from './coltype';
|
|
44
|
+
export type { BcScalar, MaterializeClass, ColumnTypeResolver, MaterializeResolver } from './coltype';
|
|
45
45
|
export { executeBehavior, compileBundle, executeBundle, read, readBundle } from './runtime';
|
|
46
46
|
export type { SqliteDb, ExecuteOptions, SqlBundle, ReadRuntimeOptions } from './runtime';
|
|
47
47
|
export { executeBundleAsync, executeBehaviorAsync } from './runtime';
|
|
@@ -54,7 +54,8 @@ export { compileWriteBundle, executeCommand, executeTransactionBundle } from './
|
|
|
54
54
|
export { compileCompositeWriteBundle, executeCompositeCommand } from './runtime';
|
|
55
55
|
export type { CompositeWriteEntry } from './runtime';
|
|
56
56
|
export { compileCreateManyBundle, compileUpdateManyBundle, compileDeleteManyBundle } from './runtime';
|
|
57
|
-
export { compileDeleteMany } from './makesql';
|
|
57
|
+
export { compileDeleteMany, compileInsertMany } from './makesql';
|
|
58
|
+
export { dbCast, dbCastIn } from '../DBValues';
|
|
58
59
|
export { CODEGEN_LANGUAGES, CODEGEN_EMITTER, generateCodegenArtifact, bundleToPortableIR, lowerReadGraphForTypedNative, codegenEmitterFor, typedEmitterFor, codegenExecuteBundleForTest, TypedNativeCoverageError, } from './codegen';
|
|
59
60
|
export type { CodegenLanguage, SqlCatalogCompanion, CodegenArtifact, } from './codegen';
|
|
60
61
|
export { compileRelationOp, runRelationOp, distributeToParent, RELATION_KEYS_HEAD, } from './relation';
|
package/dist/scp/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/scp/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AAGH,OAAO,EACL,OAAO,EACP,mBAAmB,EACnB,2BAA2B,EAC3B,SAAS,EACT,eAAe,EACf,cAAc,EACd,kBAAkB,EAClB,WAAW,EACX,cAAc,EACd,kBAAkB,EAClB,YAAY,EACZ,WAAW,EACX,WAAW,EACX,YAAY,EACZ,eAAe,EACf,eAAe,EACf,aAAa,IAAI,oBAAoB,EACrC,UAAU,EACV,aAAa,IAAI,oBAAoB,EACrC,iBAAiB,EACjB,mBAAmB,EACnB,aAAa,IAAI,oBAAoB,EACrC,gBAAgB,EAChB,kBAAkB,EAClB,mBAAmB,EACnB,yBAAyB,EACzB,uBAAuB,EACvB,4BAA4B,EAC5B,kCAAkC,EAClC,0BAA0B,EAC1B,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/scp/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AAGH,OAAO,EACL,OAAO,EACP,mBAAmB,EACnB,2BAA2B,EAC3B,SAAS,EACT,eAAe,EACf,cAAc,EACd,kBAAkB,EAClB,WAAW,EACX,cAAc,EACd,kBAAkB,EAClB,YAAY,EACZ,WAAW,EACX,WAAW,EACX,YAAY,EACZ,eAAe,EACf,eAAe,EACf,aAAa,IAAI,oBAAoB,EACrC,UAAU,EACV,aAAa,IAAI,oBAAoB,EACrC,iBAAiB,EACjB,mBAAmB,EACnB,aAAa,IAAI,oBAAoB,EACrC,gBAAgB,EAChB,kBAAkB,EAClB,mBAAmB,EACnB,yBAAyB,EACzB,uBAAuB,EACvB,4BAA4B,EAC5B,kCAAkC,EAClC,0BAA0B,EAC1B,uB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Y,EACZ,UAAU,EACV,aAAa,EACb,cAAc,GACf,MAAM,YAAY,CAAC;AAGpB,OAAO,EACL,cAAc,EACd,mBAAmB,EACnB,eAAe,EACf,gBAAgB,GACjB,MAAM,gBAAgB,CAAC;AACxB,YAAY,EAAE,cAAc,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAKlE,OAAO,EACL,gBAAgB,EAChB,QAAQ,EACR,IAAI,EACJ,MAAM,EACN,GAAG,EACH,GAAG,EACH,GAAG,EACH,GAAG,EACH,GAAG,EACH,GAAG,EACH,EAAE,EACF,EAAE,EACF,EAAE,EACF,EAAE,EACF,EAAE,EACF,EAAE,EACF,GAAG,EACH,EAAE,EACF,GAAG,EACH,QAAQ,EACR,GAAG,EACH,GAAG,GACJ,MAAM,oBAAoB,CAAC;AAC5B,YAAY,EAAE,EAAE,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC"}
|
package/dist/scp/index.js
CHANGED
|
@@ -27,10 +27,10 @@
|
|
|
27
27
|
* `./makesql`.
|
|
28
28
|
*/
|
|
29
29
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
30
|
-
exports.
|
|
31
|
-
exports.
|
|
32
|
-
exports.
|
|
33
|
-
exports.opt = exports.len = exports.coalesce = exports.not = exports.or = exports.and = exports.ge = void 0;
|
|
30
|
+
exports.catalogEntry = exports.LITEDBMODEL_CATALOG = exports.mysqlDeboxExecutor = exports.pgDeboxExecutor = exports.mysqlDeboxPoolOptions = exports.configurePgDeboxTypeParsers = exports.mysqlPoolExecutor = exports.pgPoolExecutor = exports.renderReadPrimary = exports.executeReadGraphAsync = exports.executeReadGraph = exports.compileReadGraph = exports.executeReadBehavior = exports.executeStaticWrite = exports.executeStaticBundle = exports.compileSelectNode = exports.compileStaticBundle = exports.compileRelationMap = exports.compileAuthoredNode = exports.compileAuthoredBehavior = exports.compileCompositeKeyLimited = exports.compileCompositeKeyStaticUnlimited = exports.compileCompositeKeyUnlimited = exports.compileSingleKeyLimited = exports.compileSingleKeyUnlimited = exports.PG_ARRAY_CAST_TOKEN = exports.resolvePgArrayCast = exports.inferPgArrayType = exports.compileDeleteMakeSQL = exports.compileUpdateSingle = exports.compileUpdateMany = exports.compileInsertMakeSQL = exports.builderFor = exports.compileSelectMakeSQL = exports.noCastFormatter = exports.pgCastFormatter = exports.formatterFor = exports.andTrailing = exports.whereClause = exports.compileWhere = exports.makeSqlHandlerSync = exports.makeSqlHandler = exports.renderPorts = exports.renderPlaceholders = exports.composeMakeSQL = exports.assembleMakeSQL = exports.isMakeSQL = exports.LITEDBMODEL_MAKESQL_CATALOG = exports.makeSqlCatalogEntry = exports.MAKESQL = void 0;
|
|
31
|
+
exports.compileBundle = exports.executeBehavior = exports.columnTypeResolverFromColumnMap = exports.failClosedMaterializeResolverFromColumnMap = exports.materializeResolverFromColumnMap = exports.schemaColumnTypeResolver = exports.parseSchemaColumnTypes = exports.materializeClassOrUndefined = exports.materializeCell = exports.sqlTypeToMaterializeClass = exports.sqlTypeToBcScalar = exports.FindFilterLeakError = exports.findFilterKeys = exports.assertFindFilterFolded = exports.SqlFailure = exports.mapSqliteError = exports.whereExists = exports.whereInSubquery = exports.whereTupleIn = exports.whereImmediate = exports.whereDynamic = exports.whereCast = exports.whereILike = exports.whereLike = exports.whereBetween = exports.inColumn = exports.whereIn = exports.whereIsNull = exports.whereGe = exports.whereGt = exports.whereLe = exports.whereLt = exports.whereNe = exports.whereEq = exports.compileEager = exports.publishBehaviors = exports.components = exports.assertComponentGraphPortable = exports.assertComponentPortable = exports.assertExprPortable = exports.MYSQL = exports.POSTGRES = exports.SQLITE = exports.toDollarPlaceholders = exports.dialectFor = exports.deriveContractEffect = exports.assertComponentsInCatalog = exports.WRITE_PORT_FAMILIES = exports.WRITE_CATALOG_NAMES = exports.CATALOG_NAMES = void 0;
|
|
32
|
+
exports.concat = exports.when = exports.behavior = exports.SemanticBehavior = exports.RELATION_CONTEXT = exports.RelationContext = exports.readRelationContext = exports.buildResultSet = exports.RELATION_KEYS_HEAD = exports.distributeToParent = exports.runRelationOp = exports.compileRelationOp = exports.TypedNativeCoverageError = exports.codegenExecuteBundleForTest = exports.typedEmitterFor = exports.codegenEmitterFor = exports.lowerReadGraphForTypedNative = exports.bundleToPortableIR = exports.generateCodegenArtifact = exports.CODEGEN_EMITTER = exports.CODEGEN_LANGUAGES = exports.dbCastIn = exports.dbCast = exports.compileInsertMany = exports.compileDeleteMany = exports.compileDeleteManyBundle = exports.compileUpdateManyBundle = exports.compileCreateManyBundle = exports.executeCompositeCommand = exports.compileCompositeWriteBundle = exports.executeTransactionBundle = exports.executeCommand = exports.compileWriteBundle = exports.stripMysqlPkHint = exports.mysqlPkHint = exports.compileWriteNode = exports.renderTxStatement = exports.countingDriver = exports.executeTransaction = exports.deriveTransactionPlan = exports.ENTITY_ROOT = exports.parseEffectPath = exports.lifecycleFor = exports.edgeWrites = exports.entityWrites = exports.executeBehaviorAsync = exports.executeBundleAsync = exports.readBundle = exports.read = exports.executeBundle = void 0;
|
|
33
|
+
exports.opt = exports.len = exports.coalesce = exports.not = exports.or = exports.and = exports.ge = exports.gt = exports.le = exports.lt = exports.ne = exports.eq = exports.neg = exports.mod = exports.div = exports.mul = exports.sub = exports.add = void 0;
|
|
34
34
|
// ── CANONICAL: the LOCKED `makeSQL` bc integration (epic #43 / design #45). ──────────
|
|
35
35
|
var makesql_1 = require("./makesql");
|
|
36
36
|
Object.defineProperty(exports, "MAKESQL", { enumerable: true, get: function () { return makesql_1.MAKESQL; } });
|
|
@@ -63,8 +63,6 @@ Object.defineProperty(exports, "compileSingleKeyLimited", { enumerable: true, ge
|
|
|
63
63
|
Object.defineProperty(exports, "compileCompositeKeyUnlimited", { enumerable: true, get: function () { return makesql_1.compileCompositeKeyUnlimited; } });
|
|
64
64
|
Object.defineProperty(exports, "compileCompositeKeyStaticUnlimited", { enumerable: true, get: function () { return makesql_1.compileCompositeKeyStaticUnlimited; } });
|
|
65
65
|
Object.defineProperty(exports, "compileCompositeKeyLimited", { enumerable: true, get: function () { return makesql_1.compileCompositeKeyLimited; } });
|
|
66
|
-
Object.defineProperty(exports, "makeSqlComponentIR", { enumerable: true, get: function () { return makesql_1.makeSqlComponentIR; } });
|
|
67
|
-
Object.defineProperty(exports, "makeSqlInput", { enumerable: true, get: function () { return makesql_1.makeSqlInput; } });
|
|
68
66
|
Object.defineProperty(exports, "compileAuthoredBehavior", { enumerable: true, get: function () { return makesql_1.compileAuthoredBehavior; } });
|
|
69
67
|
Object.defineProperty(exports, "compileAuthoredNode", { enumerable: true, get: function () { return makesql_1.compileAuthoredNode; } });
|
|
70
68
|
Object.defineProperty(exports, "compileRelationMap", { enumerable: true, get: function () { return makesql_1.compileRelationMap; } });
|
|
@@ -79,6 +77,10 @@ Object.defineProperty(exports, "executeReadGraphAsync", { enumerable: true, get:
|
|
|
79
77
|
Object.defineProperty(exports, "renderReadPrimary", { enumerable: true, get: function () { return makesql_1.renderReadPrimary; } });
|
|
80
78
|
Object.defineProperty(exports, "pgPoolExecutor", { enumerable: true, get: function () { return makesql_1.pgPoolExecutor; } });
|
|
81
79
|
Object.defineProperty(exports, "mysqlPoolExecutor", { enumerable: true, get: function () { return makesql_1.mysqlPoolExecutor; } });
|
|
80
|
+
Object.defineProperty(exports, "configurePgDeboxTypeParsers", { enumerable: true, get: function () { return makesql_1.configurePgDeboxTypeParsers; } });
|
|
81
|
+
Object.defineProperty(exports, "mysqlDeboxPoolOptions", { enumerable: true, get: function () { return makesql_1.mysqlDeboxPoolOptions; } });
|
|
82
|
+
Object.defineProperty(exports, "pgDeboxExecutor", { enumerable: true, get: function () { return makesql_1.pgDeboxExecutor; } });
|
|
83
|
+
Object.defineProperty(exports, "mysqlDeboxExecutor", { enumerable: true, get: function () { return makesql_1.mysqlDeboxExecutor; } });
|
|
82
84
|
// Catalog (spec §11 item 1)
|
|
83
85
|
var catalog_1 = require("./catalog");
|
|
84
86
|
Object.defineProperty(exports, "LITEDBMODEL_CATALOG", { enumerable: true, get: function () { return catalog_1.LITEDBMODEL_CATALOG; } });
|
|
@@ -142,8 +144,14 @@ Object.defineProperty(exports, "FindFilterLeakError", { enumerable: true, get: f
|
|
|
142
144
|
// resolver that types a SELECT projection for typed (de-boxed) codegen. Fail-closed throughout.
|
|
143
145
|
var coltype_1 = require("./coltype");
|
|
144
146
|
Object.defineProperty(exports, "sqlTypeToBcScalar", { enumerable: true, get: function () { return coltype_1.sqlTypeToBcScalar; } });
|
|
147
|
+
Object.defineProperty(exports, "sqlTypeToMaterializeClass", { enumerable: true, get: function () { return coltype_1.sqlTypeToMaterializeClass; } });
|
|
148
|
+
Object.defineProperty(exports, "materializeCell", { enumerable: true, get: function () { return coltype_1.materializeCell; } });
|
|
149
|
+
Object.defineProperty(exports, "materializeClassOrUndefined", { enumerable: true, get: function () { return coltype_1.materializeClassOrUndefined; } });
|
|
145
150
|
Object.defineProperty(exports, "parseSchemaColumnTypes", { enumerable: true, get: function () { return coltype_1.parseSchemaColumnTypes; } });
|
|
146
151
|
Object.defineProperty(exports, "schemaColumnTypeResolver", { enumerable: true, get: function () { return coltype_1.schemaColumnTypeResolver; } });
|
|
152
|
+
Object.defineProperty(exports, "materializeResolverFromColumnMap", { enumerable: true, get: function () { return coltype_1.materializeResolverFromColumnMap; } });
|
|
153
|
+
Object.defineProperty(exports, "failClosedMaterializeResolverFromColumnMap", { enumerable: true, get: function () { return coltype_1.failClosedMaterializeResolverFromColumnMap; } });
|
|
154
|
+
Object.defineProperty(exports, "columnTypeResolverFromColumnMap", { enumerable: true, get: function () { return coltype_1.columnTypeResolverFromColumnMap; } });
|
|
147
155
|
// Thin TS runtime (spec §3 / §10 / §11): validate → SKIP → expand → eval → bind → execute → assembly.
|
|
148
156
|
// `compileBundle` emits the §8 published artifact (Backend-Compiled once, TS-side);
|
|
149
157
|
// `executeBundle` runs that artifact via bc runtime-core alone (the multi-language target).
|
|
@@ -193,6 +201,13 @@ Object.defineProperty(exports, "compileUpdateManyBundle", { enumerable: true, ge
|
|
|
193
201
|
Object.defineProperty(exports, "compileDeleteManyBundle", { enumerable: true, get: function () { return runtime_5.compileDeleteManyBundle; } });
|
|
194
202
|
var makesql_3 = require("./makesql");
|
|
195
203
|
Object.defineProperty(exports, "compileDeleteMany", { enumerable: true, get: function () { return makesql_3.compileDeleteMany; } });
|
|
204
|
+
Object.defineProperty(exports, "compileInsertMany", { enumerable: true, get: function () { return makesql_3.compileInsertMany; } });
|
|
205
|
+
// dbCast: the column-type cast marker the makeSQL compilers thread into WHERE/SET (spec §4.1).
|
|
206
|
+
// Re-exported so a bundle consumer builds the SAME DBCast instance the inlined compilers recognise
|
|
207
|
+
// (a standalone dist/DBValues copy is a DIFFERENT class → the compiler would not honour the cast).
|
|
208
|
+
var DBValues_1 = require("../DBValues");
|
|
209
|
+
Object.defineProperty(exports, "dbCast", { enumerable: true, get: function () { return DBValues_1.dbCast; } });
|
|
210
|
+
Object.defineProperty(exports, "dbCastIn", { enumerable: true, get: function () { return DBValues_1.dbCastIn; } });
|
|
196
211
|
// Mode-3 codegen (WS7f, #35 — spec §9 exec-mode 3): supply the litedbmodel SQL catalog to bc's
|
|
197
212
|
// shared generator; emit per-language STATIC straight-line source (de-interpreted, bc#75 — real
|
|
198
213
|
// static code, NOT a baked-IR interpret path) + the SQL catalog companion. Generated code is
|
package/dist/scp/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/scp/index.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;;;;;;AAEH,wFAAwF;AACxF,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/scp/index.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;;;;;;AAEH,wFAAwF;AACxF,qCAiDmB;AAhDjB,kGAAA,OAAO,OAAA;AACP,8GAAA,mBAAmB,OAAA;AACnB,sHAAA,2BAA2B,OAAA;AAC3B,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