checks.ts — drizzle-orm Source File
Architecture documentation for checks.ts, a typescript file in the drizzle-orm codebase. 3 imports, 2 dependents.
Entity Profile
Dependency Diagram
graph LR 171b1831_b7c8_175e_cfcd_84202c037834["checks.ts"] cbe7af57_41be_454d_306f_02d0e6f81949["table.ts"] 171b1831_b7c8_175e_cfcd_84202c037834 --> cbe7af57_41be_454d_306f_02d0e6f81949 27705a9d_afe9_57dd_8c97_e52d8a67d426["entity.ts"] 171b1831_b7c8_175e_cfcd_84202c037834 --> 27705a9d_afe9_57dd_8c97_e52d8a67d426 944a2bed_8787_5f43_03e5_9a3b696c293c["index.ts"] 171b1831_b7c8_175e_cfcd_84202c037834 --> 944a2bed_8787_5f43_03e5_9a3b696c293c cbe7af57_41be_454d_306f_02d0e6f81949["table.ts"] cbe7af57_41be_454d_306f_02d0e6f81949 --> 171b1831_b7c8_175e_cfcd_84202c037834 9cb8488e_0ece_edef_af6a_5851d56cddda["utils.ts"] 9cb8488e_0ece_edef_af6a_5851d56cddda --> 171b1831_b7c8_175e_cfcd_84202c037834 style 171b1831_b7c8_175e_cfcd_84202c037834 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
import { entityKind } from '~/entity.ts';
import type { SQL } from '~/sql/index.ts';
import type { GelTable } from './table.ts';
export class CheckBuilder {
static readonly [entityKind]: string = 'GelCheckBuilder';
protected brand!: 'GelConstraintBuilder';
constructor(public name: string, public value: SQL) {}
/** @internal */
build(table: GelTable): Check {
return new Check(table, this);
}
}
export class Check {
static readonly [entityKind]: string = 'GelCheck';
readonly name: string;
readonly value: SQL;
constructor(public table: GelTable, builder: CheckBuilder) {
this.name = builder.name;
this.value = builder.value;
}
}
export function check(name: string, value: SQL): CheckBuilder {
return new CheckBuilder(name, value);
}
Domain
Subdomains
Functions
Classes
Dependencies
- entity.ts
- index.ts
- table.ts
Source
Frequently Asked Questions
What does checks.ts do?
checks.ts is a source file in the drizzle-orm codebase, written in typescript. It belongs to the DrizzleORM domain, RelationalQuery subdomain.
What functions are defined in checks.ts?
checks.ts defines 1 function(s): check.
What does checks.ts depend on?
checks.ts imports 3 module(s): entity.ts, index.ts, table.ts.
What files import checks.ts?
checks.ts is imported by 2 file(s): table.ts, utils.ts.
Where is checks.ts in the architecture?
checks.ts is located at drizzle-orm/src/gel-core/checks.ts (domain: DrizzleORM, subdomain: RelationalQuery, directory: drizzle-orm/src/gel-core).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free