import { Type } from './Type.js';
/** Maps a database DATETIME/TIMESTAMP column to a JS `Date` object. */
export class DateTimeType extends Type {
  getColumnType(prop, platform) {
    return platform.getDateTimeTypeDeclarationSQL({ length: prop.length });
  }
  compareAsType() {
    return 'Date';
  }
  get runtimeType() {
    return 'Date';
  }
  ensureComparable() {
    return false;
  }
  getDefaultLength(platform) {
    return platform.getDefaultDateTimeLength();
  }
}
