コード例 #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));
 }