cwbOBJ_EndWriter

Purpose

Ends an iSeries™ writer job.

Syntax

 
unsigned int CWB_ENTRY  cwbOBJ_EndWriter(
                               cwbOBJ_ObjHandle   writerHandle,
                               cwbOBJ_ParmHandle *parmListHandle,
                               cwbSV_ErrHandle    errorHandle);

Parameters

cwbOBJ_ObjHandle writerHandle - input
Handle of the writer job to be stopped. This handle can be obtained by either listing writers and getting the writer handle from that list or from starting a writer and asking for the writer handle to be returned.
cwbOBJ_ParmHandle *parmListHandle - input
Optional. A pointer to a valid parameter list object handle that contains parameters for ending the writer.
cwbSV_ErrHandle errorHandle - output
Optional, may be 0. Any returned messages will be written to this object. It is created with the cwbSV_CreateErrHandle() API. The messages may be retrieved through the cwbSV_GetErrText() API. If the parameter is set to zero, no messages will be retrievable.

Return Codes

The following list shows common return values.

CWB_NO_ERROR
Successful completion.
CWB_NOT_ENOUGH_MEMORY
Insufficient memory.
CWB_INVALID_HANDLE
Handle is not valid.
CWB_INVALID_PARAMETER
Invalid parameter specified.
CWBOBJ_RC_HOST_ERROR
Host error occurred. Text may be in errorHandle.

Usage

After this calls returns successfully, cwbOBJ_DeleteObjHandle() should be called to release the writerHandle. The following parameter key's may be set in the pParmListHandl object: