NWDSGetClassItemCount

Returns the number of object class definition items associated with a result buffer’s current object class definition list in a result buffer.

NetWare Server:4.x, 5.x, 6.x
Platform:NLM, Windows NT, Windows 95, Windows 98, Windows 2000, Windows XP
Library:Cross-Platform NDS (NET*.*)
Service:NDS

Syntax

C

  #include <nwnet.h> 
  or 
  #include <nwdsbuft.h> 
   
  N_EXTERN_LIBRARY (NWDSCCODE)  NWDSGetClassItemCount  ( 
     NWDSContextHandle   context,  
     pBuf_T              buf,  
     pnuint32            itemCount); 
  

Pascal

  uses netwin32 
   
  Function NWDSGetClassItemCount 
    (context : NWDSContextHandle; 
     buf : pBuf_T; 
     itemCount : pnuint32 
  ) : NWDSCCODE;
  

Parameters

context

(IN) Specifies the NDS context for the request.

buf

(IN) Points to the result buffer being read.

itemCount

(OUT) Points to the number of object-class definition items associated with the result buffer’s current class-definition-item list.

Return Values

0x0000 0000

SUCCESSFUL

nonzero value

Nonzero values indicate errors. See NDS Return Values (–001 to –799).

Remarks

buf points to Buf_T filled in by NWDSReadClassDef.

itemCount points to the number of object-class-definition items that are associated with the current class-definition-item list. There are five class-definition item lists; these lists are stored in the buffer in the following order:

  1. Super Class Names

  2. Containment Class Names

  3. Naming Attribute Names

  4. Mandatory Attribute Names

  5. Optional Attribute Names

The first two lists contain the names of classes. The remaining lists contain the names of attributes.

Before retrieving class items from a class-definition-item list, determine the number of items in the list by calling NWDSGetClassItemCount. Retrieve the items associated with the list by calling NWDSGetClassItem once for each item in the list. Then determine the number of items in the next list by calling NWDSGetClassItemCount, and retrieve the values for the list by calling NWDSGetClassItem, until you have retrieved all of the information from all lists.

For the complete steps for reading object-class-definition information, see Reading a Class Definition.

NCP Calls

See Also

NWDSGetClassDef, NWDSGetClassItem, NWDSListContainableClasses, NWDSReadClassDef