Class SlashCommandGroupAttribute
Marks this class a slash command group
Inheritance
Namespace: DisCatSharp.ApplicationCommands
Assembly: DisCatSharp.ApplicationCommands.dll
Syntax
[AttributeUsage(AttributeTargets.Class)]
public class SlashCommandGroupAttribute : Attribute
Constructors
| Improve this Doc View SourceSlashCommandGroupAttribute(String, String, Boolean)
Marks this class as a slash command group
Declaration
public SlashCommandGroupAttribute(string name, string description, bool isNsfw = false)
Parameters
Type | Name | Description |
---|---|---|
System.String | name | The name of this slash command group. |
System.String | description | The description of this slash command group. |
System.Boolean | isNsfw | Whether this command is marked as NSFW. |
SlashCommandGroupAttribute(String, String, Boolean, Boolean)
Marks this method as a slash command group
Declaration
public SlashCommandGroupAttribute(string name, string description, bool dmPermission, bool isNsfw = false)
Parameters
Type | Name | Description |
---|---|---|
System.String | name | The name of this slash command. |
System.String | description | The description of this slash command. |
System.Boolean | dmPermission | The dm permission. |
System.Boolean | isNsfw | Whether this command is marked as NSFW. |
SlashCommandGroupAttribute(String, String, Int64, Boolean)
Marks this method as a slash command group
Declaration
public SlashCommandGroupAttribute(string name, string description, long defaultMemberPermissions, bool isNsfw = false)
Parameters
Type | Name | Description |
---|---|---|
System.String | name | The name of this slash command. |
System.String | description | The description of this slash command. |
System.Int64 | defaultMemberPermissions | The default member permissions. |
System.Boolean | isNsfw | Whether this command is marked as NSFW. |
SlashCommandGroupAttribute(String, String, Int64, Boolean, Boolean)
Marks this method as a slash command group
Declaration
public SlashCommandGroupAttribute(string name, string description, long defaultMemberPermissions, bool dmPermission, bool isNsfw = false)
Parameters
Type | Name | Description |
---|---|---|
System.String | name | The name of this slash command. |
System.String | description | The description of this slash command. |
System.Int64 | defaultMemberPermissions | The default member permissions. |
System.Boolean | dmPermission | The dm permission. |
System.Boolean | isNsfw | Whether this command is marked as NSFW. |
Properties
| Improve this Doc View SourceDefaultMemberPermissions
Gets the needed permission of this slash command group
Declaration
public Permissions? DefaultMemberPermissions { get; set; }
Property Value
Type | Description |
---|---|
System.Nullable<Permissions> |
Description
Gets the description of this slash command group
Declaration
public string Description { get; set; }
Property Value
Type | Description |
---|---|
System.String |
DmPermission
Gets the dm permission of this slash command group
Declaration
public bool? DmPermission { get; set; }
Property Value
Type | Description |
---|---|
System.Nullable<System.Boolean> |
IsNsfw
Gets whether this command is marked as NSFW
Declaration
public bool IsNsfw { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
Name
Gets the name of this slash command group
Declaration
public string Name { get; set; }
Property Value
Type | Description |
---|---|
System.String |