Settings that affect how values are formatted.

Hierarchy (view full)

Constructors

Properties

_handles: Handles<unknown, ResourceHandle>

Do not directly reference this property. Use EventNames and EventTypes helpers from @arcgis/core/Evented.

Accessors

  • get currency(): string
  • The 3-letter ISO 4217 currency code (e.g "USD", "CAD"). Required when formatting a number using NumberFormat.CURRENCY or NumberFormat.ACCOUNTING.

    Returns string

  • set currency(value): void
  • Parameters

    • value: string

    Returns void

  • get dateFormat(): string
  • The default format for date values. Either a utilities/format/formats!DateFormat constant, a custom date format string.

    Returns string

  • set dateFormat(value): void
  • Parameters

    • value: string

    Returns void

  • get fractionalDigits(): number
  • The number of digits to show after the decimal point. If unspecified, an appropriate value is determined based on the locale and currency.

    Returns number

  • set fractionalDigits(value): void
  • Parameters

    • value: number

    Returns void

  • get locale(): string
  • The locale to use when formatting values.

    Returns string

  • set locale(value): void
  • Parameters

    • value: string

    Returns void

  • get numberFormat(): string
  • The default format for number values. Either a utilities/format/formats!NumberFormat constant, a custom number format string.

    Returns string

  • set numberFormat(value): void
  • Parameters

    • value: string

    Returns void

  • get parent(): this
  • The parent settings that these settings will inherit from.

    Returns this

  • set parent(value): void
  • Parameters

    • value: this

    Returns void

  • get timeFormat(): string
  • The default format for time values. Either a utilities/format/formats!TimeFormat constant, a custom time format string.

    Returns string

  • set timeFormat(value): void
  • Parameters

    • value: string

    Returns void

  • get timeZone(): string
  • The time zone to display date/time data in. The default will be the user's local time zone.

    Returns string

  • set timeZone(value): void
  • Parameters

    • value: string

    Returns void

  • get useFieldInfo(): boolean
  • Whether to use formatting from the field info if it is specified.

    Returns boolean

  • set useFieldInfo(value): void
  • Parameters

    • value: boolean

    Returns void

Methods

  • Gets the value for a setting that represents a collection.

    Type Parameters

    • T

    Parameters

    Returns Collection<T>

  • Gets a property which is itself an instance of Settings.

    Type Parameters

    Parameters

    • setting: keyof FormatSettings

      The setting name.

    • factory: (() => T)

      A factory for creating the nested settings.

        • (): T
        • Returns T

    Returns T

  • Determines whether the specified setting has been modified locally or by any parent of the current settings instance.

    Type Parameters

    Parameters

    • setting: K

      The setting to check.

    Returns boolean

  • Sets the parent settings that these settings will inherit from.

    Parameters

    Returns void

  • Sets the value for a setting. This will override any inherited value for the setting.

    Type Parameters

    Parameters

    Returns void

  • Parameters

    • properties: Partial<unknown>

    Returns void

  • Parameters

    • properties: Partial<unknown>

    Returns Promise<void>

  • Type Parameters

    • K extends never

    Parameters

    • key: K

    Returns unknown

  • Determines whether the settings have been locally modified in any way.

    Returns boolean

  • Determines whether the specified setting has been locally modified, and is thus overriding any inherited value.

    Parameters

    Returns boolean

  • Removes all local overrides, resetting all settings to their inherited values, if any.

    Returns void

  • Removes a local override for a setting and resets it to its inherited value, if any.

    Parameters

    Returns void