From 172ae4c6e63be576376b32a68c8e8218f202fa22 Mon Sep 17 00:00:00 2001
From: neil_a_wilson <neil_a_wilson@localhost>
Date: Fri, 27 Apr 2007 20:43:17 +0000
Subject: [PATCH] Add initial support for server-side sorting in OpenDS. This implementation will only work for indexed searches, and it operates by sorting the ID list before iterating through the entries to return them to the client.
---
opends/src/server/org/opends/server/messages/CoreMessages.java | 73 ++++++++++++++++++++++++++++++++++++
1 files changed, 73 insertions(+), 0 deletions(-)
diff --git a/opends/src/server/org/opends/server/messages/CoreMessages.java b/opends/src/server/org/opends/server/messages/CoreMessages.java
index f91a29c..e63864a 100644
--- a/opends/src/server/org/opends/server/messages/CoreMessages.java
+++ b/opends/src/server/org/opends/server/messages/CoreMessages.java
@@ -6041,6 +6041,57 @@
/**
+ * The message ID for the message that will be used if a sort key string
+ * has an invalid order indicator. This takes a single argument, which is the
+ * sort key string.
+ */
+ public static final int MSGID_SORTKEY_INVALID_ORDER_INDICATOR =
+ CATEGORY_MASK_CORE | SEVERITY_MASK_MILD_ERROR | 603;
+
+
+
+ /**
+ * The message ID for the message that will be used if a sort key string
+ * has an undefined attribute type. This takes two arguments, which are the
+ * sort key string and the name of the attribute type.
+ */
+ public static final int MSGID_SORTKEY_UNDEFINED_TYPE =
+ CATEGORY_MASK_CORE | SEVERITY_MASK_MILD_ERROR | 604;
+
+
+
+ /**
+ * The message ID for the message that will be used if a sort key string
+ * has an attribute type with no ordering matching rule. This takes two
+ * arguments, which are the sort key string and the name of the attribute
+ * type.
+ */
+ public static final int MSGID_SORTKEY_NO_ORDERING_RULE =
+ CATEGORY_MASK_CORE | SEVERITY_MASK_MILD_ERROR | 605;
+
+
+
+ /**
+ * The message ID for the message that will be used if a sort key string
+ * has an undefined ordering rule. This takes two arguments, which are the
+ * sort key string and the name of the ordering rule.
+ */
+ public static final int MSGID_SORTKEY_UNDEFINED_ORDERING_RULE =
+ CATEGORY_MASK_CORE | SEVERITY_MASK_MILD_ERROR | 606;
+
+
+
+ /**
+ * The message ID for the message that will be used if a sort order string
+ * does not include any sort keys. This takes a single argument, which is the
+ * sort order string.
+ */
+ public static final int MSGID_SORTORDER_DECODE_NO_KEYS =
+ CATEGORY_MASK_CORE | SEVERITY_MASK_MILD_ERROR | 607;
+
+
+
+ /**
* Associates a set of generic messages with the message IDs defined
* in this class.
*/
@@ -8219,6 +8270,28 @@
registerMessage(MSGID_PROXYAUTH_INSUFFICIENT_PRIVILEGES,
"You do not have sufficient privileges to use the " +
"proxied authorization control");
+
+
+ registerMessage(MSGID_SORTKEY_INVALID_ORDER_INDICATOR,
+ "The provided sort key value %s is invalid because it " +
+ "does not start with either '+' (to indicate sorting in " +
+ "ascending order) or '-' (to indicate sorting in " +
+ "descending order)");
+ registerMessage(MSGID_SORTKEY_UNDEFINED_TYPE,
+ "The provided sort key value %s is invalid because it " +
+ "references undefined attribute type %s");
+ registerMessage(MSGID_SORTKEY_NO_ORDERING_RULE,
+ "The provided sort key value %s is invalid because " +
+ "attribute type %s does not have a default ordering " +
+ "matching rule and no specific rule was provided");
+ registerMessage(MSGID_SORTKEY_UNDEFINED_ORDERING_RULE,
+ "The provided sort key value %s is invalid because " +
+ "it references undefined ordering matching rule %s");
+
+
+ registerMessage(MSGID_SORTORDER_DECODE_NO_KEYS,
+ "The provided sort order string \"%s\" is invalid " +
+ "because it does not contain any sort keys");
}
}
--
Gitblit v1.10.0