Channel
Represents a channel
Hierarchy
Base
<string
>↳
Channel
Table of contents
Constructors
Properties
Methods
Constructors
constructor
• new Channel(data
, client
)
Create a new Channel
Parameters
Name | Type | Description |
---|---|---|
data | RawServerChannel | The raw data of the channel |
client | Client | The client |
Overrides
Defined in
Properties
client
• client: Client
The bot client
Inherited from
Defined in
id
• id: string
The ID of the item
Inherited from
Defined in
name
• name: string
The name of the channel
Defined in
type
• type: ServerChannelCategories
The type of the channel
Defined in
Methods
delete
▸ delete(): Promise
<void
>
Delete the channel
Returns
Promise
<void
>
Defined in
edit
▸ edit(options
): Promise
<Channel
>
Edit the channel
Parameters
Name | Type | Description |
---|---|---|
options | ServerChannelEditOptions | The options to edit the channel with |
Returns
Promise
<Channel
>
Defined in
toJSON
▸ toJSON(): ChannelData
Returns the JSON representation of the item
Returns
Overrides
Defined in
update
▸ Protected
update(data
): void
Parameters
Name | Type |
---|---|
data | unknown |
Returns
void
Inherited from
Defined in
from
▸ Static
from<T
>(data
, client
): T
Type parameters
Name | Type |
---|---|
T | extends AnyChannel = AnyChannel |
Parameters
Name | Type |
---|---|
data | RawServerChannel |
client | Client |
Returns
T