@inixiative/json-rules 3.15.1 → 3.17.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/index.d.cts CHANGED
@@ -657,25 +657,47 @@ type EngineGlobalsState = {
657
657
  finestUnit: ClockUnit | RelativeUnit;
658
658
  };
659
659
  };
660
- /** Each path `engineGlobals` reads and writes, and the values it takes. */
661
- type EngineGlobalValues = {
660
+ /**
661
+ * Each path `engineGlobals` reads and writes, and the values it takes. An interface, so a library
662
+ * built on the engine adds its own namespace's paths by module augmentation:
663
+ *
664
+ * ```ts
665
+ * declare module '@inixiative/json-rules' {
666
+ * interface EngineGlobalValues { 'permissions.idField': string }
667
+ * }
668
+ * ```
669
+ */
670
+ interface EngineGlobalValues {
662
671
  'string.caseInsensitive': EngineGlobalsState['string']['caseInsensitive'];
663
672
  'string.fuzzy': EngineGlobalsState['string']['fuzzy'];
664
673
  'prismaOptions.datasource.provider': EngineGlobalsState['prismaOptions']['datasource']['provider'];
665
674
  'prismaOptions.anyNull': EngineGlobalsState['prismaOptions']['anyNull'];
666
675
  'sql.dialect': EngineGlobalsState['sql']['dialect'];
667
676
  'clock.finestUnit': EngineGlobalsState['clock']['finestUnit'];
668
- };
677
+ }
669
678
  type EngineGlobalPath = keyof EngineGlobalValues;
679
+ /** The defaults a namespace registers: its paths, relative to the namespace. */
680
+ type EngineGlobalDefaults<N extends string> = {
681
+ [P in EngineGlobalPath as P extends `${N}.${infer K}` ? K : never]: EngineGlobalValues[P];
682
+ };
670
683
  type DeepPartial<T> = {
671
684
  [K in keyof T]?: T[K] extends object ? DeepPartial<T[K]> : T[K];
672
685
  };
686
+ type Overrides = Partial<EngineGlobalValues> | DeepPartial<EngineGlobalsState>;
687
+ /**
688
+ * Register a library's namespace of engine globals and its defaults. A library built on the
689
+ * engine calls this at the top of the module that reads the setting, for its own namespace only.
690
+ * Defaults go in under any value already set (an app may configure a library before importing
691
+ * it). Registering the same defaults again is a no-op (a second installed copy of the library);
692
+ * different defaults, a dotted namespace or one of the engine's own roots throw.
693
+ */
694
+ declare const registerEngineGlobals: <N extends string>(namespace: N, defaults: EngineGlobalDefaults<N>) => void;
673
695
  /** Process-wide defaults, read and written by dotted path (`EngineGlobalPath`). */
674
696
  declare const engineGlobals: {
675
697
  set: <P extends EngineGlobalPath>(path: P, value: EngineGlobalValues[P]) => void;
676
698
  get: <P extends EngineGlobalPath>(path: P) => EngineGlobalValues[P];
677
699
  reset: () => void;
678
- with: <T>(partial: DeepPartial<EngineGlobalsState>, fn: () => T) => T;
700
+ with: <T>(overrides: Overrides, fn: () => T) => T;
679
701
  };
680
702
 
681
703
  /** A caller's input missing or malformed — the clock, the time zone, a bind's value — not the
@@ -1182,8 +1204,19 @@ type LensWhereSqlOptions = {
1182
1204
  * `'<Model>.<field>'`. */
1183
1205
  columns: Record<string, string>;
1184
1206
  /** To-many relation path → the caller's SQL for its table, as `toWhereSql` reads it: by its path
1185
- * from the lens model in a path `where`, `'<Model>.<relation>'` in a model default. */
1207
+ * from the lens model in a path `where`, `'<Model>.<relation>'` in a model default. Not read with
1208
+ * `toMany: 'join'`. */
1186
1209
  tables?: Record<string, string>;
