Class UserAttr
- java.lang.Object
-
- org.opends.server.authorization.dseecompat.UserAttr
-
- All Implemented Interfaces:
KeywordBindRule
public final class UserAttr extends Object implements KeywordBindRule
This class implements the userattr bind rule keyword.TODO Evaluate making this class more efficient.
This class isn't as efficient as it could be. For example, the
evalVal(AciEvalContext)
method should be able to use cached versions of the attribute type and filter. TheevalUrl(AciEvalContext)
andevalDNKeywords(AciEvalContext)
methods should also be able to use a cached version of the attribute type.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static KeywordBindRule
decode(String expression, org.opends.server.authorization.dseecompat.EnumBindRuleType type, ServerContext serverContext)
Decode an string containing the userattr bind rule expression.EnumEvalResult
evaluate(AciEvalContext evalCtx)
Evaluate the expression using an evaluation context.String
toString()
void
toString(StringBuilder buffer)
Appends a string representation of this object to the provided buffer.
-
-
-
Method Detail
-
decode
public static KeywordBindRule decode(String expression, org.opends.server.authorization.dseecompat.EnumBindRuleType type, ServerContext serverContext) throws AciException
Decode an string containing the userattr bind rule expression.- Parameters:
expression
- The expression string.type
- The bind rule type.serverContext
- The server context- Returns:
- A class suitable for evaluating a userattr bind rule.
- Throws:
AciException
- If the string contains an invalid expression.
-
evaluate
public EnumEvalResult evaluate(AciEvalContext evalCtx)
Evaluate the expression using an evaluation context.- Specified by:
evaluate
in interfaceKeywordBindRule
- Parameters:
evalCtx
- The evaluation context to use in the evaluation of the userattr expression.- Returns:
- An enumeration containing the result of the evaluation.
-
toString
public void toString(StringBuilder buffer)
Description copied from interface:KeywordBindRule
Appends a string representation of this object to the provided buffer.- Specified by:
toString
in interfaceKeywordBindRule
- Parameters:
buffer
- The buffer into which a string representation of this object should be appended.
-
-