WS_READ_CALLBACK function

Used by the WS_XML_READER to read from some source into a buffer.

Syntax


void WS_READ_CALLBACK(
  _In_           void              **callbackState,
                 void              **bytes,
  _In_           ULONG             maxSize,
  _Out_          ULONG             **actualSize,
  _In_opt_ const  WS_ASYNC_CONTEXT *asyncContext,
  _In_opt_       WS_ERROR          *error
);

Parameters

callbackState [in]

A void pointer to the user-defined state value that was passed to the function that accepted this callback.

bytes

A void pointer to the location where the data should be placed.

maxSize [in]

The maximum number of bytes that may be read.

actualSize [out]

A pointer to a ULONG value that indicates the number of bytes actually read. This may be less than maxSize. Returning 0 indicates that there is no more data.

asyncContext [in, optional]

A pointer to a WS_ASYNC_CONTEXT structure containing information on how to invoke the function asynchronously. Assigned NULL if invoking synchronously.

error [in, optional]

A pointer to WS_ERROR data structure where additional error information should be stored if the function fails.

Return value

This function does not return a value.

Remarks

Returning size of 0 in the actualSize output parameter indicates the end of the file.

Requirements

Minimum supported client

Windows 7 [desktop apps only]

Minimum supported server

Windows Server 2008 R2 [desktop apps only]

Header

WebServices.h

 

 

Community Additions

ADD
Show: