duration.js 655 B

123456789101112131415161718192021222324252627
  1. import { entityKind } from "../../entity.js";
  2. import { GelColumn, GelColumnBuilder } from "./common.js";
  3. class GelDurationBuilder extends GelColumnBuilder {
  4. static [entityKind] = "GelDurationBuilder";
  5. constructor(name) {
  6. super(name, "duration", "GelDuration");
  7. }
  8. /** @internal */
  9. build(table) {
  10. return new GelDuration(table, this.config);
  11. }
  12. }
  13. class GelDuration extends GelColumn {
  14. static [entityKind] = "GelDuration";
  15. getSQLType() {
  16. return `duration`;
  17. }
  18. }
  19. function duration(name) {
  20. return new GelDurationBuilder(name ?? "");
  21. }
  22. export {
  23. GelDuration,
  24. GelDurationBuilder,
  25. duration
  26. };
  27. //# sourceMappingURL=duration.js.map