Skip to main content

Class: InteractionHandler<O>

Type parameters

NameType
Oextends Options = Options

Hierarchy

  • Piece<O>

    InteractionHandler

Constructors

constructor

new InteractionHandler<O>(context, options)

Type parameters

NameType
Oextends InteractionHandlerOptions<O> = InteractionHandlerOptions

Parameters

NameType
contextPieceContext
optionsInteractionHandlerOptions

Overrides

Piece.constructor

Defined in

projects/framework/src/lib/structures/InteractionHandler.ts:13

Properties

enabled

enabled: boolean

Inherited from

Piece.enabled

Defined in

node_modules/@sapphire/pieces/dist/index.d.ts:450


interactionHandlerType

Readonly interactionHandlerType: InteractionHandlerTypes

Defined in

projects/framework/src/lib/structures/InteractionHandler.ts:11


location

Readonly location: PieceLocation

Inherited from

Piece.location

Defined in

node_modules/@sapphire/pieces/dist/index.d.ts:442


name

Readonly name: string

Inherited from

Piece.name

Defined in

node_modules/@sapphire/pieces/dist/index.d.ts:446


options

Readonly options: O

Inherited from

Piece.options

Defined in

node_modules/@sapphire/pieces/dist/index.d.ts:454


store

Readonly store: Store<Piece<PieceOptions>>

Inherited from

Piece.store

Defined in

node_modules/@sapphire/pieces/dist/index.d.ts:438

Accessors

container

get container(): Container

Returns

Container

Inherited from

Piece.container

Defined in

node_modules/@sapphire/pieces/dist/index.d.ts:460

Methods

none

none(): None

Returns

None

Defined in

projects/framework/src/lib/structures/InteractionHandler.ts:74


onLoad

onLoad(): unknown

Returns

unknown

Inherited from

Piece.onLoad

Defined in

node_modules/@sapphire/pieces/dist/index.d.ts:465


onUnload

onUnload(): unknown

Returns

unknown

Inherited from

Piece.onUnload

Defined in

node_modules/@sapphire/pieces/dist/index.d.ts:470


parse

parse(_interaction): Awaitable<Option<unknown>>

Parameters

NameType
_interactionInteraction<CacheType>

Returns

Awaitable<Option<unknown>>

Defined in

projects/framework/src/lib/structures/InteractionHandler.ts:64


reload

reload(): Promise<void>

Returns

Promise<void>

Inherited from

Piece.reload

Defined in

node_modules/@sapphire/pieces/dist/index.d.ts:478


run

Abstract run(interaction, parsedData?): unknown

Parameters

NameType
interactionInteraction<CacheType>
parsedData?unknown

Returns

unknown

Defined in

projects/framework/src/lib/structures/InteractionHandler.ts:19


some

some(): Some<never>

Returns

Some<never>

Defined in

projects/framework/src/lib/structures/InteractionHandler.ts:68

some<T>(data): Some<T>

Type parameters

Name
T

Parameters

NameType
dataT

Returns

Some<T>

Defined in

projects/framework/src/lib/structures/InteractionHandler.ts:69


toJSON

toJSON(): InteractionHandlerJSON

Returns

InteractionHandlerJSON

Overrides

Piece.toJSON

Defined in

projects/framework/src/lib/structures/InteractionHandler.ts:78


unload

unload(): Promise<void>

Returns

Promise<void>

Inherited from

Piece.unload

Defined in

node_modules/@sapphire/pieces/dist/index.d.ts:474