1210
+ /** What an array rule on a to-many relation reads. `'subquery'` (the default): an `EXISTS` on its
1211
+ * table from `tables`, carrying its clamps. `'join'`: the row the caller's LEFT JOIN brings — the
1212
+ * caller joins each to-many relation the root's `where` reads (a relation the lens declares), ON
1213
+ * its keys AND `relations[path]` AND the related model's `mapDefaults` entry; a join the `where`
1214
+ * does not read only fans the rows out (count distinct), and a read of one the caller did not
1215
+ * join fails loudly (a missing column). Only the root's `where` reads one, with `notEmpty`
1216
+ * (`<key> IS NOT NULL`) or one `any` (`(<key> IS NOT NULL AND cond)`), and only when every clamp
1217
+ * in that ON sits in a layer above the `where`'s, and the related model's default (if any) is
1218
+ * needed on that join alone — not on the root, not on another joined relation. */
1219
+ toMany?: 'subquery' | 'join';
1187
1220
  };
1188
1221
  /** A lens's `where`s as SQL, each where the lens wrote it. */
1189
1222
  type LensWhereSql = {
@@ -1197,7 +1230,7 @@ type LensWhereSql = {
1197
1230
  models: Record<string, string>;
1198
1231
  }>;
1199
1232
  };
1200
- declare const toLensWhereSql: (lens: Lens | LensNarrowing, { columns, tables }: LensWhereSqlOptions) => LensWhereSql;
1233
+ declare const toLensWhereSql: (lens: Lens | LensNarrowing, { columns, tables, toMany }: LensWhereSqlOptions) => LensWhereSql;
1201
1234
 
1202
1235
  /** Gate a rule against a lens: every field and value-side ref resolves through it, and every
1203
1236
  * operator, value and amount fits the field it reaches. */
@@ -1369,4 +1402,4 @@ declare const getConditionShapeKeys: (shape: ConditionShape) => ConditionShapeKe
1369
1402
  */
1370
1403
  declare const orderRecords: <T>(items: readonly T[], orderBy: OrderBy) => T[];
1371
1404
 
