|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.objectweb.jac.aspects.user.Rule
Rules for profiles : allow/deny reading, allow/deny writing, etc ...
Profile
,
UserAC
Field Summary | |
static boolean |
ALLOW
|
static boolean |
DENY
|
Constructor Summary | |
Rule(boolean allow,
String resourceExpression)
|
Method Summary | |
boolean |
getAllow()
Get rule mode (allow or deny). |
protected gnu.regexp.RE |
getRegexp()
Returns a regular expression object for the resource expression. |
String |
getResourceExpression()
|
protected void |
invalidateCache()
Invalidates the UserAC.controlAttribute's cache. |
boolean |
match(MetaItem item)
Tells if a MetaItem matches the rule. |
void |
setAllow(boolean allow)
Set rule mode (allow or deny). |
void |
setResourceExpression(String resourceExpression)
Set regular expression indicating which fields to apply rule for. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final boolean ALLOW
public static final boolean DENY
Constructor Detail |
public Rule(boolean allow, String resourceExpression)
allow
- if true
: allowing rule, if
false
: denying ruleresourceExpression
- regular expression indicating which
fields or methods this rule aplies to.Method Detail |
public boolean getAllow()
public void setAllow(boolean allow)
allow
- mode (true
for allow,
false
for deny).public void setResourceExpression(String resourceExpression)
resourceExpression
- the regular expression.public String getResourceExpression()
protected gnu.regexp.RE getRegexp()
public boolean match(MetaItem item)
MetaItem
matches the rule.
item
- the MetaItemprotected void invalidateCache()
It merely calls invalidateCache() on UserAC.
UserAC.controlAttribute(Object,MetaItem,String,Object)
,
UserAC.invalidateCache()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |