Initial commit
This commit is contained in:
54
node_modules/drizzle-orm/column.js
generated
vendored
Normal file
54
node_modules/drizzle-orm/column.js
generated
vendored
Normal file
@ -0,0 +1,54 @@
|
||||
import { entityKind } from "./entity.js";
|
||||
class Column {
|
||||
constructor(table, config) {
|
||||
this.table = table;
|
||||
this.config = config;
|
||||
this.name = config.name;
|
||||
this.keyAsName = config.keyAsName;
|
||||
this.notNull = config.notNull;
|
||||
this.default = config.default;
|
||||
this.defaultFn = config.defaultFn;
|
||||
this.onUpdateFn = config.onUpdateFn;
|
||||
this.hasDefault = config.hasDefault;
|
||||
this.primary = config.primaryKey;
|
||||
this.isUnique = config.isUnique;
|
||||
this.uniqueName = config.uniqueName;
|
||||
this.uniqueType = config.uniqueType;
|
||||
this.dataType = config.dataType;
|
||||
this.columnType = config.columnType;
|
||||
this.generated = config.generated;
|
||||
this.generatedIdentity = config.generatedIdentity;
|
||||
}
|
||||
static [entityKind] = "Column";
|
||||
name;
|
||||
keyAsName;
|
||||
primary;
|
||||
notNull;
|
||||
default;
|
||||
defaultFn;
|
||||
onUpdateFn;
|
||||
hasDefault;
|
||||
isUnique;
|
||||
uniqueName;
|
||||
uniqueType;
|
||||
dataType;
|
||||
columnType;
|
||||
enumValues = void 0;
|
||||
generated = void 0;
|
||||
generatedIdentity = void 0;
|
||||
config;
|
||||
mapFromDriverValue(value) {
|
||||
return value;
|
||||
}
|
||||
mapToDriverValue(value) {
|
||||
return value;
|
||||
}
|
||||
// ** @internal */
|
||||
shouldDisableInsert() {
|
||||
return this.config.generated !== void 0 && this.config.generated.type !== "byDefault";
|
||||
}
|
||||
}
|
||||
export {
|
||||
Column
|
||||
};
|
||||
//# sourceMappingURL=column.js.map
|
||||
Reference in New Issue
Block a user