NWDSCIStringsMatch(3nw)


NWDSCIStringsMatch -- tests two case ignore strings (defined by CI_String_T) to determine if the two strings are equivalent

Synopsis

   #include <nwnet.h> 
   or 
   #include <nwdsname.h> 
   

NWDSCCODE N_API NWDSCIStringsMatch (NWDSContextHandle context, pnstr8 string1, pnstr8 string2, pnint matches;)

Description

The parameters are as follows:

context
(IN) Specifies the Directory Services context to be used. It is created by calling NWDSCreateContext or NWDSCreateContextHandle.

string1
(IN) Points to the first string to compare.

string2
(IN) Points to the second string to compare.

matches
(OUT) Points to a boolean indicating whether the strings match: 0 = Don't match; 1 = Match.

Return values

0x0000
SUCCESSFUL

0xFFFFFE0D
UNI_NO_DEAFAULT

0xFFFFFE0F
UNI_HANDLE_MISMATCH

0xFFFFFE10
UNI_HANDLE_BAD

0xFFFFFED1
ERR_BAD_CONTEXT

0xFFFFFED3
ERR_NOT_ENOUGH_MEMORY

Notices

Case Ignore String is a syntax used by some of the attributes (such as CN, Description, Directory, Services flags, and Title) for Directory objects.

Depending on the context, NWDSCIStringsMatch compares two Unicode strings in the local or Unicode code page. Thsi function ignores leading and trailing white space, which is either `` '' (space, 0x0020) or ``_'' (underscore, 0x005F). Also, it matches any consecutive internal white space, regardless of quantities. For example, if the string has a single internal white space character and another has five, NWDSCIStringsMatch matches the strings. Finally, NWDSCIStringsMatch ignores case in comparisons.

NWDSCIStringsMatch is a local function.

Services

Directory

NCP calls

None


30 January 1998
© 1998 The Santa Cruz Operation, Inc. All rights reserved.