import Eris from 'eris'; import CommandsModule from '.'; import DexareClient from '../../client'; import { ClientEvent } from '../../client/events'; export default class CommandContext { /** The commands module. */ readonly cmdsModule: CommandsModule>; /** The event that created this context. */ readonly event: ClientEvent; /** The client from this context. */ readonly client: DexareClient; /** The message this context is reffering to. */ readonly message: Eris.Message; /** The channel that the message is in. */ readonly channel: Eris.TextableChannel | Eris.Uncached; /** The author of the message. */ readonly author: Eris.User; /** The prefix used for this context. */ readonly prefix: string; /** The arguments used in this context. */ readonly args: string[]; /** The guild the message is in. */ readonly guild?: Eris.Guild; /** The member that created the message. */ member?: Eris.Member; /** * @param creator The instantiating creator. * @param data The interaction data for the context. * @param respond The response function for the interaction. * @param webserverMode Whether the interaction was from a webserver. */ constructor(cmdsModule: CommandsModule, event: ClientEvent, args: string[], prefix: string, message: Eris.Message); /** Shorthand for `message.channel.createMessage`. */ send(content: Eris.MessageContent, file?: Eris.FileContent | Eris.FileContent[]): Promise>; /** Sends a message replying to the original message. */ reply(content: Eris.MessageContent, file?: Eris.FileContent | Eris.FileContent[]): Promise>; /** * Sends a message with the author's mention prepended to it. * Only prepends in guild channels. */ replyMention(content: Eris.MessageContent, file?: Eris.FileContent | Eris.FileContent[]): Promise>; /** * Fetches the member for this message and assigns it. */ fetchMember(): Promise; /** * Start typing in the channel the context is in. */ startTyping(): Promise; /** * Stop typing in the channel the context is in. */ stopTyping(): void; }