示例#1
0
文件: Cmd.java 项目: Rojoss/Boxx
 /**
  * Get a list with all the registered links.
  *
  * <p>If this command is a sub command this will include all the links from the parent.
  *
  * @return List with registered links.
  */
 public List<Link> getAllLinks() {
   if (isBase()) {
     return new ArrayList<>(links);
   }
   List<Link> links = new ArrayList<>(getBaseCmd().getLinks());
   links.addAll(this.links);
   return links;
 }
示例#2
0
文件: Cmd.java 项目: Rojoss/Boxx
 /**
  * Add one or more {@link SenderType}s on the sender blacklist.
  *
  * <p>The added sender types won't be able to execute the command.
  *
  * @param type One or more {@link SenderType}s to be blacklisted.
  */
 public void blacklistSenders(SenderType... type) {
   senderBlacklist.addAll(Arrays.asList(type));
 }