1372
- export { ALL_KINDS, type Absent, type AggregateMode, type AggregateRule, type All, type Any, ArrayOperator, type ArrayRule, type Bridge, type BridgeCardinality, type BridgeDictionary, type BridgeEndpoint, CLOCK_UNITS, type CheckData, type CheckOptions, type ClockUnit, type CompileOptions, type Condition, ConditionShape, type ConditionShapeKeys, type DateConfig, type DateExpr, type DateInputOrExpr, type DateInputValue, type DateOffset, DateOperator, type DateRule, type DateRuleValue, type EdgeExpr, type EngineGlobalPath, type EngineGlobalValues, type EngineGlobalsState, type EnumNarrowing, FieldKind, type FieldMap, type FieldMapEntry, type FieldMapSet, type FuzzyConfig, type GroupByStep, type IfThenElse, type Lens, type LensClamps, type LensNarrowing, type LensPathHop, type LensPathResolution, LensRefusal, type LensRelationSelect, type LensSelect, type LensSelectOptions, type LensValue, type LensWhereSql, type LensWhereSqlOptions, type ListBindingsOptions, type Magnitude, type MaterializeSourceQueryOptions, type ModelDefaultNarrowing, type ModelEntry, type ModelNarrowing, NUMERIC_KINDS, type NarrowingDefaults, type NumberOffset, Operator, type OperatorFamily, type OrderBy, type OrderedRuleValue, type PathProjection, type PeriodExpr, type PeriodUnit, type PrismaProvider, type PrismaStep, type PrismaWhere, type ProjectLensOptions, type ProjectRowsOptions, type ProjectedVisit, type RelativeUnit, type RelativeUnits, type RollingExpr, type Row, type Rule, type RuleDescription, type RuleScalar, type RuleSourceDescription, RuleTarget, type RuleValue, type ScopeOutOfBounds, type ScopeRef, type ScopedRef, type SortDir, type SourceEntry, type SourceOption, SourceOptionOrder, type SourcePrismaQuery, type SourceQuery, type SourceRowShape, type SourceSelect, type SourceSpec, type SourceSqlQuery, type SourceValues, SqlDialect, type StepRef, type StoredLens, type StrictAggregateRule, type StrictAll, type StrictAny, type StrictArrayCountRule, type StrictArrayPredicateRule, type StrictArrayPresenceRule, type StrictArrayRule, type StrictCondition, type StrictContainsRule, type StrictDateComparisonRule, type StrictDateDayRule, type StrictDateRangeRule, type StrictDateRule, type StrictEqualityRule, type StrictIfThenElse, type StrictMembershipRule, type StrictOrderedComparisonRule, type StrictPatternRule, type StrictPresenceRule, type StrictRangeRule, type StrictRule, type StrictStringBoundaryRule, type TimeZoneConfig, type ToPrismaOptions, type ToPrismaResult, type ToSqlOptions, type ToSqlResult, UsageError, type ValidateRuleOptions, type ValidationIssue, type ValidationResult, ValueShape, type ValueSourceFields, type ValueSourceOf, type WeekStart, type WhereSqlOptions, type WhereStep, type WindowFields, andWhere, assertValidFieldMaps, assertValidNarrowing, assertValidRule, bindLens, bindRule, check, clampLens, clockUnit, coerceRule, composeLens, createLens, describeRule, describeRuleSources, engineGlobals, executePrismaPlan, getAggregateOperators, getArrayOperators, getConditionShapeKeys, getLensRoot, getOperatorsForKind, getValueShape, indexBridges, lensVisit, listBindings, listLensBindings, matchAll, matchNothing, materializeSourceQuery, materializeSources, narrowRule, orWhere, orderRecords, parseScopeRef, prefixConditionFields, projectLens, projectRows, readLensValue, readScopeRef, stitchFieldMaps, storeLens, toLensSelect, toLensWhereSql, toPrisma, toSourceQueries, toSql, toWhereSql, validateFieldMaps, validateNarrowing, validateRule, validateRuleInLens, walkLensPath };
1405
+ export { ALL_KINDS, type Absent, type AggregateMode, type AggregateRule, type All, type Any, ArrayOperator, type ArrayRule, type Bridge, type BridgeCardinality, type BridgeDictionary, type BridgeEndpoint, CLOCK_UNITS, type CheckData, type CheckOptions, type ClockUnit, type CompileOptions, type Condition, ConditionShape, type ConditionShapeKeys, type DateConfig, type DateExpr, type DateInputOrExpr, type DateInputValue, type DateOffset, DateOperator, type DateRule, type DateRuleValue, type EdgeExpr, type EngineGlobalDefaults, type EngineGlobalPath, type EngineGlobalValues, type EngineGlobalsState, type EnumNarrowing, FieldKind, type FieldMap, type FieldMapEntry, type FieldMapSet, type FuzzyConfig, type GroupByStep, type IfThenElse, type Lens, type LensClamps, type LensNarrowing, type LensPathHop, type LensPathResolution, LensRefusal, type LensRelationSelect, type LensSelect, type LensSelectOptions, type LensValue, type LensWhereSql, type LensWhereSqlOptions, type ListBindingsOptions, type Magnitude, type MaterializeSourceQueryOptions, type ModelDefaultNarrowing, type ModelEntry, type ModelNarrowing, NUMERIC_KINDS, type NarrowingDefaults, type NumberOffset, Operator, type OperatorFamily, type OrderBy, type OrderedRuleValue, type PathProjection, type PeriodExpr, type PeriodUnit, type PrismaProvider, type PrismaStep, type PrismaWhere, type ProjectLensOptions, type ProjectRowsOptions, type ProjectedVisit, type RelativeUnit, type RelativeUnits, type RollingExpr, type Row, type Rule, type RuleDescription, type RuleScalar, type RuleSourceDescription, RuleTarget, type RuleValue, type ScopeOutOfBounds, type ScopeRef, type ScopedRef, type SortDir, type SourceEntry, type SourceOption, SourceOptionOrder, type SourcePrismaQuery, type SourceQuery, type SourceRowShape, type SourceSelect, type SourceSpec, type SourceSqlQuery, type SourceValues, SqlDialect, type StepRef, type StoredLens, type StrictAggregateRule, type StrictAll, type StrictAny, type StrictArrayCountRule, type StrictArrayPredicateRule, type StrictArrayPresenceRule, type StrictArrayRule, type StrictCondition, type StrictContainsRule, type StrictDateComparisonRule, type StrictDateDayRule, type StrictDateRangeRule, type StrictDateRule, type StrictEqualityRule, type StrictIfThenElse, type StrictMembershipRule, type StrictOrderedComparisonRule, type StrictPatternRule, type StrictPresenceRule, type StrictRangeRule, type StrictRule, type StrictStringBoundaryRule, type TimeZoneConfig, type ToPrismaOptions, type ToPrismaResult, type ToSqlOptions, type ToSqlResult, UsageError, type ValidateRuleOptions, type ValidationIssue, type ValidationResult, ValueShape, type ValueSourceFields, type ValueSourceOf, type WeekStart, type WhereSqlOptions, type WhereStep, type WindowFields, andWhere, assertValidFieldMaps, assertValidNarrowing, assertValidRule, bindLens, bindRule, check, clampLens, clockUnit, coerceRule, composeLens, createLens, describeRule, describeRuleSources, engineGlobals, executePrismaPlan, getAggregateOperators, getArrayOperators, getConditionShapeKeys, getLensRoot, getOperatorsForKind, getValueShape, indexBridges, lensVisit, listBindings, listLensBindings, matchAll, matchNothing, materializeSourceQuery, materializeSources, narrowRule, orWhere, orderRecords, parseScopeRef, prefixConditionFields, projectLens, projectRows, readLensValue, readScopeRef, registerEngineGlobals, stitchFieldMaps, storeLens, toLensSelect, toLensWhereSql, toPrisma, toSourceQueries, toSql, toWhereSql, validateFieldMaps, validateNarrowing, validateRule, validateRuleInLens, walkLensPath };
package/dist/index.d.ts CHANGED
@@ -657,25 +657,47 @@ type EngineGlobalsState = {
657
657
  finestUnit: ClockUnit | RelativeUnit;
658
658
  };
