[jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/rules ...

Shane Bryzak Shane_Bryzak at symantec.com
Sun Dec 10 19:56:30 EST 2006


  User: sbryzak2
  Date: 06/12/10 19:56:30

  Added:       src/main/org/jboss/seam/security/rules  PermissionCheck.java
  Log:
  rule-based permission check
  
  Revision  Changes    Path
  1.1      date: 2006/12/11 00:56:30;  author: sbryzak2;  state: Exp;jboss-seam/src/main/org/jboss/seam/security/rules/PermissionCheck.java
  
  Index: PermissionCheck.java
  ===================================================================
  package org.jboss.seam.security.rules;
  
  /**
   * Used to assert permission requirements into a WorkingMemory when evaluating
   * a @Restrict expression.  The consequence of the rule is responsible for
   * granting the permission.
   *
   * @author Shane Bryzak
   */
  public class PermissionCheck
  {
    private String name;
    private String action;
    private boolean granted;
  
    public PermissionCheck(String name, String action)
    {
      this.name = name;
      this.action = action;
      this.granted = false;
    }
  
    public String getName()
    {
      return name;
    }
  
    public String getAction()
    {
      return action;
    }
  
    public void grant()
    {
      this.granted = true;
    }
  
    public boolean isGranted()
    {
      return granted;
    }
  }
  
  
  



More information about the jboss-cvs-commits mailing list