类 AbstractCommand
- java.lang.Object
-
- cn.mcres.karlatemp.mxlib.shared.AbstractCommand
-
- 直接已知子类:
SharedCommandMethodHandle
,SharedCommands
public abstract class AbstractCommand extends Object implements ICommand
-
-
字段概要
字段 修饰符和类型 字段 说明 protected String
name
protected ICommands
parent
protected String
perm
protected IExceptionProcessor
processor
-
从接口继承的字段 cn.mcres.karlatemp.mxlib.cmd.ICommand
COMMAND_NOT_FOUND
-
-
构造器概要
构造器 构造器 说明 AbstractCommand(String name)
-
方法概要
修饰符和类型 方法 说明 boolean
checkPermission(ICommandSender sender)
String
getName()
ICommands
getParent()
String
getPermission()
IExceptionProcessor
getProcessor()
获取执行错误处理器,当前没有执行处理器时拿上级处理器, 依次递归, 直到获取一个处理器/无法获取处理器ICommand
setParent(ICommands parent)
已过时。ICommand
setPermission(String permission)
ICommand
setProcessor(IExceptionProcessor processor)
设置当前处理器-
从类继承的方法 java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
从接口继承的方法 cn.mcres.karlatemp.mxlib.cmd.IExecutor
command, command, command, tabComplete, tabComplete
-
-
-
-
字段详细资料
-
name
protected final String name
-
parent
protected ICommands parent
-
perm
protected String perm
-
processor
protected IExceptionProcessor processor
-
-
构造器详细资料
-
AbstractCommand
public AbstractCommand(@NotNull String name)
-
-
方法详细资料
-
getPermission
@Nullable public String getPermission()
- 指定者:
getPermission
在接口中ICommand
-
setPermission
@Nullable public ICommand setPermission(String permission)
- 指定者:
setPermission
在接口中ICommand
-
setParent
@NotNull @Deprecated public ICommand setParent(@NotNull ICommands parent)
已过时。从接口复制的说明:ICommand
-
checkPermission
public boolean checkPermission(@NotNull ICommandSender sender)
- 指定者:
checkPermission
在接口中ICommand
-
getProcessor
@Nullable public IExceptionProcessor getProcessor()
从接口复制的说明:ICommand
获取执行错误处理器,当前没有执行处理器时拿上级处理器, 依次递归, 直到获取一个处理器/无法获取处理器- 指定者:
getProcessor
在接口中ICommand
-
setProcessor
public ICommand setProcessor(@Nullable IExceptionProcessor processor)
从接口复制的说明:ICommand
设置当前处理器- 指定者:
setProcessor
在接口中ICommand
-
-