NXDirMarkInit

Initializes a new directory enumeration mark.

Library:LibC
Classification:NKS
Service:File and Directory I/O

Syntax

  #include <nks/dirio.h> 
   
  int NXDirMarkInit (
     NXHandle_t    handle,
     NXDirMark_t  *dirMark);
  

Parameters

handle

(IN) Specifies the handle for the directory enumeration operation, as returned by NXDirEnumStart.

dirMark

(OUT) Points to the new directory enumeration mark.

Return Values

If successful, returns 0. Otherwise, returns a nonzero error code:

Decimal

Hex

Constant

Description

4

0x04

NX_EBADF

The handle is not a valid directory enumeration handle.

9

0x09

NX_EINVAL

The pointer that was passed is invalid.

Remarks

NXDirMarkInit initializes a variable of type NXDirMark_t, which is a new directory enumeration mark for use in calling NXDirEnumGetEntries. In order to get an entry, a new directory enumeration mark must be initialized. Because the path context (including the pathname format) can have an integral relationship with the structure to be initialized, the handle parameter must be specified.

See Also

NXDirEnumGetEntries