Package org.javacord.api.interaction
Interface SlashCommandPermissions
-
public interface SlashCommandPermissions
-
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description static SlashCommandPermissionscreate(long id, SlashCommandPermissionType type, boolean permission)Creates an slash command permissions which can be used bySlashCommandPermissionsUpdaterto update the permission.longgetId()Gets the ID of the affectedSlashCommandPermissionType.booleangetPermission()Whether this permission is enabled or disabled for the this slash command permissions.SlashCommandPermissionTypegetType()
-
-
-
Method Detail
-
getId
long getId()
Gets the ID of the affectedSlashCommandPermissionType.- Returns:
- The ID..
-
getType
SlashCommandPermissionType getType()
- Returns:
- The type of this slash command permissions.
-
getPermission
boolean getPermission()
Whether this permission is enabled or disabled for the this slash command permissions.- Returns:
- True if the command is enabled for this user or role. Otherwise false.
-
create
static SlashCommandPermissions create(long id, SlashCommandPermissionType type, boolean permission)
Creates an slash command permissions which can be used bySlashCommandPermissionsUpdaterto update the permission.- Parameters:
id- The id of the role or user which should be updated.type- The type this ID belong to.permission- True if the command should be enabled.- Returns:
- The built SlashCommandPermissions.
-
-