hoshii / Exports / ForumTopic

ForumTopic<T>

Represents a forum topic

Type parameters

NameType
Textends ForumChannel = ForumChannel

Hierarchy

  • Base<number>

    ForumTopic

Table of contents

Constructors

Properties

Accessors

Methods

Constructors

constructor

new ForumTopic<T>(data, client)

Create a new forum topic

Type parameters

NameType
Textends ForumChannel<T> = ForumChannel

Parameters

NameTypeDescription
dataRawForumTopicThe raw data of the forum topic
clientClientThe client

Overrides

Base.constructor

Defined in

lib/structures/ForumTopic.ts:146open in new window

Properties

_cachedChannel

Private Optional _cachedChannel: T extends TextChannel ? T : undefined

The cached channel the forum topic is in

Defined in

lib/structures/ForumTopic.ts:65open in new window


_cachedServer

Private Optional _cachedServer: T extends Server ? Server : Server

The cached server the forum topic is in

Defined in

lib/structures/ForumTopic.ts:70open in new window


bumpedAt

Optional bumpedAt: Date

The date the forum topic was last bumped

Defined in

lib/structures/ForumTopic.ts:75open in new window


channelID

channelID: string

The ID of the channel the forum topic is in

Defined in

lib/structures/ForumTopic.ts:80open in new window


client

client: Client

The bot client

Inherited from

Base.client

Defined in

lib/structures/Base.ts:13open in new window


comments

comments: TypedCollection<number, RawForumTopicComment, ForumTopicComment, []>

A collection of cached comments

Defined in

lib/structures/ForumTopic.ts:85open in new window


content

content: string

The content of the forum topic

Defined in

lib/structures/ForumTopic.ts:94open in new window


createdAt

createdAt: Date

The date the forum topic was created at

Defined in

lib/structures/ForumTopic.ts:99open in new window


createdBy

createdBy: string

The ID of the user who created the forum topic

Defined in

lib/structures/ForumTopic.ts:104open in new window


createdByWebhookID

Optional createdByWebhookID: string

The ID of the webhook that created the forum topic

Defined in

lib/structures/ForumTopic.ts:109open in new window


id

id: number

The ID of the item

Inherited from

Base.id

Defined in

lib/structures/Base.ts:16open in new window


isLocked

Optional isLocked: boolean

Whether the forum topic is locked

Defined in

lib/structures/ForumTopic.ts:114open in new window


isPinned

Optional isPinned: boolean

Whether the forum topic is pinned

Defined in

lib/structures/ForumTopic.ts:119open in new window


mentions

Optional mentions: Mentions

The mentions in the forum topic

Defined in

lib/structures/ForumTopic.ts:124open in new window


serverID

serverID: string

The ID of the server the forum topic is in

Defined in

lib/structures/ForumTopic.ts:129open in new window


title

title: string

The title of the forum topic

Defined in

lib/structures/ForumTopic.ts:134open in new window


updatedAt

Optional updatedAt: Date

The date the forum topic was last updated

Defined in

lib/structures/ForumTopic.ts:139open in new window

Accessors

channel

get channel(): T extends TextChannel ? T : undefined

The channel the forum topic is in

Returns

T extends TextChannel ? T : undefined

Defined in

lib/structures/ForumTopic.ts:173open in new window


server

get server(): T extends Server ? Server : Server

The server the forum topic is in

Returns

T extends Server ? Server : Server

Defined in

lib/structures/ForumTopic.ts:187open in new window

Methods

addReactionEmote

addReactionEmote(emoteID): Promise<void>

Add a reaction emote to the forum topic

Parameters

NameTypeDescription
emoteIDnumberThe ID of the emote

Returns

Promise<void>

Defined in

lib/structures/ForumTopic.ts:206open in new window


createComment

createComment(options): Promise<ForumTopicComment>

Create a forum comment in this thread

Parameters

NameTypeDescription
optionsForumTopicCommentOptionsThe options for the comment

Returns

Promise<ForumTopicComment>

Defined in

lib/structures/ForumTopic.ts:219open in new window


delete

delete(): Promise<void>

Delete the forum topic

Returns

Promise<void>

Defined in

lib/structures/ForumTopic.ts:233open in new window


deleteReactionEmote

deleteReactionEmote(emoteID): Promise<void>

Delete a reaction emote from the forum topic

Parameters

NameTypeDescription
emoteIDnumberThe ID of the emote

Returns

Promise<void>

Defined in

lib/structures/ForumTopic.ts:242open in new window


edit

edit<T>(options): Promise<ForumTopic<T>>

Edit the forum topic

Type parameters

NameType
Textends ForumChannel<T> = ForumChannel

Parameters

NameTypeDescription
optionsForumTopicOptionsThe options for the topic

Returns

Promise<ForumTopic<T>>

Defined in

lib/structures/ForumTopic.ts:255open in new window


lock

lock(): Promise<void>

Lock the forum topic

Returns

Promise<void>

Defined in

lib/structures/ForumTopic.ts:265open in new window


pin

pin(): Promise<void>

Pin the forum topic

Returns

Promise<void>

Defined in

lib/structures/ForumTopic.ts:273open in new window


toJSON

toJSON(): ForumTopicData

Returns the JSON representation of the item

Returns

ForumTopicData

Overrides

Base.toJSON

Defined in

lib/structures/ForumTopic.ts:277open in new window


unlock

unlock(): Promise<void>

Unlock the forum topic

Returns

Promise<void>

Defined in

lib/structures/ForumTopic.ts:300open in new window


unpin

unpin(): Promise<void>

Unpin the forum topic

Returns

Promise<void>

Defined in

lib/structures/ForumTopic.ts:308open in new window


update

Protected update(data): void

Parameters

NameType
dataRawForumTopic

Returns

void

Overrides

Base.update

Defined in

lib/structures/ForumTopic.ts:312open in new window

Last Updated:
Contributors: Reinhardt