NWDSGetServerName(3nw)


NWDSGetServerName -- returns the name of the current server, as well as the number of partitions on the server, from a result buffer

Synopsis

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

NWDSCCODE N_API NWDSGetServerName (NWDSContextHandle context, pBuf_T buf, pnstr8 serverName, pnuint32 partitionCount);

Description

The parameters are as follows:

context
(IN) Specifies the Directory context for the request.

buf
(IN) Points to the result buffer being read.

serverName
(OUT) Points to the server name.

partitionCount
(OUT) Points to the number of partition names in the result buffer.

Return values

0x0000
SUCCESSFUL

Negative Value
Negative values indicate errors. For errors returned by Directory Services, see ``Directory Services OS Errors'' (-001 to -255), ``Directory Services Client Library Errors'' (-301 to -399), or ``Directory Services Agent in the Server Errors'' (-601 to -699).

Notices

NWDSGetServerName should be called first to read from a result buffer returned by NWDSListPartitions.

buf points to a Buf_T filled by NWDSListPartitions.

serverName points to a memory location containing the distinguished name of the server for which replica information has been found. You must allocate space for the server name. The size of the allocated memory is ((MAX_DN_CHARS)+1*)sizeof(character size) where character size is 1 for single-byte characters, and 2 for double-byte characters (Unicode is double-byte). One character is used for NULL termination.

The complete steps for retrieving partition information are listed in the reference for NWDSListPartitions.

Services

Directory

NCP calls

None

References

NWDSGetPartitionInfo(3nw), NWDSListPartitions(3nw)
30 January 1998
© 1998 The Santa Cruz Operation, Inc. All rights reserved.