UNPKG

@ultipa-graph/ultipa-driver

Version:

NodeJS SDK for ultipa-server 5.2

15 lines (14 loc) 750 B
import moment from "moment-timezone"; import * as ULTIPA from "../types/types"; export declare class UltipaDatetime { static datetimeInt2datetimeStr(intString: string): string; static datetimeStr2datetimeString(time: string): string; static getMoment(timestamp: string | number, timezone: ULTIPA.Timezone): moment.Moment; static timestamp2Str(timestamp_seconds: number, timezone: ULTIPA.Timezone): string; static timestampStr2int(timestamp_str: string, timezone: ULTIPA.Timezone): number; /** * Parses a timezone offset string or number into seconds. * Supports formats: "+08:30", "-05:00", "+2", "-0300", "8.5", etc. */ static parseTimezoneOffsetToSeconds(offset: string | number): number; }