NWDSListContainableClasses(3nw)


NWDSListContainableClasses -- returns the names of the object classes that can be contained by (subordinate to) the specified object in the Directory tree

Synopsis

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

NWDSCCODE N_API NWDSListContainableClasses (NWDSContextHandle context, pnstr8 parentObject, pnint32 iterationHandle, pBuf_T containableClasses);

Description

The parameters are as follows:

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

parentObject
(IN) Points to the name of the parent object for which containable classes are to be listed.

iterationHandle
(IN/OUT) Points to the information needed to resume subsequent iterations of NWDSListContainableClasses.

containableClasses
(OUT) Points to a buffer containing the names of object classes contained by the specified parent object.

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).

0x8996
SERVER_OUT_OF_MEMORY

0x89E2
TOO_FEW_FRAGMENTS

0x89E3
TOO_MANY_FRAGMENTS

0x89E4
PROTOCOL_VIOLATION

0x89E5
SIZE_LIMIT_EXCEEDED

0x89FD
UNKNOWN_REQUEST

0x89FD
INVALID_PACKET_LENGTH

0x89FE
BAD_PACKET

0x89FF
Failure not related to Directory Services

Notices

NWDSListContainableClasses can be used to build a list of object classes that can be used to create objects subordinate to the parent object specified by parentObject.

parentObject points to the name of a Directory object for which containable object-classes are to be listed. If this parent object is not a valid container object, an error is returned.

iterationHandle controls retrieval of results larger than the buffer pointed to by containableClasses.

Before the initial call to NWDSListContainableClasses, set the contents of the iteration handle pointed to by iterationHandle to NO_MORE_ITERATIONS.

When NWDSListContainableClasses returns from its initial call, if the result buffer holds the complete results, the location pointed to by iterationHandle is set to NO_MORE_ITERATIONS. If iterationHandle is not set to NO_MORE_ITERATIONS, use the iteration handle for subsequent class to NWDSListContainableClasses in order to obtain further portions of the results. When the results are completely retrieved, the contents of the iteration handle will be set to NO_MORE_ITERATIONS.


NOTE:

To end the List operation before all of the results have been retrieved, call NWDSCloseIteration with a value of DSV_LIST_CONTAINABLE_CLASSES to free memory and states associated with NWDSListContainableClasses.


The level of granularity for partial results (those split across multiple iterations) is an individual class name.

containableClasses points to a result buffer that receives the list of names of object classes that can be used to create objects contained by the specified parent object. The result buffer contains the names of only the object classes marked as effective in the Directory Schema (those from which objects can be created). Alias is always included in the list.

The list of containable classes for an object can be determined using the following steps:

  1. Determine the parent object whose containable object-classes are to be returned.

  2. Allocate a result buffer by calling NWDSAllocBuf. (The buffer does not need to be initialized since it is a result buffer.)

  3. Retrieve the object classes the parent object can contain by calling NWDSListContainableClasses.

  4. Determine the number of object-class names contained in the buffer by calling NWDSGetClassItemCount.

  5. For each object class name in the result buffer, retrieve the name by calling NWDSGetClassItem.

  6. If the contents of the iteration handle have not been set to NO_MORE_ITERATIONS, go to step 3. Otherwise, go to step 7.

  7. Free the result buffer by calling NWDSFreeBuf.

Services

Directory

NCP calls

0x2222 23 17
Get File Server Information

0x2222 23 22
Get Station's Logged Info (old)

0x2222 23 28
Get Station's Logged Info

0x2222 104 01
Ping for NDS NCP

0x2222 104 02
Send NDS Fragmented Request/Reply

References

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