NWDSGetClassItem

Returns the name of the next object class item stored 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)  NWDSGetClassItem  ( 
    (NWDSContextHandle   context,  
     pBuf_T              buf,  
    pnstr8               itemName); 
  

Pascal

  uses netwin32 
   
  Function NWDSGetClassItem 
    (context : NWDSContextHandle; 
     buf : pBuf_T; 
     itemName : pnstr8 
  ) : NWDSCCODE;
  

Parameters

context

(IN) Specifies the NDS context for the request.

buf

(IN) Points to the result buffer being read.

itemName

(OUT) Points to the name of the item (attribute or class) at the current position in the result buffer.

Return Values

0x0000 0000

SUCCESSFUL

nonzero value

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

Remarks

The buf parameter points to a Buf_T filled in by NWDSReadClassDef.

The itemName parameter points to the name of either an attribute or a class. The item is a member of one of the five class-definition-item lists:

  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.

The user must allocate space for the class item name pointed to by itemName. The size of the allocated memory is ((MAX_SCHEMA_NAME_CHARS)+1)*sizeof(character size) where character size is 1 for single-byte characters, and 2 for Unicode characters (Unicode characters are always 16 bits). One character is used for NULL termination.

Before retrieving the class items from a class-definition-item list, determine the number of items in the list by calling NWDSGetClassItemCount. Then retrieve the items associated with the list by repeatedly 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, and so on until you have retrieved all of the information from all of the lists.

NOTE:You must retrieve the information from the class-definition-item lists in the order shown above.

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

NCP Calls

See Also

NWDSGetClassDef, NWDSGetClassItemCount, NWDSListContainableClasses, NWDSReadClassDef