// Date_.d.ts
export = Date_;

declare class Date_ {
  constructor(hg: any);

  /**
   * 把日期字符串解析成时间戳（毫秒）
   */
  dateStringToTimestamp(dateString: string): number;

  /**
   * 返回 moment-timezone 实例（已默认 Asia/Shanghai）
   */
  moment(date?: string | number | Date): import('moment-timezone').Moment;

  /**
   * 把日期按指定格式输出（默认 YYYY-MM-DD HH:mm:ss）
   */
  format(date?: string | number | Date, format?: string): string;

  /**
   * 当前时间按指定格式输出（默认 YYYY-MM-DD HH:mm:ss）
   */
  nowFormat(format?: string): string;

  /**
   * 把起止日期按指定月份跨度拆分成若干段
   */
  splitDateRange(
    startDate: string,
    endDate: string,
    splitMonths: number
  ): Array<{
    begin: string;  // yyyy-mm-dd
    end: string;    // yyyy-mm-dd
    len: number;    // 实际月份数
    days: number;   // 实际天数
  }>;
}