659
659
  };
660
- /** Each path `engineGlobals` reads and writes, and the values it takes. */
661
- type EngineGlobalValues = {
660
+ /**
661
+ * Each path `engineGlobals` reads and writes, and the values it takes. An interface, so a library
662
+ * built on the engine adds its own namespace's paths by module augmentation:
663
+ *
664
+ * ```ts
665
+ * declare module '@inixiative/json-rules' {
666
+ * interface EngineGlobalValues { 'permissions.idField': string }
667
+ * }
668
+ * ```
669
+ */
670
+ interface EngineGlobalValues {
662
671
  'string.caseInsensitive': EngineGlobalsState['string']['caseInsensitive'];
663
672
  'string.fuzzy': EngineGlobalsState['string']['fuzzy'];
664
673
  'prismaOptions.datasource.provider': EngineGlobalsState['prismaOptions']['datasource']['provider'];
665
674
  'prismaOptions.anyNull': EngineGlobalsState['prismaOptions']['anyNull'];
666
675
  'sql.dialect': EngineGlobalsState['sql']['dialect'];
667
676
  'clock.finestUnit': EngineGlobalsState['clock']['finestUnit'];
668
- };
677
+ }
669
678
  type EngineGlobalPath = keyof EngineGlobalValues;
679
+ /** The defaults a namespace registers: its paths, relative to the namespace. */
680
+ type EngineGlobalDefaults<N extends string> = {
681
+ [P in EngineGlobalPath as P extends `${N}.${infer K}` ? K : never]: EngineGlobalValues[P];
682
+ };
670
683
  type DeepPartial<T> = {
671
684
  [K in keyof T]?: T[K] extends object ? DeepPartial<T[K]> : T[K];
672
685
  };
