Returns the number of object class definition items associated with a result buffer’s current object class definition list in a result buffer.
#include <nwnet.h> or #include <nwdsbuft.h> N_EXTERN_LIBRARY (NWDSCCODE) NWDSGetClassItemCount ( NWDSContextHandle context, pBuf_T buf, pnuint32 itemCount);
uses netwin32 Function NWDSGetClassItemCount (context : NWDSContextHandle; buf : pBuf_T; itemCount : pnuint32 ) : NWDSCCODE;
(IN) Specifies the NDS context for the request.
(IN) Points to the result buffer being read.
(OUT) Points to the number of object-class definition items associated with the result buffer’s current class-definition-item list.
0x0000 0000 |
SUCCESSFUL |
nonzero value |
Nonzero values indicate errors. See |
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:
Super Class Names
Containment Class Names
Naming Attribute Names
Mandatory Attribute Names
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.