From 56e752193bfb90d11cfe73c35a24e576b9b18c87 Mon Sep 17 00:00:00 2001
From: Jean-Noel Rouvignac <jean-noel.rouvignac@forgerock.com>
Date: Wed, 03 Jul 2013 11:03:06 +0000
Subject: [PATCH] First stab at having debuggable ACIs.
---
opends/src/server/org/opends/server/authorization/dseecompat/SSF.java | 27 ++++++++++++++++++++-------
1 files changed, 20 insertions(+), 7 deletions(-)
diff --git a/opends/src/server/org/opends/server/authorization/dseecompat/SSF.java b/opends/src/server/org/opends/server/authorization/dseecompat/SSF.java
index c437b15..ce4f876 100644
--- a/opends/src/server/org/opends/server/authorization/dseecompat/SSF.java
+++ b/opends/src/server/org/opends/server/authorization/dseecompat/SSF.java
@@ -23,8 +23,8 @@
*
*
* Copyright 2008 Sun Microsystems, Inc.
+ * Portions Copyright 2013 ForgeRock AS
*/
-
package org.opends.server.authorization.dseecompat;
import org.opends.messages.Message;
@@ -33,13 +33,10 @@
/**
* The class represents the ssf keyword in a bind rule.SSF stands for
* security strength factor.
- *
*/
public class SSF implements KeywordBindRule {
- /*
- * Enumeration representing the bind rule operation type.
- */
+ /** Enumeration representing the bind rule operation type. */
private EnumBindRuleType type=null;
private static final int MAX_KEY_BITS=1024;
@@ -58,8 +55,7 @@
* @return A SSF instance.
* @throws AciException If the SSF instance cannot be created.
*/
- static SSF
- decode(String expr, EnumBindRuleType type) throws AciException {
+ static SSF decode(String expr, EnumBindRuleType type) throws AciException {
int valueAsInt = 0;
try {
valueAsInt = Integer.parseInt(expr);
@@ -113,4 +109,21 @@
}
return matched.getRet(type, false);
}
+
+ /** {@inheritDoc} */
+ @Override
+ public String toString()
+ {
+ final StringBuilder sb = new StringBuilder();
+ toString(sb);
+ return sb.toString();
+ }
+
+ /** {@inheritDoc} */
+ @Override
+ public final void toString(StringBuilder buffer)
+ {
+ buffer.append(super.toString());
+ }
+
}
\ No newline at end of file
--
Gitblit v1.10.0