ldap_compare_ext (Windows Embedded CE 6.0)
1/6/2010
This function determines whether an attribute for a given entry holds a known value.
Syntax
ULONG ldap_compare_ext(
LDAP* ld,
UNICODE PTCHAR dn,
UNICODE PTCHAR Attr,
UNICODE PTCHAR Value,
struct berval* Data,
LDAPControl** ServerControls,
LDAPControl** ClientControls,
ULONG* MessageNumber
);
Parameters
- ld
[in] Session handle.
- dn
[in] Distinguished name of the entry to compare.
- Attr
[in] Attribute to compare.
- Value
[in] String attribute value to be compared to the attribute value.
- Data
[in] The berval attribute value to be compared to the attribute value.
- ServerControls
[in] List of LDAP server controls.
- ClientControls
[in] List of client controls.
- MessageNumber
[out] Message identifier for the compare operation.
Return Value
If this function succeeds, the return value is LDAP_SUCCESS.
If this function fails, it returns an error code. See the LDAP_RETCODE enumeration for a list of possible return values.
Remarks
This function initiates an asynchronous compare operation, comparing the value of an attribute to a known value. The parameters and effects of this function include those of the ldap_compare function. The extended routine includes additional parameters to support client and server controls, comparison of binary values, and thread safety.
Use the Value parameter for comparing string values or use the Data parameter for comparing raw binary data. Set the unused parameter to NULL. If neither parameter is NULL, the compare operation will use the value in the Data parameter.
If successful, ldap_compare_ext passes back the message identifier for the operation in the MessageNumber parameter. Call the ldap_result function with the message identifier to obtain the result of the comparison. If you prefer to have the function return the compare result directly, use the synchronous extended compare function ldap_compare_ext_s.
In a multithreading environment, calls to ldap_compare_ext are thread-safe.
Requirements
Header | winldap.h |
Library | wldap32.lib |
Windows Embedded CE | Windows CE .NET 4.0 and later |
See Also
Reference
LDAP Directory Entry Functions
LDAP_RETCODE
berval
ldap_compare
ldap_compare_ext_s
ldap_result