Class CommandAttribute code
- 程序集
- Another-Mirai-Native.Abstractions.dll
[AttributeUsage(AttributeTargets.Method, AllowMultiple = true)]
public class CommandAttribute : Attribute
- 继承
-
CommandAttribute
- 继承成员
构造函数
CommandAttribute(MatchMode, string, MessageScope) code
public CommandAttribute(MatchMode matchMode, string template, MessageScope scope = MessageScope.All)
参数
matchModeMatchMode指令的匹配模式。
templatestring用于匹配消息内容的模板字符串。
scopeMessageScope此指令响应的消息来源范围。默认为 All。
属性
MatchMode code
指令的匹配模式。
public MatchMode MatchMode { get; }
属性值
Scope code
此指令响应的消息来源范围。默认为 All。
public MessageScope Scope { get; set; }
属性值
Template code
public string Template { get; }