Class DApplicationCommandOption

Hierarchy (view full)

Constructors

Properties

_classRef: Record<string, any>
_from: Record<string, any>
_index?: number
_key: string
_method?: Record<string, any>

Accessors

  • get classRef(): Record<string, any>
  • Gets or sets the class reference being decorated.

    Returns Record<string, any>

  • set classRef(value): void
  • Parameters

    • value: Record<string, any>

    Returns void

  • get descriptionLocalizations(): null | Partial<Record<
        | "id"
        | "en-US"
        | "en-GB"
        | "bg"
        | "zh-CN"
        | "zh-TW"
        | "hr"
        | "cs"
        | "da"
        | "nl"
        | "fi"
        | "fr"
        | "de"
        | "el"
        | "hi"
        | "hu"
        | "it"
        | "ja"
        | "ko"
        | "lt"
        | "no"
        | "pl"
        | "pt-BR"
        | "ro"
        | "ru"
        | "es-ES"
        | "es-419"
        | "sv-SE"
        | "th"
        | "tr"
        | "uk"
        | "vi", null | string>>
  • Returns null | Partial<Record<
        | "id"
        | "en-US"
        | "en-GB"
        | "bg"
        | "zh-CN"
        | "zh-TW"
        | "hr"
        | "cs"
        | "da"
        | "nl"
        | "fi"
        | "fr"
        | "de"
        | "el"
        | "hi"
        | "hu"
        | "it"
        | "ja"
        | "ko"
        | "lt"
        | "no"
        | "pl"
        | "pt-BR"
        | "ro"
        | "ru"
        | "es-ES"
        | "es-419"
        | "sv-SE"
        | "th"
        | "tr"
        | "uk"
        | "vi", null | string>>

  • set descriptionLocalizations(value): void
  • Parameters

    • value: null | Partial<Record<
          | "id"
          | "en-US"
          | "en-GB"
          | "bg"
          | "zh-CN"
          | "zh-TW"
          | "hr"
          | "cs"
          | "da"
          | "nl"
          | "fi"
          | "fr"
          | "de"
          | "el"
          | "hi"
          | "hu"
          | "it"
          | "ja"
          | "ko"
          | "lt"
          | "no"
          | "pl"
          | "pt-BR"
          | "ro"
          | "ru"
          | "es-ES"
          | "es-419"
          | "sv-SE"
          | "th"
          | "tr"
          | "uk"
          | "vi", null | string>>

    Returns void

  • get from(): Record<string, any>
  • Gets or sets the originating class reference.

    Returns Record<string, any>

  • set from(value): void
  • Parameters

    • value: Record<string, any>

    Returns void

  • get index(): undefined | number
  • Gets the index of the parameter being decorated, if applicable.

    Returns undefined | number

  • get isClass(): boolean
  • Determines if the target is a class.

    Returns boolean

  • get key(): string
  • Gets the key of the property or method being decorated.

    Returns string

  • get method(): undefined | Record<string, any>
  • Gets the method descriptor if the target is a method.

    Returns undefined | Record<string, any>

  • get nameLocalizations(): null | Partial<Record<
        | "id"
        | "en-US"
        | "en-GB"
        | "bg"
        | "zh-CN"
        | "zh-TW"
        | "hr"
        | "cs"
        | "da"
        | "nl"
        | "fi"
        | "fr"
        | "de"
        | "el"
        | "hi"
        | "hu"
        | "it"
        | "ja"
        | "ko"
        | "lt"
        | "no"
        | "pl"
        | "pt-BR"
        | "ro"
        | "ru"
        | "es-ES"
        | "es-419"
        | "sv-SE"
        | "th"
        | "tr"
        | "uk"
        | "vi", null | string>>
  • Returns null | Partial<Record<
        | "id"
        | "en-US"
        | "en-GB"
        | "bg"
        | "zh-CN"
        | "zh-TW"
        | "hr"
        | "cs"
        | "da"
        | "nl"
        | "fi"
        | "fr"
        | "de"
        | "el"
        | "hi"
        | "hu"
        | "it"
        | "ja"
        | "ko"
        | "lt"
        | "no"
        | "pl"
        | "pt-BR"
        | "ro"
        | "ru"
        | "es-ES"
        | "es-419"
        | "sv-SE"
        | "th"
        | "tr"
        | "uk"
        | "vi", null | string>>

  • set nameLocalizations(value): void
  • Parameters

    • value: null | Partial<Record<
          | "id"
          | "en-US"
          | "en-GB"
          | "bg"
          | "zh-CN"
          | "zh-TW"
          | "hr"
          | "cs"
          | "da"
          | "nl"
          | "fi"
          | "fr"
          | "de"
          | "el"
          | "hi"
          | "hu"
          | "it"
          | "ja"
          | "ko"
          | "lt"
          | "no"
          | "pl"
          | "pt-BR"
          | "ro"
          | "ru"
          | "es-ES"
          | "es-419"
          | "sv-SE"
          | "th"
          | "tr"
          | "uk"
          | "vi", null | string>>

    Returns void

Methods

  • Applies the decoration to the specified target.

    Parameters

    • classRef: Record<string, any>

      The class reference.

    • key: string

      The property key.

    • Optionalmethod: Record<string, any>

      The method descriptor.

    • Optionalfrom: Record<string, any>

      The originating class reference.

    • Optionalindex: number

      The parameter index.

    Returns this

    The current instance.

  • Decorates an unknown type (class, method, or property).

    Parameters

    • classRef: Record<string, any>

      The class reference.

    • Optionalkey: string

      The property key.

    • Optionalmethod: PropertyDescriptor

      The method descriptor.

    • Optionalindex: number

      The parameter index.

    Returns this

    The current instance.