hikoutei 0.2.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/LICENSE +21 -0
- package/README.ja.md +135 -0
- package/README.ko.md +138 -0
- package/README.md +143 -0
- package/apps-script/gateway/Code.gs +412 -0
- package/dist/adapter/persistence/contracts/index.d.ts +3 -0
- package/dist/adapter/persistence/contracts/index.d.ts.map +1 -0
- package/dist/adapter/persistence/contracts/index.js +3 -0
- package/dist/adapter/persistence/contracts/index.js.map +1 -0
- package/dist/adapter/persistence/contracts/sql.d.ts +50 -0
- package/dist/adapter/persistence/contracts/sql.d.ts.map +1 -0
- package/dist/adapter/persistence/contracts/sql.js +9 -0
- package/dist/adapter/persistence/contracts/sql.js.map +1 -0
- package/dist/adapter/persistence/index.d.ts +2 -0
- package/dist/adapter/persistence/index.d.ts.map +1 -0
- package/dist/adapter/persistence/index.js +2 -0
- package/dist/adapter/persistence/index.js.map +1 -0
- package/dist/adapter/persistence/providers/mikro-orm/api/MikroOrmTypedSheetsEntityManager.d.ts +53 -0
- package/dist/adapter/persistence/providers/mikro-orm/api/MikroOrmTypedSheetsEntityManager.d.ts.map +1 -0
- package/dist/adapter/persistence/providers/mikro-orm/api/MikroOrmTypedSheetsEntityManager.js +105 -0
- package/dist/adapter/persistence/providers/mikro-orm/api/MikroOrmTypedSheetsEntityManager.js.map +1 -0
- package/dist/adapter/persistence/providers/mikro-orm/engine/MikroOrmMappedTypedSheets.d.ts +39 -0
- package/dist/adapter/persistence/providers/mikro-orm/engine/MikroOrmMappedTypedSheets.d.ts.map +1 -0
- package/dist/adapter/persistence/providers/mikro-orm/engine/MikroOrmMappedTypedSheets.js +54 -0
- package/dist/adapter/persistence/providers/mikro-orm/engine/MikroOrmMappedTypedSheets.js.map +1 -0
- package/dist/adapter/persistence/providers/mikro-orm/engine/MikroOrmTypedSheetsEngine.d.ts +38 -0
- package/dist/adapter/persistence/providers/mikro-orm/engine/MikroOrmTypedSheetsEngine.d.ts.map +1 -0
- package/dist/adapter/persistence/providers/mikro-orm/engine/MikroOrmTypedSheetsEngine.js +55 -0
- package/dist/adapter/persistence/providers/mikro-orm/engine/MikroOrmTypedSheetsEngine.js.map +1 -0
- package/dist/adapter/persistence/providers/mikro-orm/index.d.ts +16 -0
- package/dist/adapter/persistence/providers/mikro-orm/index.d.ts.map +1 -0
- package/dist/adapter/persistence/providers/mikro-orm/index.js +9 -0
- package/dist/adapter/persistence/providers/mikro-orm/index.js.map +1 -0
- package/dist/adapter/persistence/providers/mikro-orm/observation/MikroOrmMappedObservation.d.ts +27 -0
- package/dist/adapter/persistence/providers/mikro-orm/observation/MikroOrmMappedObservation.d.ts.map +1 -0
- package/dist/adapter/persistence/providers/mikro-orm/observation/MikroOrmMappedObservation.js +67 -0
- package/dist/adapter/persistence/providers/mikro-orm/observation/MikroOrmMappedObservation.js.map +1 -0
- package/dist/adapter/persistence/providers/mikro-orm/storage/MikroOrmFlushChanges.d.ts +19 -0
- package/dist/adapter/persistence/providers/mikro-orm/storage/MikroOrmFlushChanges.d.ts.map +1 -0
- package/dist/adapter/persistence/providers/mikro-orm/storage/MikroOrmFlushChanges.js +67 -0
- package/dist/adapter/persistence/providers/mikro-orm/storage/MikroOrmFlushChanges.js.map +1 -0
- package/dist/adapter/persistence/providers/mikro-orm/storage/MikroOrmSqliteAdapter.d.ts +78 -0
- package/dist/adapter/persistence/providers/mikro-orm/storage/MikroOrmSqliteAdapter.d.ts.map +1 -0
- package/dist/adapter/persistence/providers/mikro-orm/storage/MikroOrmSqliteAdapter.js +121 -0
- package/dist/adapter/persistence/providers/mikro-orm/storage/MikroOrmSqliteAdapter.js.map +1 -0
- package/dist/adapter/persistence/providers/mikro-orm/storage/MikroOrmSqliteSchema.d.ts +20 -0
- package/dist/adapter/persistence/providers/mikro-orm/storage/MikroOrmSqliteSchema.d.ts.map +1 -0
- package/dist/adapter/persistence/providers/mikro-orm/storage/MikroOrmSqliteSchema.js +125 -0
- package/dist/adapter/persistence/providers/mikro-orm/storage/MikroOrmSqliteSchema.js.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/errors.d.ts +42 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/errors.d.ts.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/errors.js +51 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/errors.js.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/index.d.ts +22 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/index.d.ts.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/index.js +12 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/index.js.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/operations/effect/effectOperation.d.ts +42 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/operations/effect/effectOperation.d.ts.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/operations/effect/effectOperation.js +161 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/operations/effect/effectOperation.js.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/operations/effect/effectOperationScript.d.ts +3 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/operations/effect/effectOperationScript.d.ts.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/operations/effect/effectOperationScript.js +692 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/operations/effect/effectOperationScript.js.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/operations/observation/observationOperation.d.ts +29 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/operations/observation/observationOperation.d.ts.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/operations/observation/observationOperation.js +538 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/operations/observation/observationOperation.js.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/operations/read/tableReadOperation.d.ts +12 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/operations/read/tableReadOperation.d.ts.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/operations/read/tableReadOperation.js +190 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/operations/read/tableReadOperation.js.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/operations/write/fastAppendOperation.d.ts +23 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/operations/write/fastAppendOperation.d.ts.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/operations/write/fastAppendOperation.js +166 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/operations/write/fastAppendOperation.js.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/codeGsProtocol.d.ts +50 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/codeGsProtocol.d.ts.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/codeGsProtocol.js +60 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/codeGsProtocol.js.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/constants.d.ts +44 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/constants.d.ts.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/constants.js +40 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/constants.js.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/syncProtocol.d.ts +7 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/syncProtocol.d.ts.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/syncProtocol.js +47 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/syncProtocol.js.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/timing.d.ts +5 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/timing.d.ts.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/timing.js +54 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/timing.js.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/types.d.ts +5 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/types.d.ts.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/types.js +2 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/types.js.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/validation.d.ts +10 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/validation.d.ts.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/validation.js +35 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/protocol/validation.js.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/transport/operationClient.d.ts +67 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/transport/operationClient.d.ts.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/transport/operationClient.js +204 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/transport/operationClient.js.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/transport/operationSyncGateway.d.ts +78 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/transport/operationSyncGateway.d.ts.map +1 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/transport/operationSyncGateway.js +343 -0
- package/dist/adapter/sheets/providers/apps-script-gateway/transport/operationSyncGateway.js.map +1 -0
- package/dist/application/index.d.ts +4 -0
- package/dist/application/index.d.ts.map +1 -0
- package/dist/application/index.js +4 -0
- package/dist/application/index.js.map +1 -0
- package/dist/application/orm/api/TypedSheetsOrm.d.ts +71 -0
- package/dist/application/orm/api/TypedSheetsOrm.d.ts.map +1 -0
- package/dist/application/orm/api/TypedSheetsOrm.js +116 -0
- package/dist/application/orm/api/TypedSheetsOrm.js.map +1 -0
- package/dist/application/orm/api/contracts.d.ts +118 -0
- package/dist/application/orm/api/contracts.d.ts.map +1 -0
- package/dist/application/orm/api/contracts.js +21 -0
- package/dist/application/orm/api/contracts.js.map +1 -0
- package/dist/application/orm/errors.d.ts +35 -0
- package/dist/application/orm/errors.d.ts.map +1 -0
- package/dist/application/orm/errors.js +35 -0
- package/dist/application/orm/errors.js.map +1 -0
- package/dist/application/orm/index.d.ts +13 -0
- package/dist/application/orm/index.d.ts.map +1 -0
- package/dist/application/orm/index.js +7 -0
- package/dist/application/orm/index.js.map +1 -0
- package/dist/application/orm/mapping/contracts.d.ts +113 -0
- package/dist/application/orm/mapping/contracts.d.ts.map +1 -0
- package/dist/application/orm/mapping/contracts.js +8 -0
- package/dist/application/orm/mapping/contracts.js.map +1 -0
- package/dist/application/orm/mapping/definition.d.ts +16 -0
- package/dist/application/orm/mapping/definition.d.ts.map +1 -0
- package/dist/application/orm/mapping/definition.js +145 -0
- package/dist/application/orm/mapping/definition.js.map +1 -0
- package/dist/application/orm/mapping/entityMapping.d.ts +13 -0
- package/dist/application/orm/mapping/entityMapping.d.ts.map +1 -0
- package/dist/application/orm/mapping/entityMapping.js +13 -0
- package/dist/application/orm/mapping/entityMapping.js.map +1 -0
- package/dist/application/orm/mapping/identity.d.ts +14 -0
- package/dist/application/orm/mapping/identity.d.ts.map +1 -0
- package/dist/application/orm/mapping/identity.js +37 -0
- package/dist/application/orm/mapping/identity.js.map +1 -0
- package/dist/application/orm/mapping/observationMapping.d.ts +42 -0
- package/dist/application/orm/mapping/observationMapping.d.ts.map +1 -0
- package/dist/application/orm/mapping/observationMapping.js +65 -0
- package/dist/application/orm/mapping/observationMapping.js.map +1 -0
- package/dist/application/orm/mapping/projection.d.ts +22 -0
- package/dist/application/orm/mapping/projection.d.ts.map +1 -0
- package/dist/application/orm/mapping/projection.js +74 -0
- package/dist/application/orm/mapping/projection.js.map +1 -0
- package/dist/application/orm/mapping/registry.d.ts +15 -0
- package/dist/application/orm/mapping/registry.d.ts.map +1 -0
- package/dist/application/orm/mapping/registry.js +38 -0
- package/dist/application/orm/mapping/registry.js.map +1 -0
- package/dist/application/orm/mapping/values.d.ts +17 -0
- package/dist/application/orm/mapping/values.d.ts.map +1 -0
- package/dist/application/orm/mapping/values.js +141 -0
- package/dist/application/orm/mapping/values.js.map +1 -0
- package/dist/application/orm/persistence/flush/flushCoordinator.d.ts +28 -0
- package/dist/application/orm/persistence/flush/flushCoordinator.d.ts.map +1 -0
- package/dist/application/orm/persistence/flush/flushCoordinator.js +170 -0
- package/dist/application/orm/persistence/flush/flushCoordinator.js.map +1 -0
- package/dist/application/orm/persistence/flush/mappedFlushCoordinator.d.ts +9 -0
- package/dist/application/orm/persistence/flush/mappedFlushCoordinator.d.ts.map +1 -0
- package/dist/application/orm/persistence/flush/mappedFlushCoordinator.js +8 -0
- package/dist/application/orm/persistence/flush/mappedFlushCoordinator.js.map +1 -0
- package/dist/application/orm/persistence/lifecycle/entityLifecycle.d.ts +12 -0
- package/dist/application/orm/persistence/lifecycle/entityLifecycle.d.ts.map +1 -0
- package/dist/application/orm/persistence/lifecycle/entityLifecycle.js +134 -0
- package/dist/application/orm/persistence/lifecycle/entityLifecycle.js.map +1 -0
- package/dist/application/orm/persistence/projection/projectionEffects.d.ts +21 -0
- package/dist/application/orm/persistence/projection/projectionEffects.d.ts.map +1 -0
- package/dist/application/orm/persistence/projection/projectionEffects.js +203 -0
- package/dist/application/orm/persistence/projection/projectionEffects.js.map +1 -0
- package/dist/application/orm/persistence/support/businessKeys.d.ts +17 -0
- package/dist/application/orm/persistence/support/businessKeys.d.ts.map +1 -0
- package/dist/application/orm/persistence/support/businessKeys.js +72 -0
- package/dist/application/orm/persistence/support/businessKeys.js.map +1 -0
- package/dist/application/orm/persistence/support/canonicalState.d.ts +22 -0
- package/dist/application/orm/persistence/support/canonicalState.d.ts.map +1 -0
- package/dist/application/orm/persistence/support/canonicalState.js +88 -0
- package/dist/application/orm/persistence/support/canonicalState.js.map +1 -0
- package/dist/application/orm/persistence/support/contracts.d.ts +139 -0
- package/dist/application/orm/persistence/support/contracts.d.ts.map +1 -0
- package/dist/application/orm/persistence/support/contracts.js +93 -0
- package/dist/application/orm/persistence/support/contracts.js.map +1 -0
- package/dist/application/orm/persistence/support/helpers.d.ts +32 -0
- package/dist/application/orm/persistence/support/helpers.d.ts.map +1 -0
- package/dist/application/orm/persistence/support/helpers.js +66 -0
- package/dist/application/orm/persistence/support/helpers.js.map +1 -0
- package/dist/application/orm/persistence/support/timing.d.ts +20 -0
- package/dist/application/orm/persistence/support/timing.d.ts.map +1 -0
- package/dist/application/orm/persistence/support/timing.js +55 -0
- package/dist/application/orm/persistence/support/timing.js.map +1 -0
- package/dist/application/sync/gateway/SyncGatewayBootstrap.d.ts +46 -0
- package/dist/application/sync/gateway/SyncGatewayBootstrap.d.ts.map +1 -0
- package/dist/application/sync/gateway/SyncGatewayBootstrap.js +93 -0
- package/dist/application/sync/gateway/SyncGatewayBootstrap.js.map +1 -0
- package/dist/application/sync/gateway/constants.d.ts +65 -0
- package/dist/application/sync/gateway/constants.d.ts.map +1 -0
- package/dist/application/sync/gateway/constants.js +57 -0
- package/dist/application/sync/gateway/constants.js.map +1 -0
- package/dist/application/sync/gateway/errors.d.ts +15 -0
- package/dist/application/sync/gateway/errors.d.ts.map +1 -0
- package/dist/application/sync/gateway/errors.js +16 -0
- package/dist/application/sync/gateway/errors.js.map +1 -0
- package/dist/application/sync/gateway/syncGateway.d.ts +313 -0
- package/dist/application/sync/gateway/syncGateway.d.ts.map +1 -0
- package/dist/application/sync/gateway/syncGateway.js +202 -0
- package/dist/application/sync/gateway/syncGateway.js.map +1 -0
- package/dist/application/sync/gateway/validation.d.ts +17 -0
- package/dist/application/sync/gateway/validation.d.ts.map +1 -0
- package/dist/application/sync/gateway/validation.js +60 -0
- package/dist/application/sync/gateway/validation.js.map +1 -0
- package/dist/application/sync/inbound/polling/SimpleSheetPolling.d.ts +72 -0
- package/dist/application/sync/inbound/polling/SimpleSheetPolling.d.ts.map +1 -0
- package/dist/application/sync/inbound/polling/SimpleSheetPolling.js +272 -0
- package/dist/application/sync/inbound/polling/SimpleSheetPolling.js.map +1 -0
- package/dist/application/sync/index.d.ts +16 -0
- package/dist/application/sync/index.d.ts.map +1 -0
- package/dist/application/sync/index.js +9 -0
- package/dist/application/sync/index.js.map +1 -0
- package/dist/application/sync/outbound/effects/SyncEffectSupervisor.d.ts +106 -0
- package/dist/application/sync/outbound/effects/SyncEffectSupervisor.d.ts.map +1 -0
- package/dist/application/sync/outbound/effects/SyncEffectSupervisor.js +297 -0
- package/dist/application/sync/outbound/effects/SyncEffectSupervisor.js.map +1 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorker.d.ts +100 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorker.d.ts.map +1 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorker.js +345 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorker.js.map +1 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerConstants.d.ts +46 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerConstants.d.ts.map +1 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerConstants.js +63 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerConstants.js.map +1 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerDispatch.d.ts +20 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerDispatch.d.ts.map +1 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerDispatch.js +102 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerDispatch.js.map +1 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerHelpers.d.ts +19 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerHelpers.d.ts.map +1 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerHelpers.js +32 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerHelpers.js.map +1 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerRouting.d.ts +30 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerRouting.d.ts.map +1 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerRouting.js +202 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerRouting.js.map +1 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerTiming.d.ts +17 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerTiming.d.ts.map +1 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerTiming.js +80 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerTiming.js.map +1 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerTransitions.d.ts +13 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerTransitions.d.ts.map +1 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerTransitions.js +205 -0
- package/dist/application/sync/outbound/effects/SyncEffectWorkerTransitions.js.map +1 -0
- package/dist/application/sync/outbound/projection/ProjectionEffectFactory.d.ts +81 -0
- package/dist/application/sync/outbound/projection/ProjectionEffectFactory.d.ts.map +1 -0
- package/dist/application/sync/outbound/projection/ProjectionEffectFactory.js +245 -0
- package/dist/application/sync/outbound/projection/ProjectionEffectFactory.js.map +1 -0
- package/dist/application/sync/outbound/reconciliation/ReconciliationScanner.d.ts +77 -0
- package/dist/application/sync/outbound/reconciliation/ReconciliationScanner.d.ts.map +1 -0
- package/dist/application/sync/outbound/reconciliation/ReconciliationScanner.js +518 -0
- package/dist/application/sync/outbound/reconciliation/ReconciliationScanner.js.map +1 -0
- package/dist/application/sync/telemetry/syncTiming.d.ts +50 -0
- package/dist/application/sync/telemetry/syncTiming.d.ts.map +1 -0
- package/dist/application/sync/telemetry/syncTiming.js +22 -0
- package/dist/application/sync/telemetry/syncTiming.js.map +1 -0
- package/dist/domain/conflict/errors.d.ts +42 -0
- package/dist/domain/conflict/errors.d.ts.map +1 -0
- package/dist/domain/conflict/errors.js +36 -0
- package/dist/domain/conflict/errors.js.map +1 -0
- package/dist/domain/conflict/index.d.ts +5 -0
- package/dist/domain/conflict/index.d.ts.map +1 -0
- package/dist/domain/conflict/index.js +3 -0
- package/dist/domain/conflict/index.js.map +1 -0
- package/dist/domain/conflict/transitions.d.ts +52 -0
- package/dist/domain/conflict/transitions.d.ts.map +1 -0
- package/dist/domain/conflict/transitions.js +115 -0
- package/dist/domain/conflict/transitions.js.map +1 -0
- package/dist/domain/errors/evaluation.d.ts +13 -0
- package/dist/domain/errors/evaluation.d.ts.map +1 -0
- package/dist/domain/errors/evaluation.js +14 -0
- package/dist/domain/errors/evaluation.js.map +1 -0
- package/dist/domain/errors/identity.d.ts +12 -0
- package/dist/domain/errors/identity.d.ts.map +1 -0
- package/dist/domain/errors/identity.js +15 -0
- package/dist/domain/errors/identity.js.map +1 -0
- package/dist/domain/errors/index.d.ts +7 -0
- package/dist/domain/errors/index.d.ts.map +1 -0
- package/dist/domain/errors/index.js +5 -0
- package/dist/domain/errors/index.js.map +1 -0
- package/dist/domain/errors/stableEncoding.d.ts +7 -0
- package/dist/domain/errors/stableEncoding.d.ts.map +1 -0
- package/dist/domain/errors/stableEncoding.js +8 -0
- package/dist/domain/errors/stableEncoding.js.map +1 -0
- package/dist/domain/errors/types.d.ts +20 -0
- package/dist/domain/errors/types.d.ts.map +1 -0
- package/dist/domain/errors/types.js +18 -0
- package/dist/domain/errors/types.js.map +1 -0
- package/dist/domain/evaluate/constants.d.ts +55 -0
- package/dist/domain/evaluate/constants.d.ts.map +1 -0
- package/dist/domain/evaluate/constants.js +41 -0
- package/dist/domain/evaluate/constants.js.map +1 -0
- package/dist/domain/evaluate/contracts.d.ts +125 -0
- package/dist/domain/evaluate/contracts.d.ts.map +1 -0
- package/dist/domain/evaluate/contracts.js +8 -0
- package/dist/domain/evaluate/contracts.js.map +1 -0
- package/dist/domain/evaluate/evaluateBatch.d.ts +11 -0
- package/dist/domain/evaluate/evaluateBatch.d.ts.map +1 -0
- package/dist/domain/evaluate/evaluateBatch.js +91 -0
- package/dist/domain/evaluate/evaluateBatch.js.map +1 -0
- package/dist/domain/evaluate/fieldEvaluation.d.ts +14 -0
- package/dist/domain/evaluate/fieldEvaluation.d.ts.map +1 -0
- package/dist/domain/evaluate/fieldEvaluation.js +133 -0
- package/dist/domain/evaluate/fieldEvaluation.js.map +1 -0
- package/dist/domain/evaluate/identity.d.ts +21 -0
- package/dist/domain/evaluate/identity.d.ts.map +1 -0
- package/dist/domain/evaluate/identity.js +72 -0
- package/dist/domain/evaluate/identity.js.map +1 -0
- package/dist/domain/evaluate/index.d.ts +4 -0
- package/dist/domain/evaluate/index.d.ts.map +1 -0
- package/dist/domain/evaluate/index.js +3 -0
- package/dist/domain/evaluate/index.js.map +1 -0
- package/dist/domain/evaluate/preconditions.d.ts +30 -0
- package/dist/domain/evaluate/preconditions.d.ts.map +1 -0
- package/dist/domain/evaluate/preconditions.js +389 -0
- package/dist/domain/evaluate/preconditions.js.map +1 -0
- package/dist/domain/evaluate/quarantine.d.ts +15 -0
- package/dist/domain/evaluate/quarantine.d.ts.map +1 -0
- package/dist/domain/evaluate/quarantine.js +185 -0
- package/dist/domain/evaluate/quarantine.js.map +1 -0
- package/dist/domain/index.d.ts +7 -0
- package/dist/domain/index.d.ts.map +1 -0
- package/dist/domain/index.js +7 -0
- package/dist/domain/index.js.map +1 -0
- package/dist/domain/model/constants.d.ts +73 -0
- package/dist/domain/model/constants.d.ts.map +1 -0
- package/dist/domain/model/constants.js +59 -0
- package/dist/domain/model/constants.js.map +1 -0
- package/dist/domain/model/index.d.ts +3 -0
- package/dist/domain/model/index.d.ts.map +1 -0
- package/dist/domain/model/index.js +2 -0
- package/dist/domain/model/index.js.map +1 -0
- package/dist/domain/model/types.d.ts +330 -0
- package/dist/domain/model/types.d.ts.map +1 -0
- package/dist/domain/model/types.js +8 -0
- package/dist/domain/model/types.js.map +1 -0
- package/dist/index.d.ts +17 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +11 -0
- package/dist/index.js.map +1 -0
- package/dist/infrastructure/index.d.ts +3 -0
- package/dist/infrastructure/index.d.ts.map +1 -0
- package/dist/infrastructure/index.js +3 -0
- package/dist/infrastructure/index.js.map +1 -0
- package/dist/infrastructure/storage/constants.d.ts +4 -0
- package/dist/infrastructure/storage/constants.d.ts.map +1 -0
- package/dist/infrastructure/storage/constants.js +4 -0
- package/dist/infrastructure/storage/constants.js.map +1 -0
- package/dist/infrastructure/storage/errors.d.ts +55 -0
- package/dist/infrastructure/storage/errors.d.ts.map +1 -0
- package/dist/infrastructure/storage/errors.js +58 -0
- package/dist/infrastructure/storage/errors.js.map +1 -0
- package/dist/infrastructure/storage/index.d.ts +23 -0
- package/dist/infrastructure/storage/index.d.ts.map +1 -0
- package/dist/infrastructure/storage/index.js +13 -0
- package/dist/infrastructure/storage/index.js.map +1 -0
- package/dist/infrastructure/storage/recovery/restoreRecovery.d.ts +64 -0
- package/dist/infrastructure/storage/recovery/restoreRecovery.d.ts.map +1 -0
- package/dist/infrastructure/storage/recovery/restoreRecovery.js +148 -0
- package/dist/infrastructure/storage/recovery/restoreRecovery.js.map +1 -0
- package/dist/infrastructure/storage/sqlite/schema.d.ts +49 -0
- package/dist/infrastructure/storage/sqlite/schema.d.ts.map +1 -0
- package/dist/infrastructure/storage/sqlite/schema.js +529 -0
- package/dist/infrastructure/storage/sqlite/schema.js.map +1 -0
- package/dist/infrastructure/storage/sqlite/schemaTypes.d.ts +5 -0
- package/dist/infrastructure/storage/sqlite/schemaTypes.d.ts.map +1 -0
- package/dist/infrastructure/storage/sqlite/schemaTypes.js +2 -0
- package/dist/infrastructure/storage/sqlite/schemaTypes.js.map +1 -0
- package/dist/infrastructure/storage/sqlite/sqlScript.d.ts +9 -0
- package/dist/infrastructure/storage/sqlite/sqlScript.d.ts.map +1 -0
- package/dist/infrastructure/storage/sqlite/sqlScript.js +122 -0
- package/dist/infrastructure/storage/sqlite/sqlScript.js.map +1 -0
- package/dist/infrastructure/storage/sqlite/sqlState.d.ts +6 -0
- package/dist/infrastructure/storage/sqlite/sqlState.d.ts.map +1 -0
- package/dist/infrastructure/storage/sqlite/sqlState.js +14 -0
- package/dist/infrastructure/storage/sqlite/sqlState.js.map +1 -0
- package/dist/infrastructure/storage/sqlite/sqlTransaction.d.ts +6 -0
- package/dist/infrastructure/storage/sqlite/sqlTransaction.d.ts.map +1 -0
- package/dist/infrastructure/storage/sqlite/sqlTransaction.js +24 -0
- package/dist/infrastructure/storage/sqlite/sqlTransaction.js.map +1 -0
- package/dist/infrastructure/storage/sqlite/sqliteBridge.d.ts +44 -0
- package/dist/infrastructure/storage/sqlite/sqliteBridge.d.ts.map +1 -0
- package/dist/infrastructure/storage/sqlite/sqliteBridge.js +66 -0
- package/dist/infrastructure/storage/sqlite/sqliteBridge.js.map +1 -0
- package/dist/infrastructure/storage/state/canonical/canonicalCommit.d.ts +101 -0
- package/dist/infrastructure/storage/state/canonical/canonicalCommit.d.ts.map +1 -0
- package/dist/infrastructure/storage/state/canonical/canonicalCommit.js +417 -0
- package/dist/infrastructure/storage/state/canonical/canonicalCommit.js.map +1 -0
- package/dist/infrastructure/storage/state/observation/observationAudit.d.ts +16 -0
- package/dist/infrastructure/storage/state/observation/observationAudit.d.ts.map +1 -0
- package/dist/infrastructure/storage/state/observation/observationAudit.js +85 -0
- package/dist/infrastructure/storage/state/observation/observationAudit.js.map +1 -0
- package/dist/infrastructure/storage/state/observation/observationCanonical.d.ts +31 -0
- package/dist/infrastructure/storage/state/observation/observationCanonical.d.ts.map +1 -0
- package/dist/infrastructure/storage/state/observation/observationCanonical.js +439 -0
- package/dist/infrastructure/storage/state/observation/observationCanonical.js.map +1 -0
- package/dist/infrastructure/storage/state/observation/observationConstants.d.ts +53 -0
- package/dist/infrastructure/storage/state/observation/observationConstants.d.ts.map +1 -0
- package/dist/infrastructure/storage/state/observation/observationConstants.js +41 -0
- package/dist/infrastructure/storage/state/observation/observationConstants.js.map +1 -0
- package/dist/infrastructure/storage/state/observation/observationLedger.d.ts +49 -0
- package/dist/infrastructure/storage/state/observation/observationLedger.d.ts.map +1 -0
- package/dist/infrastructure/storage/state/observation/observationLedger.js +537 -0
- package/dist/infrastructure/storage/state/observation/observationLedger.js.map +1 -0
- package/dist/infrastructure/storage/state/observation/observationQuarantine.d.ts +15 -0
- package/dist/infrastructure/storage/state/observation/observationQuarantine.d.ts.map +1 -0
- package/dist/infrastructure/storage/state/observation/observationQuarantine.js +100 -0
- package/dist/infrastructure/storage/state/observation/observationQuarantine.js.map +1 -0
- package/dist/infrastructure/storage/state/observation/observationTypes.d.ts +124 -0
- package/dist/infrastructure/storage/state/observation/observationTypes.d.ts.map +1 -0
- package/dist/infrastructure/storage/state/observation/observationTypes.js +13 -0
- package/dist/infrastructure/storage/state/observation/observationTypes.js.map +1 -0
- package/dist/infrastructure/storage/state/observation/observationValidation.d.ts +28 -0
- package/dist/infrastructure/storage/state/observation/observationValidation.d.ts.map +1 -0
- package/dist/infrastructure/storage/state/observation/observationValidation.js +223 -0
- package/dist/infrastructure/storage/state/observation/observationValidation.js.map +1 -0
- package/dist/infrastructure/storage/state/observation/observationWriter.d.ts +28 -0
- package/dist/infrastructure/storage/state/observation/observationWriter.d.ts.map +1 -0
- package/dist/infrastructure/storage/state/observation/observationWriter.js +293 -0
- package/dist/infrastructure/storage/state/observation/observationWriter.js.map +1 -0
- package/dist/infrastructure/storage/state/readonly/readOnlyObservation.d.ts +58 -0
- package/dist/infrastructure/storage/state/readonly/readOnlyObservation.d.ts.map +1 -0
- package/dist/infrastructure/storage/state/readonly/readOnlyObservation.js +195 -0
- package/dist/infrastructure/storage/state/readonly/readOnlyObservation.js.map +1 -0
- package/dist/infrastructure/storage/state/resolution/resolutionWriter.d.ts +31 -0
- package/dist/infrastructure/storage/state/resolution/resolutionWriter.d.ts.map +1 -0
- package/dist/infrastructure/storage/state/resolution/resolutionWriter.js +563 -0
- package/dist/infrastructure/storage/state/resolution/resolutionWriter.js.map +1 -0
- package/dist/infrastructure/storage/state/resolution/resolutionWriterContracts.d.ts +118 -0
- package/dist/infrastructure/storage/state/resolution/resolutionWriterContracts.d.ts.map +1 -0
- package/dist/infrastructure/storage/state/resolution/resolutionWriterContracts.js +18 -0
- package/dist/infrastructure/storage/state/resolution/resolutionWriterContracts.js.map +1 -0
- package/dist/infrastructure/storage/state/resolution/resolutionWriterHelpers.d.ts +23 -0
- package/dist/infrastructure/storage/state/resolution/resolutionWriterHelpers.d.ts.map +1 -0
- package/dist/infrastructure/storage/state/resolution/resolutionWriterHelpers.js +84 -0
- package/dist/infrastructure/storage/state/resolution/resolutionWriterHelpers.js.map +1 -0
- package/dist/infrastructure/storage/state/resolution/resolutionWriterSql.d.ts +16 -0
- package/dist/infrastructure/storage/state/resolution/resolutionWriterSql.d.ts.map +1 -0
- package/dist/infrastructure/storage/state/resolution/resolutionWriterSql.js +97 -0
- package/dist/infrastructure/storage/state/resolution/resolutionWriterSql.js.map +1 -0
- package/dist/infrastructure/storage/sync/outbound/effectOutbox.d.ts +137 -0
- package/dist/infrastructure/storage/sync/outbound/effectOutbox.d.ts.map +1 -0
- package/dist/infrastructure/storage/sync/outbound/effectOutbox.js +396 -0
- package/dist/infrastructure/storage/sync/outbound/effectOutbox.js.map +1 -0
- package/dist/infrastructure/storage/sync/outbound/effectOutboxContracts.d.ts +101 -0
- package/dist/infrastructure/storage/sync/outbound/effectOutboxContracts.d.ts.map +1 -0
- package/dist/infrastructure/storage/sync/outbound/effectOutboxContracts.js +9 -0
- package/dist/infrastructure/storage/sync/outbound/effectOutboxContracts.js.map +1 -0
- package/dist/infrastructure/storage/sync/outbound/effectOutboxSql.d.ts +21 -0
- package/dist/infrastructure/storage/sync/outbound/effectOutboxSql.d.ts.map +1 -0
- package/dist/infrastructure/storage/sync/outbound/effectOutboxSql.js +184 -0
- package/dist/infrastructure/storage/sync/outbound/effectOutboxSql.js.map +1 -0
- package/dist/infrastructure/storage/sync/outbound/effectOutboxSupport.d.ts +25 -0
- package/dist/infrastructure/storage/sync/outbound/effectOutboxSupport.d.ts.map +1 -0
- package/dist/infrastructure/storage/sync/outbound/effectOutboxSupport.js +158 -0
- package/dist/infrastructure/storage/sync/outbound/effectOutboxSupport.js.map +1 -0
- package/dist/infrastructure/storage/sync/shared/syncRegistry.d.ts +69 -0
- package/dist/infrastructure/storage/sync/shared/syncRegistry.d.ts.map +1 -0
- package/dist/infrastructure/storage/sync/shared/syncRegistry.js +272 -0
- package/dist/infrastructure/storage/sync/shared/syncRegistry.js.map +1 -0
- package/dist/infrastructure/storage/sync/shared/writerLease.d.ts +90 -0
- package/dist/infrastructure/storage/sync/shared/writerLease.d.ts.map +1 -0
- package/dist/infrastructure/storage/sync/shared/writerLease.js +282 -0
- package/dist/infrastructure/storage/sync/shared/writerLease.js.map +1 -0
- package/dist/shared/constants.d.ts +8 -0
- package/dist/shared/constants.d.ts.map +1 -0
- package/dist/shared/constants.js +8 -0
- package/dist/shared/constants.js.map +1 -0
- package/dist/shared/encoding/constants.d.ts +45 -0
- package/dist/shared/encoding/constants.d.ts.map +1 -0
- package/dist/shared/encoding/constants.js +37 -0
- package/dist/shared/encoding/constants.js.map +1 -0
- package/dist/shared/encoding/index.d.ts +6 -0
- package/dist/shared/encoding/index.d.ts.map +1 -0
- package/dist/shared/encoding/index.js +4 -0
- package/dist/shared/encoding/index.js.map +1 -0
- package/dist/shared/encoding/stableEncode.d.ts +34 -0
- package/dist/shared/encoding/stableEncode.d.ts.map +1 -0
- package/dist/shared/encoding/stableEncode.js +210 -0
- package/dist/shared/encoding/stableEncode.js.map +1 -0
- package/dist/shared/encoding/typeGuards.d.ts +15 -0
- package/dist/shared/encoding/typeGuards.d.ts.map +1 -0
- package/dist/shared/encoding/typeGuards.js +11 -0
- package/dist/shared/encoding/typeGuards.js.map +1 -0
- package/dist/shared/encoding/types.d.ts +52 -0
- package/dist/shared/encoding/types.d.ts.map +1 -0
- package/dist/shared/encoding/types.js +8 -0
- package/dist/shared/encoding/types.js.map +1 -0
- package/dist/shared/index.d.ts +6 -0
- package/dist/shared/index.d.ts.map +1 -0
- package/dist/shared/index.js +6 -0
- package/dist/shared/index.js.map +1 -0
- package/dist/shared/state/constants.d.ts +16 -0
- package/dist/shared/state/constants.d.ts.map +1 -0
- package/dist/shared/state/constants.js +16 -0
- package/dist/shared/state/constants.js.map +1 -0
- package/dist/shared/state/index.d.ts +3 -0
- package/dist/shared/state/index.d.ts.map +1 -0
- package/dist/shared/state/index.js +2 -0
- package/dist/shared/state/index.js.map +1 -0
- package/dist/shared/state/types.d.ts +23 -0
- package/dist/shared/state/types.d.ts.map +1 -0
- package/dist/shared/state/types.js +2 -0
- package/dist/shared/state/types.js.map +1 -0
- package/dist/shared/validation.d.ts +9 -0
- package/dist/shared/validation.d.ts.map +1 -0
- package/dist/shared/validation.js +25 -0
- package/dist/shared/validation.js.map +1 -0
- package/docs/architecture.md +72 -0
- package/docs/code-guidelines.md +256 -0
- package/docs/development.md +48 -0
- package/docs/git-workflow.md +224 -0
- package/docs/mikro-orm-adapter-spike.md +248 -0
- package/docs/quick-start.md +102 -0
- package/docs/sql-layer-plan.md +59 -0
- package/docs/sync-bulk-write-benchmark.md +1036 -0
- package/docs/sync-observability.md +71 -0
- package/docs/task-queue-write-model.md +640 -0
- package/docs/typed-sheets-mvp-scope-2026-06-29.md +490 -0
- package/docs/typed-sheets-plan.md +417 -0
- package/docs/write-and-synchronization-flow.md +71 -0
- package/package.json +68 -0
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Public lifecycle contracts for the typed-sheets ORM facade.
|
|
3
|
+
*
|
|
4
|
+
* They intentionally describe our entity lifecycle rather than any concrete
|
|
5
|
+
* ORM implementation, so a SQLite execution adapter can change without
|
|
6
|
+
* changing the application's `em.persist()` / `em.flush()` workflow.
|
|
7
|
+
*/
|
|
8
|
+
import { type Presence } from "../../../shared/state/index.js";
|
|
9
|
+
import type { SqlExecutor } from "../../../adapter/persistence/contracts/sql.js";
|
|
10
|
+
/** Constructor accepted by the initial entity-style public API. */
|
|
11
|
+
export interface TypedSheetsEntityClass<Entity extends object> {
|
|
12
|
+
new (...arguments_: never[]): Entity;
|
|
13
|
+
}
|
|
14
|
+
/** Stable entity reference accepted by our EntityManager facade. */
|
|
15
|
+
export type TypedSheetsEntityReference<Entity extends object> = string | TypedSheetsEntityClass<Entity>;
|
|
16
|
+
/** Values used when creating one entity through `em.create()`. */
|
|
17
|
+
export type TypedSheetsEntityData<Entity extends object> = Readonly<Partial<Entity>>;
|
|
18
|
+
/** Equality filter accepted by the initial `find()` and `findOne()` surface. */
|
|
19
|
+
export type TypedSheetsEntityFilter<Entity extends object> = Readonly<Partial<Entity>>;
|
|
20
|
+
/** Read options intentionally supported by the initial public entity API. */
|
|
21
|
+
export interface TypedSheetsFindOptions {
|
|
22
|
+
readonly limit?: number;
|
|
23
|
+
readonly offset?: number;
|
|
24
|
+
}
|
|
25
|
+
/** Entity-manager fork behavior supported without leaking the underlying ORM. */
|
|
26
|
+
export interface TypedSheetsForkOptions {
|
|
27
|
+
/** Starts the fork with an empty identity map when the execution engine supports it. */
|
|
28
|
+
readonly clear?: boolean;
|
|
29
|
+
}
|
|
30
|
+
/** Callback invoked by one entity execution engine immediately before it writes. */
|
|
31
|
+
export type TypedSheetsEntityFlushListener = (context: TypedSheetsFlushContext) => Promise<void>;
|
|
32
|
+
/**
|
|
33
|
+
* Replaceable internal execution engine for the typed-sheets EntityManager.
|
|
34
|
+
*
|
|
35
|
+
* This is the only extension point an ORM-specific integration must implement.
|
|
36
|
+
* It deliberately uses typed-sheets lifecycle types, never MikroORM types.
|
|
37
|
+
*/
|
|
38
|
+
export interface TypedSheetsEntityEngine {
|
|
39
|
+
/** Opens an isolated manager for one request, job, or unit of work. */
|
|
40
|
+
fork(): TypedSheetsEntityEngineManager;
|
|
41
|
+
/** Releases resources owned by the underlying SQLite execution engine. */
|
|
42
|
+
close(force?: boolean): Promise<void>;
|
|
43
|
+
}
|
|
44
|
+
/** Internal manager operations required to implement the public entity lifecycle. */
|
|
45
|
+
export interface TypedSheetsEntityEngineManager {
|
|
46
|
+
fork(options?: TypedSheetsForkOptions): TypedSheetsEntityEngineManager;
|
|
47
|
+
create<Entity extends object>(entityName: TypedSheetsEntityReference<Entity>, data: TypedSheetsEntityData<Entity>): Entity;
|
|
48
|
+
find<Entity extends object>(entityName: TypedSheetsEntityReference<Entity>, where: TypedSheetsEntityFilter<Entity>, options?: TypedSheetsFindOptions): Promise<readonly Entity[]>;
|
|
49
|
+
findOne<Entity extends object>(entityName: TypedSheetsEntityReference<Entity>, where: TypedSheetsEntityFilter<Entity>, options?: TypedSheetsFindOptions): Promise<Entity | null>;
|
|
50
|
+
persist<Entity extends object>(entity: Entity | Iterable<Entity>): void;
|
|
51
|
+
remove<Entity extends object>(entity: Entity | Iterable<Entity>): void;
|
|
52
|
+
flush(): Promise<void>;
|
|
53
|
+
transactional<Result>(operation: (entityManager: TypedSheetsEntityEngineManager) => Promise<Result>): Promise<Result>;
|
|
54
|
+
clear(): void;
|
|
55
|
+
isInTransaction(): boolean;
|
|
56
|
+
begin(): Promise<void>;
|
|
57
|
+
commit(): Promise<void>;
|
|
58
|
+
rollback(): Promise<void>;
|
|
59
|
+
/** Registers the typed-sheets plan to run in the engine's active flush transaction. */
|
|
60
|
+
onFlush(listener: TypedSheetsEntityFlushListener): void;
|
|
61
|
+
}
|
|
62
|
+
/** Runtime values for durable entity changes observed during one flush. */
|
|
63
|
+
export declare const TYPED_SHEETS_ENTITY_CHANGE_KINDS: {
|
|
64
|
+
readonly CREATE: "create";
|
|
65
|
+
readonly UPDATE: "update";
|
|
66
|
+
readonly DELETE: "delete";
|
|
67
|
+
};
|
|
68
|
+
/** Closed set of entity lifecycle changes handled by the typed-sheets ORM. */
|
|
69
|
+
export type TypedSheetsEntityChangeKind = (typeof TYPED_SHEETS_ENTITY_CHANGE_KINDS)[keyof typeof TYPED_SHEETS_ENTITY_CHANGE_KINDS];
|
|
70
|
+
/** Values captured from one MikroORM changeset before it reaches persistence. */
|
|
71
|
+
export type TypedSheetsEntityChangePayload = Readonly<Record<string, unknown>>;
|
|
72
|
+
/** Shared data carried by every normalized entity lifecycle change. */
|
|
73
|
+
export interface TypedSheetsEntityChangeBase {
|
|
74
|
+
readonly entityName: string;
|
|
75
|
+
readonly entity: object;
|
|
76
|
+
readonly primaryKey: Presence<string>;
|
|
77
|
+
/** Changed scalar values for updates and persisted values for inserts. */
|
|
78
|
+
readonly payload: TypedSheetsEntityChangePayload;
|
|
79
|
+
}
|
|
80
|
+
/** Entity was newly managed and will be inserted during the current flush. */
|
|
81
|
+
export interface TypedSheetsCreatedEntityChange extends TypedSheetsEntityChangeBase {
|
|
82
|
+
readonly kind: typeof TYPED_SHEETS_ENTITY_CHANGE_KINDS.CREATE;
|
|
83
|
+
}
|
|
84
|
+
/** Existing entity fields changed during the current flush. */
|
|
85
|
+
export interface TypedSheetsUpdatedEntityChange extends TypedSheetsEntityChangeBase {
|
|
86
|
+
readonly kind: typeof TYPED_SHEETS_ENTITY_CHANGE_KINDS.UPDATE;
|
|
87
|
+
}
|
|
88
|
+
/** Existing entity was marked for removal during the current flush. */
|
|
89
|
+
export interface TypedSheetsDeletedEntityChange extends TypedSheetsEntityChangeBase {
|
|
90
|
+
readonly kind: typeof TYPED_SHEETS_ENTITY_CHANGE_KINDS.DELETE;
|
|
91
|
+
}
|
|
92
|
+
/**
|
|
93
|
+
* One normalized entity change collected from a single `flush()` operation.
|
|
94
|
+
*
|
|
95
|
+
* The discriminant keeps lifecycle branching explicit for coordinators while
|
|
96
|
+
* the adapter-specific changeset shape remains outside the public contract.
|
|
97
|
+
*/
|
|
98
|
+
export type TypedSheetsEntityChange = TypedSheetsCreatedEntityChange | TypedSheetsUpdatedEntityChange | TypedSheetsDeletedEntityChange;
|
|
99
|
+
/** Context available to the typed-sheets sync planner during an entity flush. */
|
|
100
|
+
export interface TypedSheetsFlushContext {
|
|
101
|
+
/** All entity changes in the current Unit of Work(작업 단위). */
|
|
102
|
+
readonly changes: readonly TypedSheetsEntityChange[];
|
|
103
|
+
/** SQL executor bound to the same transaction as the entity writes. */
|
|
104
|
+
readonly sql: SqlExecutor;
|
|
105
|
+
}
|
|
106
|
+
/**
|
|
107
|
+
* Converts durable entity changes into typed-sheets canonical and outbox work.
|
|
108
|
+
*
|
|
109
|
+
* The coordinator runs before entity rows are flushed, but within the same
|
|
110
|
+
* SQLite transaction. Throwing aborts both the entity write and every
|
|
111
|
+
* typed-sheets write scheduled through `context.sql`.
|
|
112
|
+
*/
|
|
113
|
+
export interface TypedSheetsFlushCoordinator {
|
|
114
|
+
onFlush(context: TypedSheetsFlushContext): Promise<void>;
|
|
115
|
+
}
|
|
116
|
+
/** Converts a database-generated primary-key value into the public presence contract. */
|
|
117
|
+
export declare function primaryKeyPresence(primaryKey: string | null): Presence<string>;
|
|
118
|
+
//# sourceMappingURL=contracts.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"contracts.d.ts","sourceRoot":"","sources":["../../../../src/application/orm/api/contracts.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAEL,KAAK,QAAQ,EACd,MAAM,gCAAgC,CAAC;AACxC,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,+CAA+C,CAAC;AAEjF,mEAAmE;AACnE,MAAM,WAAW,sBAAsB,CAAC,MAAM,SAAS,MAAM;IAC3D,KAAK,GAAG,UAAU,EAAE,KAAK,EAAE,GAAG,MAAM,CAAC;CACtC;AAED,oEAAoE;AACpE,MAAM,MAAM,0BAA0B,CAAC,MAAM,SAAS,MAAM,IACxD,MAAM,GACN,sBAAsB,CAAC,MAAM,CAAC,CAAC;AAEnC,kEAAkE;AAClE,MAAM,MAAM,qBAAqB,CAAC,MAAM,SAAS,MAAM,IAAI,QAAQ,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC;AAErF,gFAAgF;AAChF,MAAM,MAAM,uBAAuB,CAAC,MAAM,SAAS,MAAM,IAAI,QAAQ,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC;AAEvF,6EAA6E;AAC7E,MAAM,WAAW,sBAAsB;IACrC,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAA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/D,MAAM,WAAW,8BAA+B,SAAQ,2BAA2B;IACjF,QAAQ,CAAC,IAAI,EAAE,OAAO,gCAAgC,CAAC,MAAM,CAAC;CAC/D;AAED,uEAAuE;AACvE,MAAM,WAAW,8BAA+B,SAAQ,2BAA2B;IACjF,QAAQ,CAAC,IAAI,EAAE,OAAO,gCAAgC,CAAC,MAAM,CAAC;CAC/D;AAED;;;;;GAKG;AACH,MAAM,MAAM,uBAAuB,GAC/B,8BAA8B,GAC9B,8BAA8B,GAC9B,8BAA8B,CAAC;AAEnC,iFAAiF;AACjF,MAAM,WAAW,uBAAuB;IACtC,6DAA6D;IAC7D,QAAQ,CAAC,OAAO,EAAE,SAAS,uBAAuB,EAAE,CAAC;IACrD,uEAAuE;IACvE,QAAQ,CAAC,GAAG,EAAE,WAAW,CAAC;CAC3B;AAED;;;;;;GAMG;AACH,MAAM,WAAW,2BAA2B;IAC1C,OAAO,CAAC,OAAO,EAAE,uBAAuB,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;CAC1D;AAED,yFAAyF;AACzF,wBAAgB,kBAAkB,CAAC,UAAU,EAAE,MAAM,GAAG,IAAI,GAAG,QAAQ,CAAC,MAAM,CAAC,CAI9E"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Public lifecycle contracts for the typed-sheets ORM facade.
|
|
3
|
+
*
|
|
4
|
+
* They intentionally describe our entity lifecycle rather than any concrete
|
|
5
|
+
* ORM implementation, so a SQLite execution adapter can change without
|
|
6
|
+
* changing the application's `em.persist()` / `em.flush()` workflow.
|
|
7
|
+
*/
|
|
8
|
+
import { PRESENCE_KINDS, } from "../../../shared/state/index.js";
|
|
9
|
+
/** Runtime values for durable entity changes observed during one flush. */
|
|
10
|
+
export const TYPED_SHEETS_ENTITY_CHANGE_KINDS = {
|
|
11
|
+
CREATE: "create",
|
|
12
|
+
UPDATE: "update",
|
|
13
|
+
DELETE: "delete",
|
|
14
|
+
};
|
|
15
|
+
/** Converts a database-generated primary-key value into the public presence contract. */
|
|
16
|
+
export function primaryKeyPresence(primaryKey) {
|
|
17
|
+
return primaryKey === null
|
|
18
|
+
? { kind: PRESENCE_KINDS.ABSENT }
|
|
19
|
+
: { kind: PRESENCE_KINDS.PRESENT, value: primaryKey };
|
|
20
|
+
}
|
|
21
|
+
//# sourceMappingURL=contracts.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"contracts.js","sourceRoot":"","sources":["../../../../src/application/orm/api/contracts.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EACL,cAAc,GAEf,MAAM,gCAAgC,CAAC;AAiFxC,2EAA2E;AAC3E,MAAM,CAAC,MAAM,gCAAgC,GAAG;IAC9C,MAAM,EAAE,QAAQ;IAChB,MAAM,EAAE,QAAQ;IAChB,MAAM,EAAE,QAAQ;CACR,CAAC;AA+DX,yFAAyF;AACzF,MAAM,UAAU,kBAAkB,CAAC,UAAyB;IAC1D,OAAO,UAAU,KAAK,IAAI;QACxB,CAAC,CAAC,EAAE,IAAI,EAAE,cAAc,CAAC,MAAM,EAAE;QACjC,CAAC,CAAC,EAAE,IAAI,EAAE,cAAc,CAAC,OAAO,EAAE,KAAK,EAAE,UAAU,EAAE,CAAC;AAC1D,CAAC"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Structured errors raised by the public typed-sheets ORM composition layer.
|
|
3
|
+
*
|
|
4
|
+
* Storage failures retain their existing `StorageError` contract. These codes
|
|
5
|
+
* describe configuration or lifecycle failures before a storage primitive can
|
|
6
|
+
* safely continue.
|
|
7
|
+
*/
|
|
8
|
+
import { CoreErrorException } from "../../domain/errors/index.js";
|
|
9
|
+
/** Stable codes emitted by entity mapping and mapped lifecycle helpers. */
|
|
10
|
+
export declare const TYPED_SHEETS_ORM_ERROR_CODES: {
|
|
11
|
+
readonly INVALID_ENTITY_MAPPING: "invalid_entity_mapping";
|
|
12
|
+
readonly DUPLICATE_ENTITY_MAPPING: "duplicate_entity_mapping";
|
|
13
|
+
readonly ENTITY_MAPPING_NOT_FOUND: "entity_mapping_not_found";
|
|
14
|
+
readonly ENTITY_PRIMARY_KEY_UNAVAILABLE: "entity_primary_key_unavailable";
|
|
15
|
+
readonly ENTITY_PRIMARY_KEY_MISMATCH: "entity_primary_key_mismatch";
|
|
16
|
+
readonly ENTITY_PRIMARY_KEY_MUTATION: "entity_primary_key_mutation";
|
|
17
|
+
readonly INVALID_MAPPED_FIELD_VALUE: "invalid_mapped_field_value";
|
|
18
|
+
readonly WRITER_LEASE_UNAVAILABLE: "writer_lease_unavailable";
|
|
19
|
+
readonly ROW_BINDING_CONFLICT: "row_binding_conflict";
|
|
20
|
+
readonly CANONICAL_COMMIT_REJECTED: "canonical_commit_rejected";
|
|
21
|
+
readonly PROJECTION_OUTBOX_BLOCKED: "projection_outbox_blocked";
|
|
22
|
+
readonly OBSERVATION_ENTITY_MUTATION_FAILED: "observation_entity_mutation_failed";
|
|
23
|
+
};
|
|
24
|
+
/** Closed set of typed-sheets ORM composition error codes. */
|
|
25
|
+
export type TypedSheetsOrmErrorCode = (typeof TYPED_SHEETS_ORM_ERROR_CODES)[keyof typeof TYPED_SHEETS_ORM_ERROR_CODES];
|
|
26
|
+
/**
|
|
27
|
+
* Error raised when mapping metadata or its lifecycle plan is unsafe.
|
|
28
|
+
*
|
|
29
|
+
* The stable `code` lets applications distinguish a bad entity mapping from a
|
|
30
|
+
* temporary writer-lease race without parsing an English error message.
|
|
31
|
+
*/
|
|
32
|
+
export declare class TypedSheetsOrmError extends CoreErrorException<"typed_sheets_orm", TypedSheetsOrmErrorCode> {
|
|
33
|
+
constructor(code: TypedSheetsOrmErrorCode, message: string);
|
|
34
|
+
}
|
|
35
|
+
//# sourceMappingURL=errors.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../../../src/application/orm/errors.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,kBAAkB,EAAE,MAAM,8BAA8B,CAAC;AAElE,2EAA2E;AAC3E,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;CAa/B,CAAC;AAEX,8DAA8D;AAC9D,MAAM,MAAM,uBAAuB,GACjC,CAAC,OAAO,4BAA4B,CAAC,CAAC,MAAM,OAAO,4BAA4B,CAAC,CAAC;AAEnF;;;;;GAKG;AACH,qBAAa,mBAAoB,SAAQ,kBAAkB,CACzD,kBAAkB,EAClB,uBAAuB,CACxB;gBACa,IAAI,EAAE,uBAAuB,EAAE,OAAO,EAAE,MAAM;CAG3D"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Structured errors raised by the public typed-sheets ORM composition layer.
|
|
3
|
+
*
|
|
4
|
+
* Storage failures retain their existing `StorageError` contract. These codes
|
|
5
|
+
* describe configuration or lifecycle failures before a storage primitive can
|
|
6
|
+
* safely continue.
|
|
7
|
+
*/
|
|
8
|
+
import { CoreErrorException } from "../../domain/errors/index.js";
|
|
9
|
+
/** Stable codes emitted by entity mapping and mapped lifecycle helpers. */
|
|
10
|
+
export const TYPED_SHEETS_ORM_ERROR_CODES = {
|
|
11
|
+
INVALID_ENTITY_MAPPING: "invalid_entity_mapping",
|
|
12
|
+
DUPLICATE_ENTITY_MAPPING: "duplicate_entity_mapping",
|
|
13
|
+
ENTITY_MAPPING_NOT_FOUND: "entity_mapping_not_found",
|
|
14
|
+
ENTITY_PRIMARY_KEY_UNAVAILABLE: "entity_primary_key_unavailable",
|
|
15
|
+
ENTITY_PRIMARY_KEY_MISMATCH: "entity_primary_key_mismatch",
|
|
16
|
+
ENTITY_PRIMARY_KEY_MUTATION: "entity_primary_key_mutation",
|
|
17
|
+
INVALID_MAPPED_FIELD_VALUE: "invalid_mapped_field_value",
|
|
18
|
+
WRITER_LEASE_UNAVAILABLE: "writer_lease_unavailable",
|
|
19
|
+
ROW_BINDING_CONFLICT: "row_binding_conflict",
|
|
20
|
+
CANONICAL_COMMIT_REJECTED: "canonical_commit_rejected",
|
|
21
|
+
PROJECTION_OUTBOX_BLOCKED: "projection_outbox_blocked",
|
|
22
|
+
OBSERVATION_ENTITY_MUTATION_FAILED: "observation_entity_mutation_failed",
|
|
23
|
+
};
|
|
24
|
+
/**
|
|
25
|
+
* Error raised when mapping metadata or its lifecycle plan is unsafe.
|
|
26
|
+
*
|
|
27
|
+
* The stable `code` lets applications distinguish a bad entity mapping from a
|
|
28
|
+
* temporary writer-lease race without parsing an English error message.
|
|
29
|
+
*/
|
|
30
|
+
export class TypedSheetsOrmError extends CoreErrorException {
|
|
31
|
+
constructor(code, message) {
|
|
32
|
+
super("typed_sheets_orm", code, message);
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
//# sourceMappingURL=errors.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"errors.js","sourceRoot":"","sources":["../../../src/application/orm/errors.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,kBAAkB,EAAE,MAAM,8BAA8B,CAAC;AAElE,2EAA2E;AAC3E,MAAM,CAAC,MAAM,4BAA4B,GAAG;IAC1C,sBAAsB,EAAE,wBAAwB;IAChD,wBAAwB,EAAE,0BAA0B;IACpD,wBAAwB,EAAE,0BAA0B;IACpD,8BAA8B,EAAE,gCAAgC;IAChE,2BAA2B,EAAE,6BAA6B;IAC1D,2BAA2B,EAAE,6BAA6B;IAC1D,0BAA0B,EAAE,4BAA4B;IACxD,wBAAwB,EAAE,0BAA0B;IACpD,oBAAoB,EAAE,sBAAsB;IAC5C,yBAAyB,EAAE,2BAA2B;IACtD,yBAAyB,EAAE,2BAA2B;IACtD,kCAAkC,EAAE,oCAAoC;CAChE,CAAC;AAMX;;;;;GAKG;AACH,MAAM,OAAO,mBAAoB,SAAQ,kBAGxC;IACC,YAAY,IAA6B,EAAE,OAAe;QACxD,KAAK,CAAC,kBAAkB,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;IAC3C,CAAC;CACF"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export { TYPED_SHEETS_ENTITY_CHANGE_KINDS, primaryKeyPresence, } from "./api/contracts.js";
|
|
2
|
+
export { createTypedSheetsOrm, TypedSheetsEntityManager, TypedSheetsOrm, } from "./api/TypedSheetsOrm.js";
|
|
3
|
+
export { createTypedSheetsEntityMappingRegistry, createTypedSheetsEntityOwnershipManifest, createTypedSheetsEntityProjectionRegistration, createTypedSheetsMappedProjectionDefinitions, decodeTypedSheetsEntityField, defineTypedSheetsEntityMapping, encodeTypedSheetsEntity, encodeTypedSheetsEntityField, requireTypedSheetsEntityField, requireTypedSheetsEntityProjection, serializeTypedSheetsEntityOwnershipManifest, typedSheetsEntityAnchor, typedSheetsEntityId, typedSheetsEntityProjectionHeaders, typedSheetsEntityRowBindingId, } from "./mapping/entityMapping.js";
|
|
4
|
+
export { TYPED_SHEETS_ORM_ERROR_CODES, TypedSheetsOrmError, } from "./errors.js";
|
|
5
|
+
export { createMappedTypedSheetsFlushCoordinator, registeredTypedSheetsProjectionDefinitions, registerTypedSheetsEntityMappings, } from "./persistence/flush/mappedFlushCoordinator.js";
|
|
6
|
+
export { MAPPED_OBSERVATION_ENTITY_MUTATION_KINDS, planMappedObservationEntityMutation, } from "./mapping/observationMapping.js";
|
|
7
|
+
export type { TypedSheetsEntityClass, TypedSheetsEntityChange, TypedSheetsEntityChangeBase, TypedSheetsEntityChangeKind, TypedSheetsEntityChangePayload, TypedSheetsCreatedEntityChange, TypedSheetsDeletedEntityChange, TypedSheetsEntityData, TypedSheetsEntityEngine, TypedSheetsEntityEngineManager, TypedSheetsEntityFilter, TypedSheetsEntityFlushListener, TypedSheetsEntityReference, TypedSheetsFindOptions, TypedSheetsForkOptions, TypedSheetsFlushContext, TypedSheetsFlushCoordinator, TypedSheetsUpdatedEntityChange, } from "./api/contracts.js";
|
|
8
|
+
export type { CreateTypedSheetsOrmOptions } from "./api/TypedSheetsOrm.js";
|
|
9
|
+
export type { CreateMappedTypedSheetsFlushCoordinatorOptions, RegisteredTypedSheetsMappedProjection, TypedSheetsEntityWriterOptions, } from "./persistence/flush/mappedFlushCoordinator.js";
|
|
10
|
+
export type { MappedObservationEntityMutation } from "./mapping/observationMapping.js";
|
|
11
|
+
export type { TypedSheetsEntityFieldCodec, TypedSheetsEntityFieldMapping, TypedSheetsEntityFieldMappingInput, TypedSheetsEntityMapping, TypedSheetsEntityMappingInput, TypedSheetsEntityMappingRegistry, TypedSheetsEntityProjection, TypedSheetsEntityProjectionMapping, TypedSheetsEntityProjectionMappingInput, TypedSheetsEntityProperty, TypedSheetsMappedProjectionDefinition, } from "./mapping/entityMapping.js";
|
|
12
|
+
export type { TypedSheetsOrmErrorCode } from "./errors.js";
|
|
13
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/application/orm/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,gCAAgC,EAChC,kBAAkB,GACnB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EACL,oBAAoB,EACpB,wBAAwB,EACxB,cAAc,GACf,MAAM,yBAAyB,CAAC;AACjC,OAAO,EACL,sCAAsC,EACtC,wCAAwC,EACxC,6CAA6C,EAC7C,4CAA4C,EAC5C,4BAA4B,EAC5B,8BAA8B,EAC9B,uBAAuB,EACvB,4BAA4B,EAC5B,6BAA6B,EAC7B,kCAAkC,EAClC,2CAA2C,EAC3C,uBAAuB,EACvB,mBAAmB,EACnB,kCAAkC,EAClC,6BAA6B,GAC9B,MAAM,4BAA4B,CAAC;AACpC,OAAO,EACL,4BAA4B,EAC5B,mBAAmB,GACpB,MAAM,aAAa,CAAC;AACrB,OAAO,EACL,uCAAuC,EACvC,0CAA0C,EAC1C,iCAAiC,GAClC,MAAM,+CAA+C,CAAC;AACvD,OAAO,EACL,wCAAwC,EACxC,mCAAmC,GACpC,MAAM,iCAAiC,CAAC;AACzC,YAAY,EACV,sBAAsB,EACtB,uBAAuB,EACvB,2BAA2B,EAC3B,2BAA2B,EAC3B,8BAA8B,EAC9B,8BAA8B,EAC9B,8BAA8B,EAC9B,qBAAqB,EACrB,uBAAuB,EACvB,8BAA8B,EAC9B,uBAAuB,EACvB,8BAA8B,EAC9B,0BAA0B,EAC1B,sBAAsB,EACtB,sBAAsB,EACtB,uBAAuB,EACvB,2BAA2B,EAC3B,8BAA8B,GAC/B,MAAM,oBAAoB,CAAC;AAC5B,YAAY,EAAE,2BAA2B,EAAE,MAAM,yBAAyB,CAAC;AAC3E,YAAY,EACV,8CAA8C,EAC9C,qCAAqC,EACrC,8BAA8B,GAC/B,MAAM,+CAA+C,CAAC;AACvD,YAAY,EAAE,+BAA+B,EAAE,MAAM,iCAAiC,CAAC;AACvF,YAAY,EACV,2BAA2B,EAC3B,6BAA6B,EAC7B,kCAAkC,EAClC,wBAAwB,EACxB,6BAA6B,EAC7B,gCAAgC,EAChC,2BAA2B,EAC3B,kCAAkC,EAClC,uCAAuC,EACvC,yBAAyB,EACzB,qCAAqC,GACtC,MAAM,4BAA4B,CAAC;AACpC,YAAY,EAAE,uBAAuB,EAAE,MAAM,aAAa,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export { TYPED_SHEETS_ENTITY_CHANGE_KINDS, primaryKeyPresence, } from "./api/contracts.js";
|
|
2
|
+
export { createTypedSheetsOrm, TypedSheetsEntityManager, TypedSheetsOrm, } from "./api/TypedSheetsOrm.js";
|
|
3
|
+
export { createTypedSheetsEntityMappingRegistry, createTypedSheetsEntityOwnershipManifest, createTypedSheetsEntityProjectionRegistration, createTypedSheetsMappedProjectionDefinitions, decodeTypedSheetsEntityField, defineTypedSheetsEntityMapping, encodeTypedSheetsEntity, encodeTypedSheetsEntityField, requireTypedSheetsEntityField, requireTypedSheetsEntityProjection, serializeTypedSheetsEntityOwnershipManifest, typedSheetsEntityAnchor, typedSheetsEntityId, typedSheetsEntityProjectionHeaders, typedSheetsEntityRowBindingId, } from "./mapping/entityMapping.js";
|
|
4
|
+
export { TYPED_SHEETS_ORM_ERROR_CODES, TypedSheetsOrmError, } from "./errors.js";
|
|
5
|
+
export { createMappedTypedSheetsFlushCoordinator, registeredTypedSheetsProjectionDefinitions, registerTypedSheetsEntityMappings, } from "./persistence/flush/mappedFlushCoordinator.js";
|
|
6
|
+
export { MAPPED_OBSERVATION_ENTITY_MUTATION_KINDS, planMappedObservationEntityMutation, } from "./mapping/observationMapping.js";
|
|
7
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/application/orm/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,gCAAgC,EAChC,kBAAkB,GACnB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EACL,oBAAoB,EACpB,wBAAwB,EACxB,cAAc,GACf,MAAM,yBAAyB,CAAC;AACjC,OAAO,EACL,sCAAsC,EACtC,wCAAwC,EACxC,6CAA6C,EAC7C,4CAA4C,EAC5C,4BAA4B,EAC5B,8BAA8B,EAC9B,uBAAuB,EACvB,4BAA4B,EAC5B,6BAA6B,EAC7B,kCAAkC,EAClC,2CAA2C,EAC3C,uBAAuB,EACvB,mBAAmB,EACnB,kCAAkC,EAClC,6BAA6B,GAC9B,MAAM,4BAA4B,CAAC;AACpC,OAAO,EACL,4BAA4B,EAC5B,mBAAmB,GACpB,MAAM,aAAa,CAAC;AACrB,OAAO,EACL,uCAAuC,EACvC,0CAA0C,EAC1C,iCAAiC,GAClC,MAAM,+CAA+C,CAAC;AACvD,OAAO,EACL,wCAAwC,EACxC,mCAAmC,GACpC,MAAM,iCAAiC,CAAC"}
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Type contracts for entity-to-Sheets mappings.
|
|
3
|
+
*
|
|
4
|
+
* This file contains declarations only. Validation, indexing, projection
|
|
5
|
+
* registration, and value conversion live in their respective modules.
|
|
6
|
+
*/
|
|
7
|
+
import { type FieldOwnership, type NormalizedCell } from "../../../domain/index.js";
|
|
8
|
+
import { SYNC_GATEWAY_PROJECTIONS } from "../../sync/gateway/constants.js";
|
|
9
|
+
import type { RegisterSyncSheetInput } from "../../../infrastructure/storage/index.js";
|
|
10
|
+
import type { TypedSheetsEntityReference } from "../api/contracts.js";
|
|
11
|
+
import type { NormalizedCellKind } from "../../../shared/encoding/constants.js";
|
|
12
|
+
/** Physical projections supported by a mapped business entity. */
|
|
13
|
+
export type TypedSheetsEntityProjection = typeof SYNC_GATEWAY_PROJECTIONS.USER_INPUT | typeof SYNC_GATEWAY_PROJECTIONS.SYSTEM_STATE;
|
|
14
|
+
/** A string property name declared by one mapped entity. */
|
|
15
|
+
export type TypedSheetsEntityProperty<Entity extends object> = Extract<keyof Entity, string>;
|
|
16
|
+
/** Optional codec used when a TypeScript property needs custom cell conversion. */
|
|
17
|
+
export interface TypedSheetsEntityFieldCodec {
|
|
18
|
+
/** Converts one entity property value into a normalized Sheet cell. */
|
|
19
|
+
readonly encode?: (value: unknown) => NormalizedCell;
|
|
20
|
+
/** Converts one accepted canonical cell into an entity property value. */
|
|
21
|
+
readonly decode?: (value: NormalizedCell) => unknown;
|
|
22
|
+
}
|
|
23
|
+
/** Input declaration for one entity property stored as a canonical field. */
|
|
24
|
+
export interface TypedSheetsEntityFieldMappingInput<Entity extends object> extends TypedSheetsEntityFieldCodec {
|
|
25
|
+
/** Property on the application entity. */
|
|
26
|
+
readonly property: TypedSheetsEntityProperty<Entity>;
|
|
27
|
+
/** Stable canonical/Sheet field name. Defaults to `property`. */
|
|
28
|
+
readonly fieldName?: string;
|
|
29
|
+
/** Runtime cell type stored in canonical state and projected to Sheets. */
|
|
30
|
+
readonly cellKind: NormalizedCellKind;
|
|
31
|
+
/** Whether a human Sheet edit may own this business field. */
|
|
32
|
+
readonly ownership: FieldOwnership;
|
|
33
|
+
/** Whether blank (`null`) or an empty string is invalid. */
|
|
34
|
+
readonly required?: boolean;
|
|
35
|
+
/** Whether this is the one v1 business-key field. */
|
|
36
|
+
readonly unique?: boolean;
|
|
37
|
+
}
|
|
38
|
+
/** Immutable routing coordinates for one physical User_Input or System_State tab. */
|
|
39
|
+
export interface TypedSheetsEntityProjectionMappingInput {
|
|
40
|
+
readonly physicalSheetId: string;
|
|
41
|
+
readonly spreadsheetId: string;
|
|
42
|
+
readonly tabName: string;
|
|
43
|
+
readonly registeredRange: string;
|
|
44
|
+
readonly projection: TypedSheetsEntityProjection;
|
|
45
|
+
}
|
|
46
|
+
/** User-facing declaration used to construct one validated entity mapping. */
|
|
47
|
+
export interface TypedSheetsEntityMappingInput<Entity extends object> {
|
|
48
|
+
/** Entity class or stable entity name handled by the execution engine. */
|
|
49
|
+
readonly entity: TypedSheetsEntityReference<Entity>;
|
|
50
|
+
/** Overrides the execution engine's class name when a stable alias is needed. */
|
|
51
|
+
readonly entityName?: string;
|
|
52
|
+
/** Stable logical Sheets identifier shared by its physical projections. */
|
|
53
|
+
readonly logicalSheetId: string;
|
|
54
|
+
/** String primary-key property used as SQLite/canonical entity identity. */
|
|
55
|
+
readonly primaryKey: TypedSheetsEntityProperty<Entity>;
|
|
56
|
+
/** Required unique property used by the v1 business-key index. */
|
|
57
|
+
readonly businessKey: TypedSheetsEntityProperty<Entity>;
|
|
58
|
+
/** Schema version registered for every physical projection of this entity. */
|
|
59
|
+
readonly schemaVersion: number;
|
|
60
|
+
/** Canonical business fields exposed by this mapping. */
|
|
61
|
+
readonly fields: readonly TypedSheetsEntityFieldMappingInput<Entity>[];
|
|
62
|
+
/** One System_State projection and, optionally, one User_Input projection. */
|
|
63
|
+
readonly projections: readonly TypedSheetsEntityProjectionMappingInput[];
|
|
64
|
+
/** System-only marker projected when `em.remove()` tombstones an entity. */
|
|
65
|
+
readonly tombstoneFieldName?: string;
|
|
66
|
+
/** Builds a deterministic projection-local row anchor from canonical identity. */
|
|
67
|
+
readonly anchorForEntity?: (entityId: string) => string;
|
|
68
|
+
}
|
|
69
|
+
/** Validated mapping metadata for one canonical entity. */
|
|
70
|
+
export interface TypedSheetsEntityFieldMapping extends TypedSheetsEntityFieldCodec {
|
|
71
|
+
readonly property: string;
|
|
72
|
+
readonly fieldName: string;
|
|
73
|
+
readonly cellKind: NormalizedCellKind;
|
|
74
|
+
readonly ownership: FieldOwnership;
|
|
75
|
+
readonly required: boolean;
|
|
76
|
+
readonly unique: boolean;
|
|
77
|
+
}
|
|
78
|
+
/** Validated physical projection route. */
|
|
79
|
+
export interface TypedSheetsEntityProjectionMapping {
|
|
80
|
+
readonly physicalSheetId: string;
|
|
81
|
+
readonly spreadsheetId: string;
|
|
82
|
+
readonly tabName: string;
|
|
83
|
+
readonly registeredRange: string;
|
|
84
|
+
readonly projection: TypedSheetsEntityProjection;
|
|
85
|
+
}
|
|
86
|
+
/** Adapter-neutral mapping consumed by the flush and observation bridges. */
|
|
87
|
+
export interface TypedSheetsEntityMapping {
|
|
88
|
+
readonly entity: TypedSheetsEntityReference<object>;
|
|
89
|
+
readonly entityName: string;
|
|
90
|
+
readonly logicalSheetId: string;
|
|
91
|
+
readonly primaryKey: string;
|
|
92
|
+
readonly businessKey: TypedSheetsEntityFieldMapping;
|
|
93
|
+
readonly schemaVersion: number;
|
|
94
|
+
readonly fields: readonly TypedSheetsEntityFieldMapping[];
|
|
95
|
+
readonly projections: readonly TypedSheetsEntityProjectionMapping[];
|
|
96
|
+
readonly tombstoneFieldName: string;
|
|
97
|
+
readonly anchorForEntity: (entityId: string) => string;
|
|
98
|
+
}
|
|
99
|
+
/** An indexed collection of validated mappings used by one typed-sheets runtime. */
|
|
100
|
+
export interface TypedSheetsEntityMappingRegistry {
|
|
101
|
+
readonly mappings: readonly TypedSheetsEntityMapping[];
|
|
102
|
+
findByEntityName(entityName: string): TypedSheetsEntityMapping | undefined;
|
|
103
|
+
findByLogicalSheetId(logicalSheetId: string): TypedSheetsEntityMapping | undefined;
|
|
104
|
+
findByPhysicalSheetId(physicalSheetId: string): TypedSheetsEntityMapping | undefined;
|
|
105
|
+
}
|
|
106
|
+
/** A physical projection plus its computed registry input and header schema. */
|
|
107
|
+
export interface TypedSheetsMappedProjectionDefinition {
|
|
108
|
+
readonly mapping: TypedSheetsEntityMapping;
|
|
109
|
+
readonly projection: TypedSheetsEntityProjectionMapping;
|
|
110
|
+
readonly registration: RegisterSyncSheetInput;
|
|
111
|
+
readonly headers: readonly string[];
|
|
112
|
+
}
|
|
113
|
+
//# sourceMappingURL=contracts.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"contracts.d.ts","sourceRoot":"","sources":["../../../../src/application/orm/mapping/contracts.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EACL,KAAK,cAAc,EACnB,KAAK,cAAc,EACpB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EACL,wBAAwB,EACzB,MAAM,iCAAiC,CAAC;AACzC,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,0CAA0C,CAAC;AACvF,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,qBAAqB,CAAC;AACtE,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,uCAAuC,CAAC;AAEhF,kEAAkE;AAClE,MAAM,MAAM,2BAA2B,GACnC,OAAO,wBAAwB,CAAC,UAAU,GAC1C,OAAO,wBAAwB,CAAC,YAAY,CAAC;AAEjD,4DAA4D;AAC5D,MAAM,MAAM,yBAAyB,CAAC,MAAM,SAAS,MAAM,IAAI,OAAO,CAAC,MAAM,MAAM,EAAE,MAAM,CAAC,CAAC;AAE7F,mFAAmF;AACnF,MAAM,WAAW,2BAA2B;IAC1C,uEAAuE;IACvE,QAAQ,CAAC,MAAM,CAAC,EAAE,CAAC,KAAK,EAAE,OAAO,KAAK,cAAc,CAAC;IACrD,0EAA0E;IAC1E,QAAQ,CAAC,MAAM,CAAC,EAAE,CAAC,KAAK,EAAE,cAAc,KAAK,OAAO,CAAC;C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IACpD,QAAQ,CAAC,aAAa,EAAE,MAAM,CAAC;IAC/B,QAAQ,CAAC,MAAM,EAAE,SAAS,6BAA6B,EAAE,CAAC;IAC1D,QAAQ,CAAC,WAAW,EAAE,SAAS,kCAAkC,EAAE,CAAC;IACpE,QAAQ,CAAC,kBAAkB,EAAE,MAAM,CAAC;IACpC,QAAQ,CAAC,eAAe,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,MAAM,CAAC;CACxD;AAED,oFAAoF;AACpF,MAAM,WAAW,gCAAgC;IAC/C,QAAQ,CAAC,QAAQ,EAAE,SAAS,wBAAwB,EAAE,CAAC;IACvD,gBAAgB,CAAC,UAAU,EAAE,MAAM,GAAG,wBAAwB,GAAG,SAAS,CAAC;IAC3E,oBAAoB,CAAC,cAAc,EAAE,MAAM,GAAG,wBAAwB,GAAG,SAAS,CAAC;IACnF,qBAAqB,CAAC,eAAe,EAAE,MAAM,GAAG,wBAAwB,GAAG,SAAS,CAAC;CACtF;AAED,gFAAgF;AAChF,MAAM,WAAW,qCAAqC;IACpD,QAAQ,CAAC,OAAO,EAAE,wBAAwB,CAAC;IAC3C,QAAQ,CAAC,UAAU,EAAE,kCAAkC,CAAC;IACxD,QAAQ,CAAC,YAAY,EAAE,sBAAsB,CAAC;IAC9C,QAAQ,CAAC,OAAO,EAAE,SAAS,MAAM,EAAE,CAAC;CACrC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"contracts.js","sourceRoot":"","sources":["../../../../src/application/orm/mapping/contracts.ts"],"names":[],"mappings":"AAAA;;;;;GAKG"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Validates and normalizes user-facing entity mapping declarations.
|
|
3
|
+
*
|
|
4
|
+
* This module is the construction boundary: callers provide flexible input,
|
|
5
|
+
* and every downstream mapping module receives a validated contract.
|
|
6
|
+
*/
|
|
7
|
+
import type { TypedSheetsEntityMapping, TypedSheetsEntityMappingInput } from "./contracts.js";
|
|
8
|
+
/**
|
|
9
|
+
* Validates and normalizes a single entity-to-Sheets mapping declaration.
|
|
10
|
+
*
|
|
11
|
+
* It rejects ambiguous entity names, duplicated field names, missing business
|
|
12
|
+
* key guarantees, and a projection layout that would violate the v1
|
|
13
|
+
* User_Input/System_State ownership boundary.
|
|
14
|
+
*/
|
|
15
|
+
export declare function defineTypedSheetsEntityMapping<Entity extends object>(input: TypedSheetsEntityMappingInput<Entity>): TypedSheetsEntityMapping;
|
|
16
|
+
//# sourceMappingURL=definition.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"definition.d.ts","sourceRoot":"","sources":["../../../../src/application/orm/mapping/definition.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAWH,OAAO,KAAK,EAGV,wBAAwB,EACxB,6BAA6B,EAG9B,MAAM,gBAAgB,CAAC;AAMxB;;;;;;GAMG;AACH,wBAAgB,8BAA8B,CAAC,MAAM,SAAS,MAAM,EAClE,KAAK,EAAE,6BAA6B,CAAC,MAAM,CAAC,GAC3C,wBAAwB,CAkE1B"}
|
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Validates and normalizes user-facing entity mapping declarations.
|
|
3
|
+
*
|
|
4
|
+
* This module is the construction boundary: callers provide flexible input,
|
|
5
|
+
* and every downstream mapping module receives a validated contract.
|
|
6
|
+
*/
|
|
7
|
+
import { EMPTY_STRING_LENGTH_ZERO, FIELD_OWNERSHIPS, } from "../../../domain/index.js";
|
|
8
|
+
import { NORMALIZED_CELL_KINDS, } from "../../../shared/encoding/constants.js";
|
|
9
|
+
import { SYNC_GATEWAY_PROJECTIONS } from "../../sync/gateway/constants.js";
|
|
10
|
+
import { TYPED_SHEETS_ORM_ERROR_CODES, TypedSheetsOrmError, } from "../errors.js";
|
|
11
|
+
/**
|
|
12
|
+
* Validates and normalizes a single entity-to-Sheets mapping declaration.
|
|
13
|
+
*
|
|
14
|
+
* It rejects ambiguous entity names, duplicated field names, missing business
|
|
15
|
+
* key guarantees, and a projection layout that would violate the v1
|
|
16
|
+
* User_Input/System_State ownership boundary.
|
|
17
|
+
*/
|
|
18
|
+
export function defineTypedSheetsEntityMapping(input) {
|
|
19
|
+
const entityName = input.entityName ?? entityReferenceName(input.entity);
|
|
20
|
+
requireText(entityName, "entity name");
|
|
21
|
+
requireText(input.logicalSheetId, "logical sheet ID");
|
|
22
|
+
requireText(input.primaryKey, "primary-key property");
|
|
23
|
+
requireText(input.businessKey, "business-key property");
|
|
24
|
+
if (!Number.isSafeInteger(input.schemaVersion) || input.schemaVersion < 1) {
|
|
25
|
+
throwInvalidMapping("schema version must be a positive safe integer");
|
|
26
|
+
}
|
|
27
|
+
if (input.fields.length === 0) {
|
|
28
|
+
throwInvalidMapping("an entity mapping must declare at least one field");
|
|
29
|
+
}
|
|
30
|
+
const fields = input.fields.map((field) => normalizeFieldMapping(field));
|
|
31
|
+
assertDistinct(fields.map((field) => field.property), "entity property");
|
|
32
|
+
assertDistinct(fields.map((field) => field.fieldName), "canonical field name");
|
|
33
|
+
const businessKey = fields.find((field) => field.property === input.businessKey);
|
|
34
|
+
if (businessKey === undefined) {
|
|
35
|
+
throwInvalidMapping("the business-key property must be declared as a mapped field");
|
|
36
|
+
}
|
|
37
|
+
if (!businessKey.required || !businessKey.unique) {
|
|
38
|
+
throwInvalidMapping("the business-key field must be required and unique");
|
|
39
|
+
}
|
|
40
|
+
if (fields.some((field) => field.unique && field.property !== input.businessKey)) {
|
|
41
|
+
throwInvalidMapping("v1 supports exactly one unique business-key field");
|
|
42
|
+
}
|
|
43
|
+
const projections = input.projections.map(normalizeProjectionMapping);
|
|
44
|
+
if (projections.length === 0) {
|
|
45
|
+
throwInvalidMapping("an entity mapping must declare a system_state projection");
|
|
46
|
+
}
|
|
47
|
+
assertDistinct(projections.map((projection) => projection.physicalSheetId), "physical sheet ID");
|
|
48
|
+
assertDistinct(projections.map((projection) => projection.projection), "projection kind");
|
|
49
|
+
if (!projections.some((projection) => projection.projection === SYNC_GATEWAY_PROJECTIONS.SYSTEM_STATE)) {
|
|
50
|
+
throwInvalidMapping("an entity mapping must declare exactly one system_state projection");
|
|
51
|
+
}
|
|
52
|
+
const tombstoneFieldName = input.tombstoneFieldName ?? "__typed_sheets_deleted";
|
|
53
|
+
requireText(tombstoneFieldName, "tombstone field name");
|
|
54
|
+
if (fields.some((field) => field.fieldName === tombstoneFieldName)) {
|
|
55
|
+
throwInvalidMapping("the tombstone field name cannot duplicate a mapped field");
|
|
56
|
+
}
|
|
57
|
+
const userInput = projections.find((projection) => projection.projection === SYNC_GATEWAY_PROJECTIONS.USER_INPUT);
|
|
58
|
+
if (userInput !== undefined && fields.every((field) => field.ownership !== FIELD_OWNERSHIPS.USER)) {
|
|
59
|
+
throwInvalidMapping("a user_input projection requires at least one user-owned field");
|
|
60
|
+
}
|
|
61
|
+
if (userInput !== undefined && businessKey.ownership !== FIELD_OWNERSHIPS.USER) {
|
|
62
|
+
throwInvalidMapping("a user_input projection requires a user-owned business-key field");
|
|
63
|
+
}
|
|
64
|
+
return {
|
|
65
|
+
entity: input.entity,
|
|
66
|
+
entityName,
|
|
67
|
+
logicalSheetId: input.logicalSheetId,
|
|
68
|
+
primaryKey: input.primaryKey,
|
|
69
|
+
businessKey,
|
|
70
|
+
schemaVersion: input.schemaVersion,
|
|
71
|
+
fields,
|
|
72
|
+
projections,
|
|
73
|
+
tombstoneFieldName,
|
|
74
|
+
anchorForEntity: input.anchorForEntity ?? defaultAnchorForEntity,
|
|
75
|
+
};
|
|
76
|
+
}
|
|
77
|
+
function normalizeFieldMapping(field) {
|
|
78
|
+
const property = field.property;
|
|
79
|
+
const fieldName = field.fieldName ?? property;
|
|
80
|
+
requireText(property, "entity property");
|
|
81
|
+
requireText(fieldName, "canonical field name");
|
|
82
|
+
if (!isNormalizedCellKind(field.cellKind)) {
|
|
83
|
+
throwInvalidMapping(`${fieldName} has an unsupported normalized cell kind`);
|
|
84
|
+
}
|
|
85
|
+
if (field.ownership !== FIELD_OWNERSHIPS.USER && field.ownership !== FIELD_OWNERSHIPS.SYSTEM) {
|
|
86
|
+
throwInvalidMapping(`${fieldName} has an unsupported ownership`);
|
|
87
|
+
}
|
|
88
|
+
return {
|
|
89
|
+
property,
|
|
90
|
+
fieldName,
|
|
91
|
+
cellKind: field.cellKind,
|
|
92
|
+
ownership: field.ownership,
|
|
93
|
+
required: field.required ?? false,
|
|
94
|
+
unique: field.unique ?? false,
|
|
95
|
+
...(field.encode === undefined ? {} : { encode: field.encode }),
|
|
96
|
+
...(field.decode === undefined ? {} : { decode: field.decode }),
|
|
97
|
+
};
|
|
98
|
+
}
|
|
99
|
+
function normalizeProjectionMapping(projection) {
|
|
100
|
+
requireText(projection.physicalSheetId, "physical sheet ID");
|
|
101
|
+
requireText(projection.spreadsheetId, "spreadsheet ID");
|
|
102
|
+
requireText(projection.tabName, "tab name");
|
|
103
|
+
requireText(projection.registeredRange, "registered range");
|
|
104
|
+
if (projection.projection !== SYNC_GATEWAY_PROJECTIONS.USER_INPUT &&
|
|
105
|
+
projection.projection !== SYNC_GATEWAY_PROJECTIONS.SYSTEM_STATE) {
|
|
106
|
+
throwInvalidMapping("an entity mapping supports only user_input and system_state projections");
|
|
107
|
+
}
|
|
108
|
+
return { ...projection };
|
|
109
|
+
}
|
|
110
|
+
function entityReferenceName(entity) {
|
|
111
|
+
if (typeof entity === "string")
|
|
112
|
+
return entity;
|
|
113
|
+
const name = entity.name;
|
|
114
|
+
if (typeof name !== "string") {
|
|
115
|
+
throwInvalidMapping("an entity class must expose a stable name or entityName must be provided");
|
|
116
|
+
}
|
|
117
|
+
return name;
|
|
118
|
+
}
|
|
119
|
+
function assertDistinct(values, label) {
|
|
120
|
+
const seen = new Set();
|
|
121
|
+
for (const value of values) {
|
|
122
|
+
if (seen.has(value)) {
|
|
123
|
+
throwInvalidMapping(`a mapping cannot repeat ${label}: ${value}`);
|
|
124
|
+
}
|
|
125
|
+
seen.add(value);
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
function defaultAnchorForEntity(entityId) {
|
|
129
|
+
return `entity:${entityId}`;
|
|
130
|
+
}
|
|
131
|
+
function isNormalizedCellKind(value) {
|
|
132
|
+
return value === NORMALIZED_CELL_KINDS.STRING ||
|
|
133
|
+
value === NORMALIZED_CELL_KINDS.NUMBER ||
|
|
134
|
+
value === NORMALIZED_CELL_KINDS.BOOLEAN ||
|
|
135
|
+
value === NORMALIZED_CELL_KINDS.DATE;
|
|
136
|
+
}
|
|
137
|
+
function requireText(value, label) {
|
|
138
|
+
if (value.length === EMPTY_STRING_LENGTH_ZERO) {
|
|
139
|
+
throwInvalidMapping(`${label} is required`);
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
function throwInvalidMapping(message) {
|
|
143
|
+
throw new TypedSheetsOrmError(TYPED_SHEETS_ORM_ERROR_CODES.INVALID_ENTITY_MAPPING, message);
|
|
144
|
+
}
|
|
145
|
+
//# sourceMappingURL=definition.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"definition.js","sourceRoot":"","sources":["../../../../src/application/orm/mapping/definition.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EACL,wBAAwB,EACxB,gBAAgB,GACjB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EACL,qBAAqB,GAEtB,MAAM,uCAAuC,CAAC;AAC/C,OAAO,EAAE,wBAAwB,EAAE,MAAM,iCAAiC,CAAC;AAS3E,OAAO,EACL,4BAA4B,EAC5B,mBAAmB,GACpB,MAAM,cAAc,CAAC;AAEtB;;;;;;GAMG;AACH,MAAM,UAAU,8BAA8B,CAC5C,KAA4C;IAE5C,MAAM,UAAU,GAAG,KAAK,CAAC,UAAU,IAAI,mBAAmB,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;IACzE,WAAW,CAAC,UAAU,EAAE,aAAa,CAAC,CAAC;IACvC,WAAW,CAAC,KAAK,CAAC,cAAc,EAAE,kBAAkB,CAAC,CAAC;IACt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AAc,CAAC,MAAyB,EAAE,KAAa;IAC9D,MAAM,IAAI,GAAG,IAAI,GAAG,EAAU,CAAC;IAC/B,KAAK,MAAM,KAAK,IAAI,MAAM,EAAE,CAAC;QAC3B,IAAI,IAAI,CAAC,GAAG,CAAC,KAAK,CAAC,EAAE,CAAC;YACpB,mBAAmB,CAAC,2BAA2B,KAAK,KAAK,KAAK,EAAE,CAAC,CAAC;QACpE,CAAC;QACD,IAAI,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC;IAClB,CAAC;AACH,CAAC;AAED,SAAS,sBAAsB,CAAC,QAAgB;IAC9C,OAAO,UAAU,QAAQ,EAAE,CAAC;AAC9B,CAAC;AAED,SAAS,oBAAoB,CAAC,KAAc;IAC1C,OAAO,KAAK,KAAK,qBAAqB,CAAC,MAAM;QAC3C,KAAK,KAAK,qBAAqB,CAAC,MAAM;QACtC,KAAK,KAAK,qBAAqB,CAAC,OAAO;QACvC,KAAK,KAAK,qBAAqB,CAAC,IAAI,CAAC;AACzC,CAAC;AAED,SAAS,WAAW,CAAC,KAAa,EAAE,KAAa;IAC/C,IAAI,KAAK,CAAC,MAAM,KAAK,wBAAwB,EAAE,CAAC;QAC9C,mBAAmB,CAAC,GAAG,KAAK,cAAc,CAAC,CAAC;IAC9C,CAAC;AACH,CAAC;AAED,SAAS,mBAAmB,CAAC,OAAe;IAC1C,MAAM,IAAI,mBAAmB,CAAC,4BAA4B,CAAC,sBAAsB,EAAE,OAAO,CAAC,CAAC;AAC9F,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Public mapping entrypoint.
|
|
3
|
+
*
|
|
4
|
+
* Implementation is split by responsibility; this barrel preserves the
|
|
5
|
+
* existing import path for callers while keeping the individual modules small.
|
|
6
|
+
*/
|
|
7
|
+
export * from "./contracts.js";
|
|
8
|
+
export * from "./definition.js";
|
|
9
|
+
export * from "./identity.js";
|
|
10
|
+
export * from "./projection.js";
|
|
11
|
+
export * from "./registry.js";
|
|
12
|
+
export * from "./values.js";
|
|
13
|
+
//# sourceMappingURL=entityMapping.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"entityMapping.d.ts","sourceRoot":"","sources":["../../../../src/application/orm/mapping/entityMapping.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,cAAc,gBAAgB,CAAC;AAC/B,cAAc,iBAAiB,CAAC;AAChC,cAAc,eAAe,CAAC;AAC9B,cAAc,iBAAiB,CAAC;AAChC,cAAc,eAAe,CAAC;AAC9B,cAAc,aAAa,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Public mapping entrypoint.
|
|
3
|
+
*
|
|
4
|
+
* Implementation is split by responsibility; this barrel preserves the
|
|
5
|
+
* existing import path for callers while keeping the individual modules small.
|
|
6
|
+
*/
|
|
7
|
+
export * from "./contracts.js";
|
|
8
|
+
export * from "./definition.js";
|
|
9
|
+
export * from "./identity.js";
|
|
10
|
+
export * from "./projection.js";
|
|
11
|
+
export * from "./registry.js";
|
|
12
|
+
export * from "./values.js";
|
|
13
|
+
//# sourceMappingURL=entityMapping.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"entityMapping.js","sourceRoot":"","sources":["../../../../src/application/orm/mapping/entityMapping.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,cAAc,gBAAgB,CAAC;AAC/B,cAAc,iBAAiB,CAAC;AAChC,cAAc,eAAe,CAAC;AAC9B,cAAc,iBAAiB,CAAC;AAChC,cAAc,eAAe,CAAC;AAC9B,cAAc,aAAa,CAAC"}
|