GuildApplicationCommandManager class Managers
An ApplicationCommandManager for the commands in a guild.
- Inheritance
-
- Object
- ReadOnlyManager<
ApplicationCommand> - Manager<
ApplicationCommand> - ApplicationCommandManager
- GuildApplicationCommandManager
Constructors
-
GuildApplicationCommandManager(CacheConfig<
ApplicationCommand> config, UhxxRest client, {required Snowflake applicationId, required Snowflake guildId, required CacheConfig<CommandPermissions> permissionsConfig}) - Create a new GuildApplicationCommandManager.
Properties
- applicationId → Snowflake
-
The ID of the application this manager is for.
finalinherited
-
cache
→ Cache<
ApplicationCommand> -
The cache for this manager.
finalinherited
- client → UhxxRest
-
The client this manager belongs to.
finalinherited
- guildId → Snowflake
-
The ID of the guild this manager is for.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
-
permissionsCache
→ Cache<
CommandPermissions> -
A cache for the command permissions in this guild.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
bulkOverride(
List< ApplicationCommandBuilder> builders) → Future<List< ApplicationCommand> > -
Remove all existing commands and replace them with the commands defined in
builders.inherited -
create(
covariant ApplicationCommandBuilder builder) → Future< ApplicationCommand> -
Create a new instance of the type of this manager.
inherited
-
delete(
Snowflake id) → Future< void> -
Delete the item with the given
idfrom the API.inherited -
fetch(
Snowflake id) → Future< ApplicationCommand> -
Fetch the item with the given
idfrom the API.inherited -
fetchPermissions(
Snowflake id) → Future< CommandPermissions> - Fetch the permissions for a command.
-
get(
Snowflake id) → Future< ApplicationCommand> -
Get an item by its
idfrom the cache if it exists, else fetch it from the API.inherited -
list(
{bool? withLocalizations}) → Future< List< ApplicationCommand> > -
List the commands belonging to the application.
inherited
-
listPermissions(
) → Future< List< CommandPermissions> > - List all the CommandPermissions in this guild.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
parse(
Map< String, Object?> raw) → ApplicationCommand -
Parse the
rawdata received from the API into an instance of the type of this manager.inherited -
parseApplicationCommandOption(
Map< String, Object?> raw) → CommandOption -
Parse a CommandOption from
raw.inherited -
parseCommandPermission(
Map< String, Object?> raw) → CommandPermission -
Parse a CommandPermission from
raw. -
parseCommandPermissions(
Map< String, Object?> raw) → CommandPermissions -
Parse a CommandPermissions from
raw. -
parseOptionChoice(
Map< String, Object?> raw) → CommandOptionChoice -
Parse a CommandOptionChoice from
raw.inherited -
toString(
) → String -
A string representation of this object.
inherited
-
update(
Snowflake id, covariant ApplicationCommandUpdateBuilder builder) → Future< ApplicationCommand> -
Update the item with the given
idin the API.inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
-
operator [](
Snowflake id) → PartialApplicationCommand -
Return a partial instance of the entity with ID
idcontaining no data.inherited