Beispiel #1
0
 public void setAsExecutor(Command cmd) {
   cmd.setDescription(annot.desc());
   cmd.setUsage(annot.usage());
   cmd.setPermission(annot.permission());
   cmd.setAliases(new ArrayList<String>(Arrays.asList(annot.alias())));
   if (cmd instanceof PluginCommand) {
     PluginCommand pcmd = ((PluginCommand) cmd);
     pcmd.setExecutor(this);
     pcmd.setTabCompleter(this);
   }
 }
Beispiel #2
0
 public void setPermissions(String[] permissions) {
   this.permissions = permissions;
   if (permissions != null) {
     super.setPermission(StringUtils.join(permissions, ";"));
   }
 }