686
+ type Overrides = Partial<EngineGlobalValues> | DeepPartial<EngineGlobalsState>;
687
+ /**
688
+ * Register a library's namespace of engine globals and its defaults. A library built on the
689
+ * engine calls this at the top of the module that reads the setting, for its own namespace only.
690
+ * Defaults go in under any value already set (an app may configure a library before importing
691
+ * it). Registering the same defaults again is a no-op (a second installed copy of the library);
692
+ * different defaults, a dotted namespace or one of the engine's own roots throw.
693
+ */
694
+ declare const registerEngineGlobals: <N extends string>(namespace: N, defaults: EngineGlobalDefaults<N>) => void;
673
695
  /** Process-wide defaults, read and written by dotted path (`EngineGlobalPath`). */
674
696
  declare const engineGlobals: {
675
697
  set: <P extends EngineGlobalPath>(path: P, value: EngineGlobalValues[P]) => void;
676
698
  get: <P extends EngineGlobalPath>(path: P) => EngineGlobalValues[P];
677
699
  reset: () => void;
678
- with: <T>(partial: DeepPartial<EngineGlobalsState>, fn: () => T) => T;
700
+ with: <T>(overrides: Overrides, fn: () => T) => T;
679
701
  };
680
702
 
681
703
  /** A caller's input missing or malformed — the clock, the time zone, a bind's value — not the
@@ -1182,8 +1204,19 @@ type LensWhereSqlOptions = {
1182
1204
  * `'<Model>.<field>'`. */
1183
1205
  columns: Record<string, string>;
1184
1206
  /** To-many relation path → the caller's SQL for its table, as `toWhereSql` reads it: by its path
1185
- * from the lens model in a path `where`, `'<Model>.<relation>'` in a model default. */
1207
+ * from the lens model in a path `where`, `'<Model>.<relation>'` in a model default. Not read with
1208
+ * `toMany: 'join'`. */
1186
1209
  tables?: Record<string, string>;
1210
+ /** What an array rule on a to-many relation reads. `'subquery'` (the default): an `EXISTS` on its
1211
+ * table from `tables`, carrying its clamps. `'join'`: the row the caller's LEFT JOIN brings — the
1212
+ * caller joins each to-many relation the root's `where` reads (a relation the lens declares), ON
1213
+ * its keys AND `relations[path]` AND the related model's `mapDefaults` entry; a join the `where`
1214
+ * does not read only fans the rows out (count distinct), and a read of one the caller did not
1215
+ * join fails loudly (a missing column). Only the root's `where` reads one, with `notEmpty`
1216
+ * (`<key> IS NOT NULL`) or one `any` (`(<key> IS NOT NULL AND cond)`), and only when every clamp
1217
+ * in that ON sits in a layer above the `where`'s, and the related model's default (if any) is
1218
+ * needed on that join alone — not on the root, not on another joined relation. */
1219
+ toMany?: 'subquery' | 'join';
1187
1220
  };
1188
1221
  /** A lens's `where`s as SQL, each where the lens wrote it. */
1189
1222
  type LensWhereSql = {
@@ -1197,7 +1230,7 @@ type LensWhereSql = {
1197
1230
  models: Record<string, string>;
1198
1231
  }>;
1199
1232
  };
1200
- declare const toLensWhereSql: (lens: Lens | LensNarrowing, { columns, tables }: LensWhereSqlOptions) => LensWhereSql;
1233
+ declare const toLensWhereSql: (lens: Lens | LensNarrowing, { columns, tables, toMany }: LensWhereSqlOptions) => LensWhereSql;
1201
1234
 
1202
1235
  /** Gate a rule against a lens: every field and value-side ref resolves through it, and every
1203
1236
  * operator, value and amount fits the field it reaches. */
@@ -1369,4 +1402,4 @@ declare const getConditionShapeKeys: (shape: ConditionShape) => ConditionShapeKe
1369
1402
  */
1370
1403
  declare const orderRecords: <T>(items: readonly T[], orderBy: OrderBy) => T[];
1371
1404
 
