Options
All
  • Public
  • Public/Protected
  • All
Menu

Class Embed

Utils Embed Structure

Hierarchy

Index

Constructors

constructor

  • Parameters

    Returns Embed

Properties

_keys

_keys: BaseSet<string> = keysEmbed

Optional author

author: EmbedAuthor

Optional color

color: undefined | number

Optional description

description: undefined | string

Optional fields

fields: BaseCollection<number, EmbedField>

Optional footer

footer: EmbedFooter

Optional image

image: EmbedImage

Optional provider

provider: EmbedProvider

Optional referenceId

referenceId: undefined | string

Optional thumbnail

thumbnail: EmbedThumbnail

Optional timestamp

timestamp: Date

Optional title

title: undefined | string

type

type: string = MessageEmbedTypes.RICH

Optional url

url: undefined | string

Optional video

video: EmbedVideo

Accessors

length

  • get length(): number
  • Returns number

size

  • get size(): number
  • Returns number

Methods

[inspect.custom]

  • [inspect.custom](): object

_getFromSnake

  • _getFromSnake(key: string): any
  • Parameters

    • key: string

    Returns any

_setFromSnake

  • _setFromSnake(key: string, value: any): any
  • Parameters

    • key: string
    • value: any

    Returns any

addField

  • addField(name: string, value: string, inline?: undefined | false | true): Embed
  • Parameters

    • name: string
    • value: string
    • Optional inline: undefined | false | true

    Returns Embed

difference

  • difference(key: string, value: any): [boolean, any]
  • Parameters

    • key: string
    • value: any

    Returns [boolean, any]

differences

merge

mergeValue

  • mergeValue(key: string, value: any): void
  • Parameters

    • key: string
    • value: any

    Returns void

setAuthor

  • setAuthor(name?: null | string, iconUrl?: null | string, url?: null | string): Embed
  • Parameters

    • Optional name: null | string
    • Optional iconUrl: null | string
    • Optional url: null | string

    Returns Embed

setColor

  • setColor(color: number): Embed
  • Parameters

    • color: number

    Returns Embed

setDescription

  • setDescription(description: null | string): Embed
  • Parameters

    • description: null | string

    Returns Embed

setFooter

  • setFooter(text: string, iconUrl?: null | string): Embed
  • Parameters

    • text: string
    • Optional iconUrl: null | string

    Returns Embed

setImage

  • setImage(url: string): Embed
  • Parameters

    • url: string

    Returns Embed

setThumbnail

  • setThumbnail(url: string): Embed
  • Parameters

    • url: string

    Returns Embed

setTimestamp

  • setTimestamp(timestamp?: Date | number | string): Embed
  • Parameters

    • Default value timestamp: Date | number | string = Date.now()

    Returns Embed

setTitle

  • setTitle(title: string): Embed
  • Parameters

    • title: string

    Returns Embed

setUrl

  • setUrl(url: string): Embed
  • Parameters

    • url: string

    Returns Embed

toJSON

Generated using TypeDoc