⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 authconstraint.java

📁 用于JAVA的Web的权限过滤器
💻 JAVA
字号:
package dev.trade.common.securityfilter.config;

import java.util.*;

/**
 * <p>Title: 权限过滤器</p>
 *
 * <p>Description: 验证配置</p>
 *
 * <p>Copyright: Copyright (c) 2006</p>
 *
 * <p>Company: </p>
 *
 * @author Zheng YanNan
 * @version 1.0
 */
public class AuthConstraint {
   private Set roles;

   /**
    * Constructor
    */
   public AuthConstraint() {
      roles = new HashSet();
   }

   /**
    * Add a role.
    *
    * @param role role to add
    */
   public void addRole(String role) {
      roles.add(role);
   }

   /**
    * Get the roles collection.
    * Returns an empty collection if no roles were present in the config file.
    */
   public Collection getRoles() {
      return Collections.unmodifiableCollection(roles);
   }
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -