From 5f9ccac52b25265d38c85c0d23be6f8f91dc74d6 Mon Sep 17 00:00:00 2001
From: Nicolas Capponi <nicolas.capponi@forgerock.com>
Date: Fri, 09 Sep 2016 09:45:26 +0000
Subject: [PATCH] OPENDJ-3089 Remove syntaxes, matching rules factories, associated tests
---
opendj-server-legacy/src/main/java/org/opends/server/util/SchemaUtils.java | 15 ++++++++++++++-
1 files changed, 14 insertions(+), 1 deletions(-)
diff --git a/opendj-server-legacy/src/main/java/org/opends/server/util/SchemaUtils.java b/opendj-server-legacy/src/main/java/org/opends/server/util/SchemaUtils.java
index 5b6c3f7..650808d 100644
--- a/opendj-server-legacy/src/main/java/org/opends/server/util/SchemaUtils.java
+++ b/opendj-server-legacy/src/main/java/org/opends/server/util/SchemaUtils.java
@@ -16,7 +16,6 @@
package org.opends.server.util;
import static org.opends.messages.SchemaMessages.*;
-
import static org.opends.server.util.ServerConstants.SCHEMA_PROPERTY_FILENAME;
import static org.opends.server.schema.SchemaConstants.SYNTAX_AUTH_PASSWORD_OID;
import static org.opends.server.schema.SchemaConstants.SYNTAX_USER_PASSWORD_OID;
@@ -28,6 +27,7 @@
import org.forgerock.i18n.LocalizableMessage;
import org.forgerock.i18n.LocalizableMessageDescriptor.Arg1;
+import org.forgerock.opendj.ldap.ByteString;
import org.forgerock.opendj.ldap.ResultCode;
import org.forgerock.opendj.ldap.schema.AttributeType;
import org.forgerock.opendj.ldap.schema.ObjectClass;
@@ -81,6 +81,19 @@
}
/**
+ * Retrieves an attribute value containing a representation of the provided
+ * boolean value.
+ *
+ * @param b The boolean value for which to retrieve the attribute value.
+ *
+ * @return The attribute value created from the provided boolean value.
+ */
+ public static ByteString createBooleanValue(boolean b)
+ {
+ return b ? ServerConstants.TRUE_VALUE : ServerConstants.FALSE_VALUE;
+ }
+
+ /**
* Retrieves the definition string used to create the provided schema element and including the
* X-SCHEMA-FILE extension.
*
--
Gitblit v1.10.0