1372
- export { ALL_KINDS, type Absent, type AggregateMode, type AggregateRule, type All, type Any, ArrayOperator, type ArrayRule, type Bridge, type BridgeCardinality, type BridgeDictionary, type BridgeEndpoint, CLOCK_UNITS, type CheckData, type CheckOptions, type ClockUnit, type CompileOptions, type Condition, ConditionShape, type ConditionShapeKeys, type DateConfig, type DateExpr, type DateInputOrExpr, type DateInputValue, type DateOffset, DateOperator, type DateRule, type DateRuleValue, type EdgeExpr, type EngineGlobalPath, type EngineGlobalValues, type EngineGlobalsState, type EnumNarrowing, FieldKind, type FieldMap, type FieldMapEntry, type FieldMapSet, type FuzzyConfig, type GroupByStep, type IfThenElse, type Lens, type LensClamps, type LensNarrowing, type LensPathHop, type LensPathResolution, LensRefusal, type LensRelationSelect, type LensSelect, type LensSelectOptions, type LensValue, type LensWhereSql, type LensWhereSqlOptions, type ListBindingsOptions, type Magnitude, type MaterializeSourceQueryOptions, type ModelDefaultNarrowing, type ModelEntry, type ModelNarrowing, NUMERIC_KINDS, type NarrowingDefaults, type NumberOffset, Operator, type OperatorFamily, type OrderBy, type OrderedRuleValue, type PathProjection, type PeriodExpr, type PeriodUnit, type PrismaProvider, type PrismaStep, type PrismaWhere, type ProjectLensOptions, type ProjectRowsOptions, type ProjectedVisit, type RelativeUnit, type RelativeUnits, type RollingExpr, type Row, type Rule, type RuleDescription, type RuleScalar, type RuleSourceDescription, RuleTarget, type RuleValue, type ScopeOutOfBounds, type ScopeRef, type ScopedRef, type SortDir, type SourceEntry, type SourceOption, SourceOptionOrder, type SourcePrismaQuery, type SourceQuery, type SourceRowShape, type SourceSelect, type SourceSpec, type SourceSqlQuery, type SourceValues, SqlDialect, type StepRef, type StoredLens, type StrictAggregateRule, type StrictAll, type StrictAny, type StrictArrayCountRule, type StrictArrayPredicateRule, type StrictArrayPresenceRule, type StrictArrayRule, type StrictCondition, type StrictContainsRule, type StrictDateComparisonRule, type StrictDateDayRule, type StrictDateRangeRule, type StrictDateRule, type StrictEqualityRule, type StrictIfThenElse, type StrictMembershipRule, type StrictOrderedComparisonRule, type StrictPatternRule, type StrictPresenceRule, type StrictRangeRule, type StrictRule, type StrictStringBoundaryRule, type TimeZoneConfig, type ToPrismaOptions, type ToPrismaResult, type ToSqlOptions, type ToSqlResult, UsageError, type ValidateRuleOptions, type ValidationIssue, type ValidationResult, ValueShape, type ValueSourceFields, type ValueSourceOf, type WeekStart, type WhereSqlOptions, type WhereStep, type WindowFields, andWhere, assertValidFieldMaps, assertValidNarrowing, assertValidRule, bindLens, bindRule, check, clampLens, clockUnit, coerceRule, composeLens, createLens, describeRule, describeRuleSources, engineGlobals, executePrismaPlan, getAggregateOperators, getArrayOperators, getConditionShapeKeys, getLensRoot, getOperatorsForKind, getValueShape, indexBridges, lensVisit, listBindings, listLensBindings, matchAll, matchNothing, materializeSourceQuery, materializeSources, narrowRule, orWhere, orderRecords, parseScopeRef, prefixConditionFields, projectLens, projectRows, readLensValue, readScopeRef, stitchFieldMaps, storeLens, toLensSelect, toLensWhereSql, toPrisma, toSourceQueries, toSql, toWhereSql, validateFieldMaps, validateNarrowing, validateRule, validateRuleInLens, walkLensPath };
1405
+ export { ALL_KINDS, type Absent, type AggregateMode, type AggregateRule, type All, type Any, ArrayOperator, type ArrayRule, type Bridge, type BridgeCardinality, type BridgeDictionary, type BridgeEndpoint, CLOCK_UNITS, type CheckData, type CheckOptions, type ClockUnit, type CompileOptions, type Condition, ConditionShape, type ConditionShapeKeys, type DateConfig, type DateExpr, type DateInputOrExpr, type DateInputValue, type DateOffset, DateOperator, type DateRule, type DateRuleValue, type EdgeExpr, type EngineGlobalDefaults, type EngineGlobalPath, type EngineGlobalValues, type EngineGlobalsState, type EnumNarrowing, FieldKind, type FieldMap, type FieldMapEntry, type FieldMapSet, type FuzzyConfig, type GroupByStep, type IfThenElse, type Lens, type LensClamps, type LensNarrowing, type LensPathHop, type LensPathResolution, LensRefusal, type LensRelationSelect, type LensSelect, type LensSelectOptions, type LensValue, type LensWhereSql, type LensWhereSqlOptions, type ListBindingsOptions, type Magnitude, type MaterializeSourceQueryOptions, type ModelDefaultNarrowing, type ModelEntry, type ModelNarrowing, NUMERIC_KINDS, type NarrowingDefaults, type NumberOffset, Operator, type OperatorFamily, type OrderBy, type OrderedRuleValue, type PathProjection, type PeriodExpr, type PeriodUnit, type PrismaProvider, type PrismaStep, type PrismaWhere, type ProjectLensOptions, type ProjectRowsOptions, type ProjectedVisit, type RelativeUnit, type RelativeUnits, type RollingExpr, type Row, type Rule, type RuleDescription, type RuleScalar, type RuleSourceDescription, RuleTarget, type RuleValue, type ScopeOutOfBounds, type ScopeRef, type ScopedRef, type SortDir, type SourceEntry, type SourceOption, SourceOptionOrder, type SourcePrismaQuery, type SourceQuery, type SourceRowShape, type SourceSelect, type SourceSpec, type SourceSqlQuery, type SourceValues, SqlDialect, type StepRef, type StoredLens, type StrictAggregateRule, type StrictAll, type StrictAny, type StrictArrayCountRule, type StrictArrayPredicateRule, type StrictArrayPresenceRule, type StrictArrayRule, type StrictCondition, type StrictContainsRule, type StrictDateComparisonRule, type StrictDateDayRule, type StrictDateRangeRule, type StrictDateRule, type StrictEqualityRule, type StrictIfThenElse, type StrictMembershipRule, type StrictOrderedComparisonRule, type StrictPatternRule, type StrictPresenceRule, type StrictRangeRule, type StrictRule, type StrictStringBoundaryRule, type TimeZoneConfig, type ToPrismaOptions, type ToPrismaResult, type ToSqlOptions, type ToSqlResult, UsageError, type ValidateRuleOptions, type ValidationIssue, type ValidationResult, ValueShape, type ValueSourceFields, type ValueSourceOf, type WeekStart, type WhereSqlOptions, type WhereStep, type WindowFields, andWhere, assertValidFieldMaps, assertValidNarrowing, assertValidRule, bindLens, bindRule, check, clampLens, clockUnit, coerceRule, composeLens, createLens, describeRule, describeRuleSources, engineGlobals, executePrismaPlan, getAggregateOperators, getArrayOperators, getConditionShapeKeys, getLensRoot, getOperatorsForKind, getValueShape, indexBridges, lensVisit, listBindings, listLensBindings, matchAll, matchNothing, materializeSourceQuery, materializeSources, narrowRule, orWhere, orderRecords, parseScopeRef, prefixConditionFields, projectLens, projectRows, readLensValue, readScopeRef, registerEngineGlobals, stitchFieldMaps, storeLens, toLensSelect, toLensWhereSql, toPrisma, toSourceQueries, toSql, toWhereSql, validateFieldMaps, validateNarrowing, validateRule, validateRuleInLens, walkLensPath };