NWDSGetAttrDef

Returns the next eDirectory Schema attribute definition from 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)  NWDSGetAttrDef  ( 
     NWDSContextHandle   context,  
     pBuf_T              buf,  
     pnstr8              attrName,  
     pAttr_Info_T        attrInfo); 
  

Pascal

  uses netwin32 
   
  Function NWDSGetAttrDef 
    (context : NWDSContextHandle; 
     buf : pBuf_T; 
     attrName : pnstr8; 
     attrInfo : pAttr_Info_T 
  ) : NWDSCCODE;
  

Parameters

context

(IN) Specifies the NDS context for the request.

buf

(IN) Points to the result buffer being read.

attrName

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

attrInfo

(OUT) Points to additional information about the attribute definition.

Return Values

0x0000 0000

SUCCESSFUL

nonzero value

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

Remarks

NWDSGetAttrDef is used to retrieve attribute information from a result buffer filled in by NWDSReadAttrDef. For more information, see Reading an Attribute Definition.

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

If NWDSReadAttrDef is called with infoType set to DS_ATTR_DEF_NAMES (instead of DS_ATTR_DEFS), its output buffer will contain only names of the attributes. In this case, NWDSGetAttrDef ignores attrInfo, so attrInfo can be NULL.

You must allocate memory (sizeof(Attr_Info_T)) to receive the additional attribute-definition information.

NCP Calls

See Also

NWDSGetAttrCount, NWDSReadAttrDef