[seam-commits] Seam SVN: r7932 - trunk/src/main/org/jboss/seam/security/permission.
seam-commits at lists.jboss.org
seam-commits at lists.jboss.org
Mon Apr 14 00:16:30 EDT 2008
Author: shane.bryzak at jboss.com
Date: 2008-04-14 00:16:30 -0400 (Mon, 14 Apr 2008)
New Revision: 7932
Modified:
trunk/src/main/org/jboss/seam/security/permission/Permission.java
Log:
should be immutable
Modified: trunk/src/main/org/jboss/seam/security/permission/Permission.java
===================================================================
--- trunk/src/main/org/jboss/seam/security/permission/Permission.java 2008-04-14 04:13:40 UTC (rev 7931)
+++ trunk/src/main/org/jboss/seam/security/permission/Permission.java 2008-04-14 04:16:30 UTC (rev 7932)
@@ -4,7 +4,7 @@
import java.security.Principal;
/**
- * Base class for permissions
+ * Represents a single permission for a particular target, action and recipient combination.
*
* @author Shane Bryzak
*/
@@ -14,14 +14,16 @@
private String action;
private Principal recipient;
- public Object getTarget()
+ public Permission(Object target, String action, Principal recipient)
{
- return target;
+ this.target = target;
+ this.action = action;
+ this.recipient = recipient;
}
- public void setTarget(Object target)
+ public Object getTarget()
{
- this.target = target;
+ return target;
}
public String getAction()
@@ -29,18 +31,8 @@
return action;
}
- public void setAction(String action)
- {
- this.action = action;
- }
-
public Principal getRecipient()
{
return recipient;
}
-
- public void setRecipient(Principal recipient)
- {
- this.recipient = recipient;
- }
}
More information about the seam-commits
mailing list