AutocompleteContext class Null safety

Represents a context in which an autocomplete event was triggered.

Implemented types

Constructors

AutocompleteContext({required CommandsPlugin commands, required IGuild? guild, required ITextChannel channel, required IMember? member, required IUser user, required ChatCommand command, required INyxx client, required ISlashCommandInteraction interaction, required IAutocompleteInteractionEvent interactionEvent, required IInteractionOption option, required String currentValue})
Create a new AutocompleteContext.

Properties

arguments Map<String, String?>
A map containing the arguments of command and their value, if the user has inputted a value for them.
late, final
channel ITextChannel
The channel in which the context was created.
final
client INyxx
The client that emitted the event triggering this context's creation.
final
command ChatCommand
The command that was executed or is being processed.
final
commands CommandsPlugin
The instance of CommandsPlugin which created this context.
final
currentValue String
The value the user has put in option so far.
final
existingArguments Map<String, String>
A map containing the arguments and the values that the user has inputted so far.
late, final
guild IGuild?
The guild in which the context was created, or null if created outside of a guild.
final
hashCode int
The hash code for this object.
read-only, inherited
interaction ISlashCommandInteraction
The interaction that triggered this context's creation.
final
interactionEvent IAutocompleteInteractionEvent
The interaction event that triggered this context's creation.
final
member IMember?
The member that triggered this context's created, or null if created outside of a guild.
final
option IInteractionOption
The option that the user is currently filling in.
final
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited
user IUser
The user that triggered this context's creation.
final

Methods

hasArgument(String name) bool
Whether the user has inputted a value for an argument with the name name.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited