Options
All
  • Public
  • Public/Protected
  • All
Menu

A class for managing time zones.

abstract

Hierarchy

  • Zones

Index

Constructors

Accessors

Methods

Constructors

Accessors

Methods

  • fixed(name: string, hour: number, minute?: number): FixedZone
  • iana(ianaName: string, opts?: { strict?: boolean }): IANAZone
  • Tries to resolve an IANA time zone. It first tries to find the zone in the repository. If find operation fails, it tries to create a RuntimeIANAZone (a Zone created by using javascript Intl API). If creating RuntimeIANAZone fails, this method returns undefined or throws an error (based on "opts.strict" parameter)

    static

    Parameters

    • ianaName: string
    • Optional opts: { strict?: boolean }
      • Optional strict?: boolean

    Returns IANAZone

  • resolve(zone: ZoneSpecifier, opts?: { strict?: boolean }): Zone
  • Tries to resolve a Zone by a ZoneSpecifier.

    static

    Parameters

    • zone: ZoneSpecifier
    • Optional opts: { strict?: boolean }
      • Optional strict?: boolean

    Returns Zone

Generated using TypeDoc