Skip to main content

Class: PluginPatternCommandsMessageParseListener

@sapphire/plugin-pattern-commands.PluginPatternCommandsMessageParseListener

Hierarchy

  • Listener<typeof Events.PreMessageParsed>

    PluginPatternCommandsMessageParseListener

Constructors

constructor

new PluginPatternCommandsMessageParseListener(context): PluginPatternCommandsMessageParseListener

Parameters

NameType
contextLoaderContext

Returns

PluginPatternCommandsMessageParseListener

Overrides

Listener&lt;typeof Events.PreMessageParsed&gt;.constructor

Defined in

projects/plugins/packages/pattern-commands/src/listeners/PluginMessageParse.ts:10

Properties

emitter

Readonly emitter: null | __module

The emitter, if any.

Since

2.0.0

Inherited from

Listener.emitter

Defined in

node_modules/@sapphire/framework/dist/esm/index.d.mts:2462


enabled

enabled: boolean

Whether or not the piece is enabled.

Inherited from

Listener.enabled

Defined in

node_modules/@sapphire/pieces/dist/esm/index.d.mts:234


event

Readonly event: string | symbol

The name of the event the listener listens to.

Since

2.0.0

Inherited from

Listener.event

Defined in

node_modules/@sapphire/framework/dist/esm/index.d.mts:2467


location

Readonly location: PieceLocation

The location metadata for the piece's file.

Inherited from

Listener.location

Defined in

node_modules/@sapphire/pieces/dist/esm/index.d.mts:226


name

Readonly name: string

The name of the piece.

Inherited from

Listener.name

Defined in

node_modules/@sapphire/pieces/dist/esm/index.d.mts:230


once

Readonly once: boolean

Whether the listener will be unloaded after the first run.

Since

2.0.0

Inherited from

Listener.once

Defined in

node_modules/@sapphire/framework/dist/esm/index.d.mts:2472


options

Readonly options: ListenerOptions

The raw options passed to this Piece

Inherited from

Listener.options

Defined in

node_modules/@sapphire/pieces/dist/esm/index.d.mts:238


requiredPermissions

Private Readonly requiredPermissions: Readonly<BitField<"CreateInstantInvite" | "KickMembers" | "BanMembers" | "Administrator" | "ManageChannels" | "ManageGuild" | "AddReactions" | "ViewAuditLog" | "PrioritySpeaker" | "Stream" | "ViewChannel" | "SendMessages" | "SendTTSMessages" | "ManageMessages" | "EmbedLinks" | "AttachFiles" | "ReadMessageHistory" | "MentionEveryone" | "UseExternalEmojis" | "ViewGuildInsights" | "Connect" | "Speak" | "MuteMembers" | "DeafenMembers" | "MoveMembers" | "UseVAD" | "ChangeNickname" | "ManageNicknames" | "ManageRoles" | "ManageWebhooks" | "ManageEmojisAndStickers" | "ManageGuildExpressions" | "UseApplicationCommands" | "RequestToSpeak" | "ManageEvents" | "ManageThreads" | "CreatePublicThreads" | "CreatePrivateThreads" | "UseExternalStickers" | "SendMessagesInThreads" | "UseEmbeddedActivities" | "ModerateMembers" | "ViewCreatorMonetizationAnalytics" | "UseSoundboard" | "UseExternalSounds" | "SendVoiceMessages", bigint>>

Defined in

projects/plugins/packages/pattern-commands/src/listeners/PluginMessageParse.ts:9


store

Readonly store: ListenerStore

The store that contains the piece.

Inherited from

Listener.store

Defined in

node_modules/@sapphire/pieces/dist/esm/index.d.mts:222

Accessors

container

get container(): Container

A reference to the Container object for ease of use.

Returns

Container

See

container

Inherited from

Listener.container

Defined in

node_modules/@sapphire/pieces/dist/esm/index.d.mts:244

Methods

canRunInChannel

canRunInChannel(message): Promise<boolean>

Parameters

NameType
messageMessage<boolean>

Returns

Promise<boolean>

Defined in

projects/plugins/packages/pattern-commands/src/listeners/PluginMessageParse.ts:88


onLoad

onLoad(): unknown

Per-piece listener that is called when the piece is loaded into the store. Useful to set-up asynchronous initialization tasks.

Returns

unknown

Inherited from

Listener.onLoad

Defined in

node_modules/@sapphire/pieces/dist/esm/index.d.mts:249


onUnload

onUnload(): unknown

Per-piece listener that is called when the piece is unloaded from the store. Useful to set-up clean-up tasks.

Returns

unknown

Inherited from

Listener.onUnload

Defined in

node_modules/@sapphire/pieces/dist/esm/index.d.mts:254


reload

reload(): Promise<void>

Reloads the piece by loading the same path in the store.

Returns

Promise<void>

Inherited from

Listener.reload

Defined in

node_modules/@sapphire/pieces/dist/esm/index.d.mts:262


run

run(message): Promise<void>

Parameters

NameType
messageMessage<boolean>

Returns

Promise<void>

Overrides

Listener.run

Defined in

projects/plugins/packages/pattern-commands/src/listeners/PluginMessageParse.ts:14


toJSON

toJSON(): ListenerJSON

Returns

ListenerJSON

Inherited from

Listener.toJSON

Defined in

node_modules/@sapphire/framework/dist/esm/index.d.mts:2476


unload

unload(): Promise<void>

Unloads and disables the piece.

Returns

Promise<void>

Inherited from

Listener.unload

Defined in

node_modules/@sapphire/pieces/dist/esm/index.d.mts:258