MesEncodeIncrementalHandleCreate function (midles.h)

The MesEncodeIncrementalHandleCreate function creates an encoding and then initializes it for the incremental style of serialization.

Syntax

RPC_STATUS MesEncodeIncrementalHandleCreate(
  void          *UserState,
  MIDL_ES_ALLOC AllocFn,
  MIDL_ES_WRITE WriteFn,
  handle_t      *pHandle
);

Parameters

UserState

Pointer to the user-supplied state object that coordinates the user-supplied Alloc, Write, and Read functions.

AllocFn

Pointer to the user-supplied Alloc function.

WriteFn

Pointer to the user-supplied Write function.

pHandle

Pointer to the newly created handle.

Return value

Value Meaning
RPC_S_OK
The call succeeded.
RPC_S_INVALID_ARG
The argument was invalid.
RPC_S_OUT_OF_MEMORY
Out of memory.
 
Note  For a list of valid error codes, see RPC Return Values.
 

Remarks

The MesEncodeIncrementalHandleCreate function is used by applications to create and initialize the handle for the incremental style of encoding or decoding. When using the incremental style of encoding, the user supplies an Alloc function to provide an empty buffer into which the encoded data is placed, and a Write function to call when the buffer is full or the encoding is complete. For additional information on the user-supplied Alloc, Write, and Read functions, see Serialization Services.

When a stub is compiled using -protocol all or -protocol ndr64 and the buffer is to be encoded using the NDR64 transfer syntax, the MesIncrementalHandleReset function must be called with its OpCode parameter set to MES_ENCODE_NDR64.

Requirements

Requirement Value
Minimum supported client Windows 2000 Professional [desktop apps only]
Minimum supported server Windows 2000 Server [desktop apps only]
Target Platform Windows
Header midles.h (include Rpc.h)
Library Rpcrt4.lib
DLL Rpcrt4.dll

See also

Alloc

MesBufferHandleReset

MesHandleFree

MesIncrementalHandleReset