zBeginTask

Begins a new task.

Service:File System Services (64-Bit)

Syntax

#include <zPublics.h>

STATUS zBeginTask(
   Key_t   key,
   NINT    taskID,
   NINT   *retTaskID);

Parameters

key

(IN) Specifies the key that identifies the owner of the task.

taskID

(IN) Specifies the task ID number. If zero is passed in, the system assigns a task ID; otherwise, the user must supply a task ID in the range of 0-65,535.

retTaskID

(OUT) Points to a new task ID (a value greater than 65,535). When the task is ended, all the resources associated with the task are released.

Return Values

zOK

The operation completed successfully.

non-0

An error occurred (see Section 4.1, Return Values for a description).

Remarks

Resources such as open files and transactions are tied to a specific task.

See Also

zEndTask, zRootKey