LDAPsortkey structures from a string representation of a set of sort keys.
#include <ldap.h>
int ldap_create_sort_keylist(LDAPsortkey ***sortKeyList,
char *string_rep);
sortKeyList |
Pointer to an array of |
string_rep |
LDAP_SUCCESS if successful. LDAP_PARAM_ERROR if an invalid parameter was passed to the function. LDAP_NO_MEMORY if memory cannot be allocated. ldap_create_sort_keylist() function allows you to create an array of LDAPsortkey structures from a string representation of a set of sort keys. Calling this function creates an array of LDAPsortkey structures that you can pass to the ldap_create_sort_control() function.
The string representation specified by the string_rep argument should specify the name of the attribute that you want to sort by.
cn (sort by the cn attribute) -cn (sort by the cn attribute in reverse order) -cn:1.2.3.4 (sort by the cn attribute in reverse order and use the matching rule identified by the OID 1.2.3.4) LDAPsortkey structures by calling the ldap_free_sort_keylist() function.
ldap_create_sort_control(), ldap_free_sort_keylist().
Last Updated: 10/01/98 17:06:23